1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/mobilizon_ynh.git synced 2024-09-03 19:46:19 +02:00

Alter services configuration to meet with new requirements

This commit is contained in:
Thomas Parisot 2021-01-16 21:28:18 +01:00
parent 39924136ea
commit b79fc63e8c
4 changed files with 30 additions and 12 deletions

View file

@ -1,6 +1,6 @@
SOURCE_URL=https://framagit.org/framasoft/mobilizon/-/archive/1.0.0/mobilizon-1.0.0.tar.gz
SOURCE_SUM=a66712b859b923403945ad3e1e05f3ef537c7eb2a598f511dd99018ee4c06feb
SOURCE_URL=https://framagit.org/oncletom/mobilizon/-/package_files/74/download
SOURCE_SUM=cf6cd61ecc9c146586e8e8586cb9d58c51dda88da24850df5445f0f4c3bf7e58
SOURCE_SUM_PRG=sha256sum
SOURCE_FORMAT=tar.gz
SOURCE_IN_SUBDIR=true
SOURCE_FILENAME=mobilizon-1.0.0.tar.gz
SOURCE_FILENAME=mobilizon_0.0.6_amd64.tar.gz

View file

@ -18,7 +18,7 @@ location / {
proxy_pass http://localhost:__PORT__;
location ~* \.(css|js)$ {
root __FINALPATH__/mobilizon/priv/static;
root __FINALPATH__/__NAME__/lib/mobilizon-__APP_VERSION__/priv/static;
etag off;
access_log off;
more_set_headers "Cache-Control: public, max-age=31536000, immutable";
@ -38,6 +38,6 @@ location / {
}
location @error {
root __FINALPATH__/mobilizon/priv/errors;
root __FINALPATH__/__NAME__/lib/mobilizon-__APP_VERSION__/priv/errors;
try_files /error.html 502;
}

View file

@ -5,13 +5,33 @@ After=network.target postgresql.service
[Service]
User=__APP__
WorkingDirectory=__FINALPATH__/__APP__/
ExecStart=/usr/bin/env mix phx.server
ExecReload=/bin/kill $MAINPID
ExecStart=__FINALPATH__/__APP__/bin/mobilizon start
ExecReload=__FINALPATH__/__APP__/bin/mobilizon restart
ExecStop=__FINALPATH__/__APP__/bin/mobilizon stop
KillMode=process
Restart=on-failure
Environment=MIX_ENV=prod
SyslogIdentifier=mobilizon
Environment=MIX_ENV=prod
Environment=PORT=__PORT__
Environment=MOBILIZON_INSTANCE_PORT=__PORT__
Environment=MOBILIZON_INSTANCE_HOST=__DOMAIN__
Environment=MOBILIZON_INSTANCE_SECRET_KEY_BASE=__SECRET__
Environment=MOBILIZON_INSTANCE_SECRET_KEY=__SECRET_KEY__
Environment=MOBILIZON_INSTANCE_NAME=Mobilizon
Environment=MOBILIZON_INSTANCE_EMAIL=__APP__@__DOMAIN__
Environment=MOBILIZON_REPLY_EMAIL=__APP__@__DOMAIN__
Environment=MOBILIZON_UPLOADS=/app/uploads
Environment=MOBILIZON_DATABASE_USERNAME=__DB_USER__
Environment=MOBILIZON_DATABASE_PASSWORD=__DB_PWD__
Environment=MOBILIZON_DATABASE_DBNAME=__DB_NAME__
Environment=MOBILIZON_DATABASE_HOST=localhost
Environment=MOBILIZON_SMTP_SERVER=127.0.0.1
Environment=MOBILIZON_SMTP_HOSTNAME=127.0.0.1
Environment=MOBILIZON_SMTP_PORT=25
Environment=MOBILIZON_SMTP_USERNAME=__YNH_USER__
Environment=MOBILIZON_SMTP_PASSWORD=__YNH_USER_PASSWORD__
SyslogIdentifier=__APP__
; Some security directives.
; Use private /tmp and /var/tmp folders inside a new file system namespace, which are discarded after the process stops.

View file

@ -5,10 +5,8 @@
#=================================================
# dependencies used by the app
pkg_dependencies="build-essential inotify-tools postgresql postgresql-client postgresql-contrib postgis postgresql-postgis-scripts git curl unzip gnupg openssl make gcc libc-dev argon2 imagemagick webp gifsicle jpegoptim optipng pngquant cmake"
extra_pkg_dependencies="elixir esl-erlang"
pkg_dependencies="postgresql postgresql-client postgresql-contrib postgis postgresql-postgis-scripts"
NODEJS_VERSION=12
#=================================================
# PERSONAL HELPERS