소스 검색

Don't delete Docker images which may have been pulled by another

Some people run Coturn or Jitsi, etc., by themselves and disable it
in the playbook.

Because the playbook is trying to be nice and clean up after itself,
it was deleting these Docker images.

However, people wish to pull and use them separately and would rather
they don't get deleted.

We could make this configurable for the sake of this special case, but
it's simpler to just avoid deleting these images.
It's not like this "cleaning things up" thing works anyway.
As time goes on, the playbook gets updated with newer image tags
and we leave so many images behind. If one doesn't run
`docker system prune -a` manually once in a while, they'd get swamped
with images anyway. Whether we leave a few images behind due to the lack
of this cleanup now is pretty much irrelevant.
pull/816/head
Slavi Pantaleev 5 년 전
부모
커밋
1cd251ed78
6개의 변경된 파일14개의 추가작업 그리고 24개의 파일을 삭제
  1. +2
    -4
      roles/matrix-coturn/tasks/setup_uninstall.yml
  2. +3
    -0
      roles/matrix-dynamic-dns/tasks/uninstall.yml
  3. +2
    -5
      roles/matrix-jitsi/tasks/setup_jitsi_jicofo.yml
  4. +2
    -5
      roles/matrix-jitsi/tasks/setup_jitsi_jvb.yml
  5. +2
    -5
      roles/matrix-jitsi/tasks/setup_jitsi_prosody.yml
  6. +3
    -5
      roles/matrix-jitsi/tasks/setup_jitsi_web.yml

+ 2
- 4
roles/matrix-coturn/tasks/setup_uninstall.yml 파일 보기

@@ -41,7 +41,5 @@
path: "{{ matrix_coturn_base_path }}"
state: absent

- name: Ensure coturn Docker image doesn't exist
docker_image:
name: "{{ matrix_coturn_docker_image }}"
state: absent
# Intentionally not removing the Docker image when uninstalling.
# We can't be sure it had been pulled by us in the first place.

+ 3
- 0
roles/matrix-dynamic-dns/tasks/uninstall.yml 파일 보기

@@ -22,3 +22,6 @@
service:
daemon_reload: yes
when: "matrix_dynamic_dns_service_stat.stat.exists"

# Intentionally not removing the Docker image when uninstalling.
# We can't be sure it had been pulled by us in the first place.

+ 2
- 5
roles/matrix-jitsi/tasks/setup_jitsi_jicofo.yml 파일 보기

@@ -89,8 +89,5 @@
state: absent
when: "not matrix_jitsi_enabled|bool"

- name: Ensure jitsi-jicofo Docker image doesn't exist
docker_image:
name: "{{ matrix_jitsi_jicofo_docker_image }}"
state: absent
when: "not matrix_jitsi_enabled|bool"
# Intentionally not removing the Docker image when uninstalling.
# We can't be sure it had been pulled by us in the first place.

+ 2
- 5
roles/matrix-jitsi/tasks/setup_jitsi_jvb.yml 파일 보기

@@ -89,8 +89,5 @@
state: absent
when: "not matrix_jitsi_enabled|bool"

- name: Ensure jitsi-jvb Docker image doesn't exist
docker_image:
name: "{{ matrix_jitsi_jvb_docker_image }}"
state: absent
when: "not matrix_jitsi_enabled|bool"
# Intentionally not removing the Docker image when uninstalling.
# We can't be sure it had been pulled by us in the first place.

+ 2
- 5
roles/matrix-jitsi/tasks/setup_jitsi_prosody.yml 파일 보기

@@ -80,8 +80,5 @@
state: absent
when: "not matrix_jitsi_enabled|bool"

- name: Ensure jitsi-prosody Docker image doesn't exist
docker_image:
name: "{{ matrix_jitsi_prosody_docker_image }}"
state: absent
when: "not matrix_jitsi_enabled|bool"
# Intentionally not removing the Docker image when uninstalling.
# We can't be sure it had been pulled by us in the first place.

+ 3
- 5
roles/matrix-jitsi/tasks/setup_jitsi_web.yml 파일 보기

@@ -90,8 +90,6 @@
state: absent
when: "not matrix_jitsi_enabled|bool"

- name: Ensure jitsi-web Docker image doesn't exist
docker_image:
name: "{{ matrix_jitsi_web_docker_image }}"
state: absent
when: "not matrix_jitsi_enabled|bool"
# Intentionally not removing the Docker image when uninstalling.
# We can't be sure it had been pulled by us in the first place.


불러오는 중...
취소
저장