Commit 4da0f77a authored by nanahira's avatar nanahira

add option to keep distro

parent 1b3dab35
Pipeline #18513 failed with stage
in 16 minutes and 10 seconds
...@@ -34,3 +34,4 @@ kernel_params: [] ...@@ -34,3 +34,4 @@ kernel_params: []
nfs: false nfs: false
docker_root: /var/lib/docker docker_root: /var/lib/docker
testing: false testing: false
keep_distro: false
...@@ -76,15 +76,15 @@ ...@@ -76,15 +76,15 @@
- name: keep old distribution - name: keep old distribution
set_fact: set_fact:
target_distribution: '{{ ansible_distribution_release }}' target_distribution: '{{ ansible_distribution_release }}'
when: not upgrade or ansible_distribution_release == 'sid' when: not upgrade or ansible_distribution_release == 'sid' or keep_distro
- name: move to jammy - name: move to jammy
set_fact: set_fact:
target_distribution: 'jammy' target_distribution: 'jammy'
when: ansible_distribution == 'Ubuntu' and upgrade when: ansible_distribution == 'Ubuntu' and upgrade and not keep_distro
- name: move to bullseye - name: move to bullseye
set_fact: set_fact:
target_distribution: 'bullseye' target_distribution: 'bullseye'
when: ansible_distribution == 'Debian' and upgrade and ansible_distribution_release != 'sid' when: ansible_distribution == 'Debian' and upgrade and ansible_distribution_release != 'sid' and not keep_distro
- name: 系统源 (apt) - name: 系统源 (apt)
become: true become: true
template: template:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment