diff options
author | Lars Wirzenius <liw@liw.fi> | 2023-12-17 10:21:46 +0200 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2023-12-17 10:21:46 +0200 |
commit | 472f963d2d68679710c8609b28db13894954837f (patch) | |
tree | 830e9e42496008a66fe7ee65597fda0ef494a365 /ansible/radicle.liw.fi.yml | |
parent | d279e728aabbb634039290132ba69aa57bd11d46 (diff) | |
download | ansibleness-472f963d2d68679710c8609b28db13894954837f.tar.gz |
radicle.liw.fi: some httpd installation
Signed-off-by: Lars Wirzenius <liw@liw.fi>
Sponsored-by: author
Diffstat (limited to 'ansible/radicle.liw.fi.yml')
-rw-r--r-- | ansible/radicle.liw.fi.yml | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/ansible/radicle.liw.fi.yml b/ansible/radicle.liw.fi.yml index 30edb64..b7e82cc 100644 --- a/ansible/radicle.liw.fi.yml +++ b/ansible/radicle.liw.fi.yml @@ -12,10 +12,30 @@ - name: "install important additional packages" apt: name: + - caddy - moreutils - nmap - ripgrep + - name: "install Caddy configuration" + copy: + content: | + :80 { + root * /usr/share/caddy + } + radicle.liw.fi:443 { + reverse_proxy 127.0.0.1:8888 + } + dest: /etc/caddy/Caddyfile + + - name: "restart Caddy" + systemd: + name: radicle-node + state: restarted + masked: no + enabled: yes + daemon_reload: yes + - name: "install radicle using installer" shell: | curl -sSf https://radicle.xyz/install | sudo -u liw bash @@ -74,6 +94,35 @@ enabled: yes daemon_reload: yes + - name: "install systemd unit for Radicle HTTPD" + copy: + content: | + [Unit] + After=syslog.target network.target + Description=Radicle HTTPd + + [Service] + Type=simple + ExecStart=/home/liw/.radicle/bin/radicle-httpd --listen 127.0.0.1:8888 + Environment=RAD_HOME=/home/liw/.radicle + KillMode=process + Restart=always + RestartSec=1 + User=liw + Group=liw + + [Install] + WantedBy=default.target + dest: /lib/systemd/system/radicle-httpd.service + + - name: "enable systemd unit for Radicle node" + systemd: + name: radicle-httpd + state: restarted + masked: no + enabled: yes + daemon_reload: yes + vars: ansible_python_interpreter: /usr/bin/python3 |