37 lines
865 B
YAML

---
- name: Create Agent NGINX Hosts Directory
become: yes
become_user: frappe
file:
path: /home/jingrow/agent/nginx/hosts
state: directory
- name: Create Agent NGINX Upstream Directory
become: yes
become_user: frappe
file:
path: /home/jingrow/agent/nginx/upstreams
state: directory
- name: Create NGINX Proxy Configuration File
become: yes
become_user: frappe
file:
path: /home/jingrow/agent/nginx/proxy.conf
state: touch
- name: Symlink NGINX Proxy Configuration File
file:
src: /home/jingrow/agent/nginx/proxy.conf
dest: /etc/nginx/conf.d/proxy.conf
state: link
force: yes
follow: no
- name: Setup Agent Proxy
become: yes
become_user: frappe
command: '/home/jingrow/agent/env/bin/agent setup proxy --domain {{ domain }} --press-url {{ press_url }}'
args:
chdir: /home/jingrow/agent