Skip to content

Commit

Permalink
feat: add support for helm dependency update (#4)
Browse files Browse the repository at this point in the history
* feat: add support for helm update

* fix: variable type

* test: force update

* test: separate update from upgrade

* fix: add missing chart path
  • Loading branch information
arielvinas authored Sep 21, 2021
1 parent 7ce7c0d commit 95e7fa4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ inputs:
update-deps:
description: 'Update chart dependencies'
required: false
default: true
default: "true"
runs:
using: 'docker'
image: 'Dockerfile'
Expand Down
7 changes: 3 additions & 4 deletions deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ else
fi

# Helm Deployment
DEPS_UPDATE_COMMAND="helm dependency update &&"
DEPS_UPDATE_COMMAND="helm dependency update ${DEPLOY_CHART_PATH}"
UPGRADE_COMMAND="helm upgrade --timeout ${TIMEOUT}"
for config_file in ${DEPLOY_CONFIG_FILES//,/ }
do
Expand All @@ -25,9 +25,8 @@ fi
if [ -n "$DEPLOY_VALUES" ]; then
UPGRADE_COMMAND="${UPGRADE_COMMAND} --set ${DEPLOY_VALUES}"
fi
if [ $UPDATE_DEPS ]; then
UPGRADE_COMMAND="${DEPS_UPGRADE_COMMAND} ${UPGRADE_COMMAND} --set ${DEPLOY_VALUES}"
fi
UPGRADE_COMMAND="${UPGRADE_COMMAND} ${DEPLOY_NAME} ${DEPLOY_CHART_PATH}"
echo "Executing: ${DEPS_UPDATE_COMMAND}"
${DEPS_UPDATE_COMMAND}
echo "Executing: ${UPGRADE_COMMAND}"
${UPGRADE_COMMAND}

0 comments on commit 95e7fa4

Please sign in to comment.