#!/usr/bin/with-contenv bash

cd /opt/ombi || exit

if [[ ! -z "${BASE_URL}" ]]; then
    EXTRA_PARAM="--baseurl ${BASE_URL}"
fi

exec \
	s6-setuidgid abc /opt/ombi/Ombi --storage "/config" --host http://*:3579 ${EXTRA_PARAM}
