1
0
Fork 0
mirror of https://git.tt-rss.org/fox/ttrss-docker-compose synced 2025-06-09 21:29:52 +02:00

1. move .env to .env-dist so local customization is not clashing with the

repo
2. rewrite SELF_URL_PATH based on configured value even if config.php
exists
3. update README
This commit is contained in:
Andrew Dolgov 2020-01-19 12:54:24 +03:00
parent 05d341df89
commit 9b0a93677d
4 changed files with 21 additions and 5 deletions

View file

@ -48,9 +48,9 @@ elif ! $PSQL -c 'select * from ttrss_version'; then
$PSQL < /var/www/html/tt-rss/schema/ttrss_schema_pgsql.sql
fi
if [ ! -s $DST_DIR/config.php ]; then
SELF_URL_PATH=$(echo $SELF_URL_PATH | sed -e 's/[\/&]/\\&/g')
SELF_URL_PATH=$(echo $SELF_URL_PATH | sed -e 's/[\/&]/\\&/g')
if [ ! -s $DST_DIR/config.php ]; then
sed \
-e "s/define('DB_HOST'.*/define('DB_HOST', '$DB_HOST');/" \
-e "s/define('DB_USER'.*/define('DB_USER', '$DB_USER');/" \
@ -63,7 +63,10 @@ if [ ! -s $DST_DIR/config.php ]; then
cat >> $DST_DIR/config.php << EOF
define('NGINX_XACCEL_PREFIX', '/tt-rss');
EOF
else
sed \
-e "s/define('SELF_URL_PATH'.*/define('SELF_URL_PATH','$SELF_URL_PATH');/" \
-i.bak $DST_DIR/config.php
fi
crond &