Обновить ansible/npm-setup.yml
This commit is contained in:
+2
-10
@@ -155,19 +155,13 @@
|
|||||||
when: docker_compose_result is failed
|
when: docker_compose_result is failed
|
||||||
|
|
||||||
- name: Check if containers are running
|
- name: Check if containers are running
|
||||||
shell: docker ps --filter "name=app" --format "table {{.Names}}\t{{.Status}}"
|
shell: docker ps --filter "name=app"
|
||||||
register: container_status
|
register: container_status
|
||||||
changed_when: false
|
changed_when: false
|
||||||
|
|
||||||
- name: Display container status
|
- name: Display container status
|
||||||
debug:
|
debug:
|
||||||
msg: "{{ container_status.stdout_lines }}"
|
msg: "Container status:\n{{ container_status.stdout }}"
|
||||||
|
|
||||||
- name: Get container logs if needed
|
|
||||||
shell: docker logs npm_app_1 --tail 20
|
|
||||||
register: container_logs
|
|
||||||
changed_when: false
|
|
||||||
ignore_errors: yes
|
|
||||||
|
|
||||||
- name: Display access information
|
- name: Display access information
|
||||||
debug:
|
debug:
|
||||||
@@ -186,6 +180,4 @@
|
|||||||
Default Admin Credentials:
|
Default Admin Credentials:
|
||||||
- Email: admin@example.com
|
- Email: admin@example.com
|
||||||
- Password: changeme
|
- Password: changeme
|
||||||
|
|
||||||
To check logs: docker logs npm_app_1
|
|
||||||
========================================
|
========================================
|
||||||
Reference in New Issue
Block a user