From b9ac337e4b27912a541c8f156ca9d1a296b988c9 Mon Sep 17 00:00:00 2001 From: Jennifer Power Date: Fri, 12 Jan 2024 16:50:43 -0500 Subject: [PATCH] fix: uses abs path to common.sh in entrypoint scripts The working directory is subject to change and the entrypoint scripts need to source `common.sh` from the location in the container. Signed-off-by: Jennifer Power --- actions/autosync/auto-sync-entrypoint.sh | 4 +++- actions/create-cd/create-cd-entrypoint.sh | 2 +- actions/rules-transform/rules-transform-entrypoint.sh | 2 +- actions/sync-upstreams/sync-upstreams-entrypoint.sh | 2 +- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/actions/autosync/auto-sync-entrypoint.sh b/actions/autosync/auto-sync-entrypoint.sh index 16d60028..ba03a2d3 100644 --- a/actions/autosync/auto-sync-entrypoint.sh +++ b/actions/autosync/auto-sync-entrypoint.sh @@ -3,7 +3,9 @@ set -eu # shellcheck disable=SC1091 -source ./common.sh +source /common.sh + +set_git_safe_directory # Initialize the command variable command="trestlebot-autosync \ diff --git a/actions/create-cd/create-cd-entrypoint.sh b/actions/create-cd/create-cd-entrypoint.sh index 079f5980..5fd93b27 100644 --- a/actions/create-cd/create-cd-entrypoint.sh +++ b/actions/create-cd/create-cd-entrypoint.sh @@ -3,7 +3,7 @@ set -eu # shellcheck disable=SC1091 -source ./common.sh +source /common.sh set_git_safe_directory diff --git a/actions/rules-transform/rules-transform-entrypoint.sh b/actions/rules-transform/rules-transform-entrypoint.sh index 56a969d6..8fb9d814 100644 --- a/actions/rules-transform/rules-transform-entrypoint.sh +++ b/actions/rules-transform/rules-transform-entrypoint.sh @@ -3,7 +3,7 @@ set -eu # shellcheck disable=SC1091 -source ./common.sh +source /common.sh set_git_safe_directory diff --git a/actions/sync-upstreams/sync-upstreams-entrypoint.sh b/actions/sync-upstreams/sync-upstreams-entrypoint.sh index 02d99a41..60a07d42 100644 --- a/actions/sync-upstreams/sync-upstreams-entrypoint.sh +++ b/actions/sync-upstreams/sync-upstreams-entrypoint.sh @@ -3,7 +3,7 @@ set -eu # shellcheck disable=SC1091 -source ./common.sh +source /common.sh set_git_safe_directory