Mercurial > libervia-backend
annotate docker/backend-dev-demo/scripts/init_script.sh @ 4197:9cda0347e0ac
plugin XEP-0359: if no origin ID is found, use <message> ID instead:
This way, we always have the right ID to check for non groupchat message in
`History.origin_id`.
author | Goffi <goffi@goffi.org> |
---|---|
date | Wed, 13 Dec 2023 22:00:25 +0100 |
parents | 22cd3094cd1e |
children | 6a8cc6d668a4 |
rev | line source |
---|---|
4195
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
1 #!/bin/bash |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
2 |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
3 SETUP_INDICATOR="/home/libervia/.local/share/libervia/setup_complete.flag" |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
4 FORUMS_JSON_FILE="/home/libervia/forums.json" |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
5 |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
6 if [ ! -f "$SETUP_INDICATOR" ]; then |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
7 echo "First run detected. Setting up the environment and configuration." |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
8 |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
9 libervia-cli profile modify -D -cp demo --pwd demo |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
10 libervia-cli forums set -p demo < $FORUMS_JSON_FILE |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
11 libervia-cli bookmarks add -pdemo -a demo@chat.server1.test |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
12 |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
13 touch "$SETUP_INDICATOR" |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
14 echo "Initial setup complete." |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
15 else |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
16 echo "Not the first run. Skipping setup." |
22cd3094cd1e
docker (demo): fix starting + better UX:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
17 fi |