feat: stop the service if running
All checks were successful
continuous-integration/drone/push Build is passing

Signed-off-by: kjuulh <contact@kjuulh.io>
This commit is contained in:
Kasper Juul Hermansen 2024-11-30 12:20:51 +01:00
parent 150c7c3c98
commit 7b222af1dd
Signed by: kjuulh
GPG Key ID: D85D7535F18F35FA

View File

@ -28,6 +28,11 @@ echo "Creating directories..."
mkdir -p "${INSTALL_DIR}" mkdir -p "${INSTALL_DIR}"
mkdir -p "${CONFIG_DIR}" mkdir -p "${CONFIG_DIR}"
if systemctl is-active --quiet churn.service; then
echo "Stopping existing churn service..."
systemctl stop churn.service
fi
# Download binary from S3 # Download binary from S3
echo "Downloading binary..." echo "Downloading binary..."
curl -L -s "https://api-minio.front.kjuulh.io/${S3_BUCKET}/releases/${APP_NAME}/${APP_VERSION}/${BINARY_NAME}" -o "${INSTALL_DIR}/${BINARY_NAME}" curl -L -s "https://api-minio.front.kjuulh.io/${S3_BUCKET}/releases/${APP_NAME}/${APP_VERSION}/${BINARY_NAME}" -o "${INSTALL_DIR}/${BINARY_NAME}"