chore: Update deployment configuration and documentation
- Update Gitea configuration (remove DEFAULT_ACTIONS_URL) - Fix deployment documentation - Update Ansible playbooks - Clean up deprecated files - Add new deployment scripts and templates
This commit is contained in:
73
deployment/ansible/playbooks/tasks/diagnose-404.yml
Normal file
73
deployment/ansible/playbooks/tasks/diagnose-404.yml
Normal file
@@ -0,0 +1,73 @@
|
||||
---
|
||||
# Diagnose 404 Errors
|
||||
- name: Check nginx logs for errors
|
||||
shell: |
|
||||
docker logs nginx --tail 100 2>&1
|
||||
args:
|
||||
executable: /bin/bash
|
||||
register: nginx_logs
|
||||
failed_when: false
|
||||
|
||||
- name: Display nginx logs
|
||||
debug:
|
||||
msg: "{{ nginx_logs.stdout_lines }}"
|
||||
|
||||
- name: Check app container logs
|
||||
shell: |
|
||||
docker logs app --tail 100 2>&1
|
||||
args:
|
||||
executable: /bin/bash
|
||||
register: app_logs
|
||||
failed_when: false
|
||||
|
||||
- name: Display app container logs
|
||||
debug:
|
||||
msg: "{{ app_logs.stdout_lines }}"
|
||||
|
||||
- name: Test nginx health endpoint directly
|
||||
shell: |
|
||||
docker exec nginx wget -q -O - http://127.0.0.1/health 2>&1 || echo "Health check failed"
|
||||
args:
|
||||
executable: /bin/bash
|
||||
register: nginx_health_test
|
||||
failed_when: false
|
||||
|
||||
- name: Display nginx health check result
|
||||
debug:
|
||||
msg: "{{ nginx_health_test.stdout }}"
|
||||
|
||||
- name: Check nginx configuration
|
||||
shell: |
|
||||
docker exec nginx cat /etc/nginx/conf.d/default.conf 2>&1
|
||||
args:
|
||||
executable: /bin/bash
|
||||
register: nginx_config
|
||||
failed_when: false
|
||||
|
||||
- name: Display nginx configuration
|
||||
debug:
|
||||
msg: "{{ nginx_config.stdout_lines }}"
|
||||
|
||||
- name: Check if app container has files in /var/www/html
|
||||
shell: |
|
||||
docker exec app ls -la /var/www/html/ 2>&1 | head -20
|
||||
args:
|
||||
executable: /bin/bash
|
||||
register: app_files
|
||||
failed_when: false
|
||||
|
||||
- name: Display app container files
|
||||
debug:
|
||||
msg: "{{ app_files.stdout_lines }}"
|
||||
|
||||
- name: Check container network connectivity
|
||||
shell: |
|
||||
docker exec nginx ping -c 1 app 2>&1 | head -5
|
||||
args:
|
||||
executable: /bin/bash
|
||||
register: network_check
|
||||
failed_when: false
|
||||
|
||||
- name: Display network connectivity
|
||||
debug:
|
||||
msg: "{{ network_check.stdout }}"
|
||||
Reference in New Issue
Block a user