Have to chown first for the cp to work
This commit is contained in:
parent
de4f151912
commit
49e2758907
1 changed files with 2 additions and 2 deletions
4
start.sh
4
start.sh
|
@ -4,12 +4,12 @@ set -eu
|
||||||
|
|
||||||
mkdir -p /app/data/runtime /app/data/config
|
mkdir -p /app/data/runtime /app/data/config
|
||||||
|
|
||||||
|
chown -R cloudron:cloudron /app/data
|
||||||
|
|
||||||
if [[ ! -f /app/data/config/prometheus.yml ]]; then
|
if [[ ! -f /app/data/config/prometheus.yml ]]; then
|
||||||
echo "=> Creating config file on first run"
|
echo "=> Creating config file on first run"
|
||||||
sudo -u cloudron cp -n /app/code/prometheus.yml /app/data/config/prometheus.yml
|
sudo -u cloudron cp -n /app/code/prometheus.yml /app/data/config/prometheus.yml
|
||||||
fi
|
fi
|
||||||
|
|
||||||
chown -R cloudron:cloudron /app/data
|
|
||||||
|
|
||||||
echo "=> Starting Prometheus"
|
echo "=> Starting Prometheus"
|
||||||
exec /usr/local/bin/gosu cloudron:cloudron /app/code/prometheus --config.file=/app/data/config/prometheus.yml --storage.tsdb.path=/app/data/runtime
|
exec /usr/local/bin/gosu cloudron:cloudron /app/code/prometheus --config.file=/app/data/config/prometheus.yml --storage.tsdb.path=/app/data/runtime
|
||||||
|
|
Loading…
Reference in a new issue