This commit is contained in:
3
main.yml
3
main.yml
@@ -86,6 +86,9 @@
|
||||
- name: Deploy Jackett
|
||||
import_tasks: tasks/jackett.yml
|
||||
tags: jackett_deploy
|
||||
- name: Deploy NFL Proxy
|
||||
import_tasks: tasks/nfl-proxy.yml
|
||||
tags: nfl-proxy_deploy
|
||||
|
||||
- hosts: jackson
|
||||
|
||||
|
||||
22
tasks/nfl-proxy.yml
Normal file
22
tasks/nfl-proxy.yml
Normal file
@@ -0,0 +1,22 @@
|
||||
---
|
||||
- name: Create folder structure
|
||||
file:
|
||||
path: "{{ item }}"
|
||||
state: directory
|
||||
with_items:
|
||||
- "{{ data_dir }}/nfl-proxy"
|
||||
|
||||
- name: "Clone latest NFL-Proxy"
|
||||
git:
|
||||
repo: "git@git.alexav.gg:alex/nfl-proxy.git"
|
||||
dest: "{{ data_dir }}/nfl-proxy"
|
||||
|
||||
- name: "Stop & remove existing PM2 containers"
|
||||
shell: |
|
||||
pm2 delete nfl-proxy
|
||||
|
||||
- name: "Start new PM2 container"
|
||||
args:
|
||||
chdir: "{{ data_dir }}/nfl-proxy"
|
||||
shell: |
|
||||
pm2 start --name="nfl-proxy" "python3 main.py"
|
||||
Reference in New Issue
Block a user