Merge "Stop running k8s-on-openstack nested"
This commit is contained in:
commit
d3e554e306
11
playbooks/bootstrap-k8s-nodes.yaml
Normal file
11
playbooks/bootstrap-k8s-nodes.yaml
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# k8s-on-openstack uses the baked in ubuntu user and ssh keypairs
|
||||||
|
# to interact with the host. Our other roles assume that we'll be
|
||||||
|
# logging in directly as root. Run base-repos logging in as ubuntu
|
||||||
|
# with become: true set so that we can overwrite the root ssh key
|
||||||
|
# with the one allowing direct login from bridge.
|
||||||
|
- hosts: "kubernetes:!disabled"
|
||||||
|
name: "Base: set up users and base package repositories on all hosts"
|
||||||
|
remote_user: ubuntu
|
||||||
|
become: true
|
||||||
|
roles:
|
||||||
|
- base-repos
|
@ -1,35 +0,0 @@
|
|||||||
- hosts: "localhost:!disabled"
|
|
||||||
name: "System-config: Update the system-config repo on bridge"
|
|
||||||
connection: local
|
|
||||||
gather_facts: false
|
|
||||||
tasks:
|
|
||||||
- name: Make sure k8s-on-openstack repo is up to date
|
|
||||||
git:
|
|
||||||
repo: https://github.com/infraly/k8s-on-openstack
|
|
||||||
dest: /opt/k8s-on-openstack
|
|
||||||
# HEAD as of 2019-02-08
|
|
||||||
version: e27a313b1583c377e08385014b9a880da765924b
|
|
||||||
force: yes
|
|
||||||
|
|
||||||
- name: Run kubernetes deploy playbook
|
|
||||||
command: ./run_k8s_ansible.sh
|
|
||||||
args:
|
|
||||||
chdir: /opt/system-config
|
|
||||||
|
|
||||||
- name: Install cinder storage class
|
|
||||||
k8s:
|
|
||||||
context: gitea
|
|
||||||
state: present
|
|
||||||
definition: "{{ lookup('file', 'k8s/storage-class.yaml') | from_yaml }}"
|
|
||||||
|
|
||||||
# k8s-on-openstack uses the baked in ubuntu user and ssh keypairs
|
|
||||||
# to interact with the host. Our other roles assume that we'll be
|
|
||||||
# logging in directly as root. Run base-repos logging in as ubuntu
|
|
||||||
# with become: true set so that we can overwrite the root ssh key
|
|
||||||
# with the one allowing direct login from bridge.
|
|
||||||
- hosts: "kubernetes:!disabled"
|
|
||||||
name: "Base: set up users and base package repositories on all hosts"
|
|
||||||
remote_user: ubuntu
|
|
||||||
become: true
|
|
||||||
roles:
|
|
||||||
- base-repos
|
|
@ -18,3 +18,11 @@
|
|||||||
command: ansible-galaxy install --roles-path /etc/ansible/roles --force -r roles.yaml
|
command: ansible-galaxy install --roles-path /etc/ansible/roles --force -r roles.yaml
|
||||||
args:
|
args:
|
||||||
chdir: /opt/system-config
|
chdir: /opt/system-config
|
||||||
|
|
||||||
|
- name: Make sure k8s-on-openstack repo is up to date
|
||||||
|
git:
|
||||||
|
repo: https://github.com/infraly/k8s-on-openstack
|
||||||
|
dest: /opt/k8s-on-openstack
|
||||||
|
# HEAD as of 2019-02-08
|
||||||
|
version: e27a313b1583c377e08385014b9a880da765924b
|
||||||
|
force: yes
|
||||||
|
15
run_all.sh
15
run_all.sh
@ -77,16 +77,21 @@ start_timer
|
|||||||
timeout -k 2m 120m ansible-playbook ${ANSIBLE_PLAYBOOKS}/bridge.yaml
|
timeout -k 2m 120m ansible-playbook ${ANSIBLE_PLAYBOOKS}/bridge.yaml
|
||||||
send_timer bridge
|
send_timer bridge
|
||||||
|
|
||||||
|
# Run k8s-on-openstack
|
||||||
|
start_timer
|
||||||
|
timeout -k 2m 120m ${SYSTEM_CONFIG}/run_k8s_ansible.sh
|
||||||
|
send_timer k8s
|
||||||
|
|
||||||
|
# Run the k8s nodes bootstrap playbook
|
||||||
|
start_timer
|
||||||
|
timeout -k 2m 120m ansible-playbook -f 50 ${ANSIBLE_PLAYBOOKS}/bootstrap-k8s-nodes.yaml
|
||||||
|
send_timer base
|
||||||
|
|
||||||
# Run the base playbook everywhere
|
# Run the base playbook everywhere
|
||||||
start_timer
|
start_timer
|
||||||
timeout -k 2m 120m ansible-playbook -f 50 ${ANSIBLE_PLAYBOOKS}/base.yaml
|
timeout -k 2m 120m ansible-playbook -f 50 ${ANSIBLE_PLAYBOOKS}/base.yaml
|
||||||
send_timer base
|
send_timer base
|
||||||
|
|
||||||
# Run k8s-on-openstack
|
|
||||||
start_timer
|
|
||||||
timeout -k 2m 120m ansible-playbook -f 50 ${ANSIBLE_PLAYBOOKS}/run-k8s-on-openstack.yaml
|
|
||||||
send_timer k8s
|
|
||||||
|
|
||||||
# These playbooks run on the gitea k8s cluster
|
# These playbooks run on the gitea k8s cluster
|
||||||
start_timer
|
start_timer
|
||||||
timeout -k 2m 120m ansible-playbook -f 50 -e /etc/ansible/hosts/gitea-cluster.yaml ${SYSTEM_CONFIG}/kubernetes/rook/rook-playbook.yaml
|
timeout -k 2m 120m ansible-playbook -f 50 -e /etc/ansible/hosts/gitea-cluster.yaml ${SYSTEM_CONFIG}/kubernetes/rook/rook-playbook.yaml
|
||||||
|
@ -39,5 +39,4 @@ export NODE_EXTRA_VOLUME_SIZE="80"
|
|||||||
export USE_OCTAVIA="True"
|
export USE_OCTAVIA="True"
|
||||||
export BLOCK_STORAGE_VERSION='v3'
|
export BLOCK_STORAGE_VERSION='v3'
|
||||||
|
|
||||||
cd /opt/k8s-on-openstack
|
ansible-playbook -v /opt/k8s-on-openstack/site.yaml
|
||||||
ansible-playbook -v site.yaml
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user