Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider not requiring SVN credentials for dry-run #149

Open
aaemnnosttv opened this issue Jul 29, 2024 · 0 comments
Open

Consider not requiring SVN credentials for dry-run #149

aaemnnosttv opened this issue Jul 29, 2024 · 0 comments
Labels
help wanted Extra attention is needed needs:engineering This requires engineering to resolve.

Comments

@aaemnnosttv
Copy link
Member

Currently the SVN credentials are required for all runs, however they're only used when performing the commit which is only conditionally called if the job is not running as a dry-run.

if [[ -z "$SVN_USERNAME" ]]; then
echo "Set the SVN_USERNAME secret"
exit 1
fi
if [[ -z "$SVN_PASSWORD" ]]; then
echo "Set the SVN_PASSWORD secret"
exit 1
fi

if $INPUT_DRY_RUN; then
echo "➤ Dry run: Files not committed."
else
echo "➤ Committing files..."
svn commit -m "Update to version $VERSION from GitHub" --no-auth-cache --non-interactive --username "$SVN_USERNAME" --password "$SVN_PASSWORD"
fi

The dry-run was a much more recent addition, so it's possible this wasn't considered at the time.

Describe the solution you'd like

Since the credentials are only needed for that part of the deploy which isn't called for a dry-run, it would be nice to not require them but only in this scenario. Instead, I propose that missing credentials only raise a warning in a dry-run (to ensure devs are still aware without failing the script) but are still required for normal runs. This would add a little peace of mind to dry-runs that a deployment could not be possible (even if there was a bug in the action's script).

Similarly, it could be worth even redefining/unsetting the SVN credential variables when running as a dry-run early on to further safeguard these runs when live credentials may be present.

@jeffpaul jeffpaul added this to the Future Release milestone Jul 29, 2024
@jeffpaul jeffpaul added help wanted Extra attention is needed needs:engineering This requires engineering to resolve. labels Jul 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed needs:engineering This requires engineering to resolve.
Projects
Status: Incoming
Development

No branches or pull requests

2 participants