Skip to content

Commit

Permalink
update the install-crucible action to set workshop.force-builds="true…
Browse files Browse the repository at this point in the history
…" if a CI built controller is used

- We need to ensure that the CI controller is fully tested by building
  images.

- Without this change it is possible that the CI controller will not
  have to build any images and then it won't be fully tested.  This
  can happen since it's possible for all the necessary images to
  already exist and recent changes such as expiration refresh make
  that more likely than ever.
  • Loading branch information
k-rister committed Aug 22, 2024
1 parent ebdfd7f commit beaf7cc
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions .github/actions/install-crucible/install-crucible.sh
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,27 @@ start_github_group "rickshaw-settings updates"
RICKSHAW_SETTINGS_FILE="/opt/crucible/subprojects/core/rickshaw/rickshaw-settings.json"
UPDATES_REQUIRED=0

if [ "${CI_CONTROLLER}" == "yes" ]; then
UPDATES_REQUIRED=1
FORCE_BUILDS="true"
echo "Updating rickshaw-settings value workshop.force-builds to '${FORCE_BUILDS}' in ${RICKSHAW_SETTINGS_FILE}"

if jq --indent 4 --arg force_builds "${FORCE_BUILDS}" \
'.workshop."force-builds" = $force_builds' \
${RICKSHAW_SETTINGS_FILE} > ${RICKSHAW_SETTINGS_FILE}.tmp; then
if mv ${RICKSHAW_SETTINGS_FILE}.tmp ${RICKSHAW_SETTINGS_FILE}; then
echo "Successfully updated:"
jq --indent 4 . ${RICKSHAW_SETTINGS_FILE}
else
echo "ERROR: Failed to move force-builds"
exit 1
fi
else
echo "ERROR: Failed to update force-builds"
exit 1
fi
fi

if [ "${AUTH_TOKEN_FILE_FOUND}" == 1 -a "${AUTH_TOKEN_TYPE}" == "PRODUCTION" ]; then
UPDATES_REQUIRED=1
EXPIRATION_LENGTH="52w"
Expand Down

0 comments on commit beaf7cc

Please sign in to comment.