From d2d8e23d9def182534feda9f696b1ef45f857e0d Mon Sep 17 00:00:00 2001 From: S M Y Date: Fri, 30 Aug 2019 21:37:47 +0530 Subject: [PATCH 1/2] Docker remove credential file and cert service deployment change --- ansible/docker_image_push.yml | 7 +++++++ ansible/roles/stack-sunbird/tasks/cert_service.yml | 4 ++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/ansible/docker_image_push.yml b/ansible/docker_image_push.yml index a9bb19b231..192b9cbe07 100644 --- a/ansible/docker_image_push.yml +++ b/ansible/docker_image_push.yml @@ -15,3 +15,10 @@ docker_image: name: "{{ hub_org }}/{{ image_name }}:{{ image_tag }}" push: yes + + - name: which user + shell: whoami + register: username + + - debug: + var: username diff --git a/ansible/roles/stack-sunbird/tasks/cert_service.yml b/ansible/roles/stack-sunbird/tasks/cert_service.yml index 849e040e3a..3ef1092c34 100644 --- a/ansible/roles/stack-sunbird/tasks/cert_service.yml +++ b/ansible/roles/stack-sunbird/tasks/cert_service.yml @@ -1,7 +1,7 @@ --- -- name: Remove user org service +- name: Remove cert service shell: "docker service rm cert-service" ignore_errors: yes -- name: Deploy user org service +- name: Deploy cert service shell: "docker service create --with-registry-auth --replicas {{ cert_replicas }} -p 9011:9000 --name cert-service --hostname cert-service --reserve-memory {{ cert_reservation_memory }} --limit-memory {{ cert_limit_memory }} --limit-cpu {{ cert_limit_cpu }} --reserve-cpu {{ cert_reservation_cpu }} --network application_default --env-file /home/deployer/env/sunbird_cert-service.env {{hub_org}}/{{image_name}}:{{image_tag}}" From df4a092c35c0c132e9089eaa1d10d6fa63ce29ca Mon Sep 17 00:00:00 2001 From: S M Y Date: Fri, 30 Aug 2019 21:46:31 +0530 Subject: [PATCH 2/2] docker push file removal --- ansible/docker_image_push.yml | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/ansible/docker_image_push.yml b/ansible/docker_image_push.yml index 192b9cbe07..5b0dc91f01 100644 --- a/ansible/docker_image_push.yml +++ b/ansible/docker_image_push.yml @@ -16,9 +16,6 @@ name: "{{ hub_org }}/{{ image_name }}:{{ image_tag }}" push: yes - - name: which user - shell: whoami - register: username - - - debug: - var: username + - file: + path: "/root/.docker" + state: absent