build stuff and generate config

matrix
histausse 3 years ago
parent 3f412974fd
commit bc54f67e59
Signed by: histausse
GPG Key ID: 67486F107F62E9E9

@ -37,6 +37,18 @@
git: git:
repo: 'https://github.com/t2bot/matrix-appservice-discord.git' repo: 'https://github.com/t2bot/matrix-appservice-discord.git'
dest: /srv/matrix-appservice-discord dest: /srv/matrix-appservice-discord
# They should be an handler here the rebuild the bot
- name: Build typescript
shell:
cmd: npm run build
chdir: /srv/matrix-appservice-discord
creates: /srv/matrix-appservice-discord/build
- name: Install dependencies
npm:
path: /srv/matrix-appservice-discord
state: latest
- name: Configure the bridge - name: Configure the bridge
template: template:
@ -47,10 +59,13 @@
mode: '0660' mode: '0660'
- name: Generate discord-registration.yaml - name: Generate discord-registration.yaml
debug: shell:
msg: "TODO: Generate discord-registration.yaml" cmd: "node build/src/discordas.js -r -u 'http://localhost:9005' -c config.yaml"
chdir: /srv/matrix-appservice-discord
creates: /srv/matrix-appservice-discord/discord-registration.yaml
notify: Restart synapse
- name: - name: Copy config for synapse
file: file:
src: /srv/matrix-appservice-discord/discord-registration.yaml src: /srv/matrix-appservice-discord/discord-registration.yaml
dest: /etc/matrix-synapse/discord-registration.yaml dest: /etc/matrix-synapse/discord-registration.yaml

@ -4,7 +4,7 @@
name: nginx name: nginx
state: reloaded state: reloaded
- name: Reload synapse - name: Restart synapse
systemd: systemd:
name: matrix-synapse name: matrix-synapse
state: reloaded state: restarted

@ -58,7 +58,7 @@
template: template:
src: homeserver.yaml src: homeserver.yaml
dest: /etc/matrix-synapse/homeserver.yaml dest: /etc/matrix-synapse/homeserver.yaml
notify: Reload synapse notify: Restart synapse
# --- DRAFT --- # --- DRAFT ---
- name: Install nginx - name: Install nginx

Loading…
Cancel
Save