Commit e7a287a9 authored by Spiros Koulouzis's avatar Spiros Koulouzis

move add data-root after installing docker

parent a8ffaf0d
......@@ -104,18 +104,7 @@
- name: Update apt and install docker-ce
apt: update_cache=yes name=docker-ce state=latest
- name: Change data-root location in /etc/docker/daemon.json
shell: |
echo '{"data-root": "/data"}' > /etc/docker/daemon.json
when: mount_volume.stat.exists == True
- name: Restart service docker, in all cases
service:
name: docker
state: restarted
ignore_errors: yes
when: mount_volume.stat.exists == True
- name: Update and upgrade apt packages
apt:
......@@ -135,3 +124,16 @@
- name: Update apt and install docker-ce
apt: update_cache=yes name=kubeadm state=latest
- name: Change data-root location in /etc/docker/daemon.json
shell: |
echo '{"data-root": "/data"}' > /etc/docker/daemon.json
when: mount_volume.stat.exists == True
- name: Restart service docker, in all cases
service:
name: docker
state: restarted
ignore_errors: yes
when: mount_volume.stat.exists == True
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