mirror of
https://git.tt-rss.org/fox/ttrss-docker-compose
synced 2025-06-12 16:29:51 +02:00
add workaround for slow podman internal dns resolver
This commit is contained in:
parent
f43ade0129
commit
c50ed4ca5b
1 changed files with 12 additions and 0 deletions
|
@ -19,6 +19,18 @@ SRC_REPO=https://git.tt-rss.org/fox/tt-rss.git
|
|||
|
||||
[ -e $DST_DIR ] && rm -f $DST_DIR/.app_is_ready
|
||||
|
||||
export PGPASSWORD=$TTRSS_DB_PASS
|
||||
|
||||
# podman internal dns is hilariously slow
|
||||
if [ ! -z "${TTRSS_DB_SLOW_DNS_HACK}" ]; then
|
||||
DBIPADDR=$(ping -c 1 db | grep from | cut -d " " -f 4 | tr -d :)
|
||||
|
||||
if [ ! -z "$DBIPADDR" ]; then
|
||||
echo overriding DB host with IP address: $DBIPADDR
|
||||
export TTRSS_DB_HOST=$DBIPADDR
|
||||
fi
|
||||
fi
|
||||
|
||||
[ ! -e /var/www/html/index.php ] && cp ${SCRIPT_ROOT}/index.php /var/www/html
|
||||
|
||||
PSQL="mysql -q -h $TTRSS_DB_HOST -u $TTRSS_DB_USER -p$TTRSS_DB_PASS $TTRSS_DB_NAME"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue