mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
Centralize database setup there and remove all copying of config.dev from the entrypoint scripts (the Dockerfile now does it). Signed-off-by: Kevin Morris <kevr@0cost.org>
22 lines
644 B
Bash
Executable file
22 lines
644 B
Bash
Executable file
#!/bin/bash
|
|
set -eou pipefail
|
|
|
|
# Setup database.
|
|
NO_INITDB=1 /docker/mariadb-init-entrypoint.sh
|
|
|
|
# Setup some other options.
|
|
aurweb-config set options cache 'redis'
|
|
aurweb-config set options redis_address 'redis://redis'
|
|
aurweb-config set options aur_location "$AURWEB_FASTAPI_PREFIX"
|
|
aurweb-config set options git_clone_uri_anon "${AURWEB_FASTAPI_PREFIX}/%s.git"
|
|
aurweb-config set options git_clone_uri_priv "${AURWEB_SSHD_PREFIX}/%s.git"
|
|
|
|
if [ ! -z ${COMMIT_HASH+x} ]; then
|
|
aurweb-config set devel commit_hash "$COMMIT_HASH"
|
|
fi
|
|
|
|
# Setup prometheus directory.
|
|
rm -rf $PROMETHEUS_MULTIPROC_DIR
|
|
mkdir -p $PROMETHEUS_MULTIPROC_DIR
|
|
|
|
exec "$@"
|