1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/tandoor_ynh.git synced 2024-09-03 20:35:56 +02:00
This commit is contained in:
eric_G 2024-08-21 13:22:59 +02:00 committed by GitHub
commit ed8ebb1732
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 8 additions and 2 deletions

View file

@ -55,7 +55,7 @@ SHOPPING_MIN_AUTOSYNC_INTERVAL=5
# If mediafiles are stored at a different location uncomment and change accordingly, MUST END IN /
# this is not required if you are just using a subfolder
# This can either be a relative path from the applications base path or the url of an external host
#MEDIA_URL=/media/
MEDIA_URL=__DATA_DIR__/media/
# Serve mediafiles directly using gunicorn. Basically everyone recommends not doing this. Please use any of the examples
# provided that include an additional nxginx container to handle media file serving.

View file

@ -18,5 +18,5 @@ location __PATH__/ {
}
location /media/ {
alias __INSTALL_DIR__/mediafiles/;
alias __DATA_DIR__/media/;
}

View file

@ -51,6 +51,9 @@ ram.runtime = "1500M"
[resources.install_dir]
[resources.data_dir]
subdirs = ["media"]
[resources.permissions]
main.url = "/"
api.url = "/api"

View file

@ -63,12 +63,15 @@ chown "$app:$app" "$install_dir/recipes/version.py"
# SPECIFIC SETUP
#=================================================
ynh_script_progression --message="Building frontend..." --weight=5
_tandoor_build_frontend
ynh_script_progression --message="Installing Tandoor and its python dependencies..." --weight=1
_tandoor_venv_install
ynh_script_progression --message="Running migrations and generating static files..." --weight=2
pushd "$install_dir"
(
source "$install_dir/.env"