From 090c3e592c7e003d5a997f75e6bb1217c97c7402 Mon Sep 17 00:00:00 2001 From: damon Date: Sat, 27 Mar 2021 12:11:57 -0700 Subject: [PATCH] cloudworkers: clean disk space more thoroughly, stop containers first --- .dockerignore | 2 ++ deploy/ansible/worker/include/update_existing_ursula.yml | 7 +------ deploy/ansible/worker/update_remote_workers.yml | 1 + newsfragments/2618.bugfix.rst | 1 + 4 files changed, 5 insertions(+), 6 deletions(-) create mode 100644 newsfragments/2618.bugfix.rst diff --git a/.dockerignore b/.dockerignore index fd69de5d9..842d8b640 100644 --- a/.dockerignore +++ b/.dockerignore @@ -1,6 +1,8 @@ +venv .env/* env/* docs/* newsfragments/* .coverage/* .git/* +.history diff --git a/deploy/ansible/worker/include/update_existing_ursula.yml b/deploy/ansible/worker/include/update_existing_ursula.yml index dd6ab406a..50d8ecca0 100644 --- a/deploy/ansible/worker/include/update_existing_ursula.yml +++ b/deploy/ansible/worker/include/update_existing_ursula.yml @@ -6,11 +6,7 @@ - name: Keep disk space clean by pruning unneeded docker debris become: yes - docker_prune: - containers: yes - images: yes - networks: yes - builder_cache: yes + shell: docker system prune -af - name: "pull {{ nucypher_image | default('nucypher/nucypher:latest') }}" become: yes @@ -19,7 +15,6 @@ source: pull force_source: yes -- import_playbook: stop_containers.yml - import_playbook: run_geth.yml when: node_is_decentralized is not undefined and node_is_decentralized - import_playbook: run_ursula.yml diff --git a/deploy/ansible/worker/update_remote_workers.yml b/deploy/ansible/worker/update_remote_workers.yml index 80dc0c080..fea124383 100644 --- a/deploy/ansible/worker/update_remote_workers.yml +++ b/deploy/ansible/worker/update_remote_workers.yml @@ -2,6 +2,7 @@ hosts: "{{ play_hosts }}" remote_user: "{{default_user}}" +- import_playbook: include/stop_containers.yml - import_playbook: include/update_existing_ursula.yml - import_playbook: include/check_running_ursula.yml - import_playbook: include/backup_ursula_data.yml diff --git a/newsfragments/2618.bugfix.rst b/newsfragments/2618.bugfix.rst new file mode 100644 index 000000000..1dccbbffe --- /dev/null +++ b/newsfragments/2618.bugfix.rst @@ -0,0 +1 @@ +cloudworkers more throughoughly cleans up diskspace before updates.