covas-deployment/db/tasks/start-db.yml

39 lines
848 B
YAML
Raw Normal View History

2022-10-08 18:15:53 +02:00
# start services db
2022-10-05 23:37:45 +02:00
2022-10-08 18:15:53 +02:00
- name: Stopping existing service
community.docker.docker_compose:
project_src: /home/valentin/db
2022-10-10 23:15:28 +02:00
state: absent
2022-10-08 18:15:53 +02:00
- name: Starting service
community.docker.docker_compose:
project_src: /home/valentin/db
register: output
- name: debug output
debug:
var: output
- name: Allow port postgresql
ansible.builtin.iptables:
chain: INPUT
protocol: tcp
destination_port: 54321
jump: ACCEPT
2022-10-08 18:15:53 +02:00
state: present
2022-10-20 16:47:03 +02:00
vars:
ansible_become: yes
ansible_become_method: sudo
ansible_become_password: "{{ sudo_password }}"
2022-10-08 18:15:53 +02:00
- name: Allow port redis
ansible.builtin.iptables:
chain: INPUT
protocol: tcp
destination_port: 63791
jump: ACCEPT
2022-10-08 18:15:53 +02:00
state: present
2022-10-20 16:47:03 +02:00
vars:
ansible_become: yes
ansible_become_method: sudo
ansible_become_password: "{{ sudo_password }}"