gourami

[UNMAINTAINED] Activitypub server in Rust
Log | Files | Refs | README | LICENSE

commit a17549bd0ae5dd1f2d4681b4feec71d6b9e93dcc
parent b7393235aa23586ffbf9b32c8afd0cfc736ae463
Author: alex wennerberg <alex@alexwennerberg.com>
Date:   Sun, 10 May 2020 17:44:22 -0500

Add very basic ansible playbook

Diffstat:
Aansible/deploy.sh | 5+++++
Aansible/gourami.service | 13+++++++++++++
Aansible/playbook.retry | 1+
Aansible/playbook.yml | 31+++++++++++++++++++++++++++++++
4 files changed, 50 insertions(+), 0 deletions(-)

diff --git a/ansible/deploy.sh b/ansible/deploy.sh @@ -0,0 +1,5 @@ +set -e + +cargo build --release +ansible-playbook playbook.yml + diff --git a/ansible/gourami.service b/ansible/gourami.service @@ -0,0 +1,13 @@ +[Unit] +Description=Gourami service +After=network.target + +[Service] +Type=simple +Restart=always +User=root +WorkingDirectory=/home/gourami +ExecStart=/home/gourami/gourami_social run + +[Install] +WantedBy=multi-user.target diff --git a/ansible/playbook.retry b/ansible/playbook.retry @@ -0,0 +1 @@ +dev.gourami.social diff --git a/ansible/playbook.yml b/ansible/playbook.yml @@ -0,0 +1,31 @@ +--- +- hosts: all + remote_user: root + become: yes + tasks: + - name: install dependencies + apt: + pkg: + - sqlite3 + - libsqlite3-dev + - name: copy binary over + copy: + src: ../target/release/gourami_social + dest: /home/gourami/gourami_social # TODO template etc + owner: gourami + - name: copy env over + copy: + src: prod_dotenv # distinguish dev/prod + dest: /home/gourami/.env + - name: copy service over + copy: + src: gourami.service + dest: /etc/systemd/system/gourami.service + - name: stop gourami service, if running + systemd: + name: gourami + state: stopped + - name: start gourami service + systemd: + name: gourami + state: started