-
Notifications
You must be signed in to change notification settings - Fork 265
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added support for ssh signed commits and completed gpg signed commit …
…work Signed-off-by: Dustin Lactin <[email protected]>
- Loading branch information
Showing
11 changed files
with
210 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -221,6 +221,8 @@ func newRunCommand() *cobra.Command { | |
runCmd.Flags().BoolVar(&warmUpCache, "warmup-cache", true, "whether to perform a cache warm-up on startup") | ||
runCmd.Flags().StringVar(&cfg.GitCommitUser, "git-commit-user", env.GetStringVal("GIT_COMMIT_USER", "argocd-image-updater"), "Username to use for Git commits") | ||
runCmd.Flags().StringVar(&cfg.GitCommitMail, "git-commit-email", env.GetStringVal("GIT_COMMIT_EMAIL", "[email protected]"), "E-Mail address to use for Git commits") | ||
runCmd.Flags().StringVar(&cfg.GitCommitSigningKey, "git-commit-signing-key", env.GetStringVal("GIT_COMMIT_SIGNING_KEY", ""), "GnuPG key ID or path to Public SSH Key used to sign the commits") | ||
runCmd.Flags().BoolVar(&cfg.GitCommitSignOff, "git-commit-sign-off", env.GetBoolVal("GIT_COMMIT_SIGN_OFF", false), "Whether to sign-off git commits") | ||
runCmd.Flags().StringVar(&commitMessagePath, "git-commit-message-path", defaultCommitTemplatePath, "Path to a template to use for Git commit messages") | ||
runCmd.Flags().BoolVar(&cfg.DisableKubeEvents, "disable-kube-events", env.GetBoolVal("IMAGE_UPDATER_KUBE_EVENTS", false), "Disable kubernetes events") | ||
|
||
|
@@ -300,15 +302,17 @@ func runImageUpdater(cfg *ImageUpdaterConfig, warmUp bool) (argocd.ImageUpdaterR | |
defer sem.Release(1) | ||
log.Debugf("Processing application %s", app) | ||
upconf := &argocd.UpdateConfiguration{ | ||
NewRegFN: registry.NewClient, | ||
ArgoClient: cfg.ArgoClient, | ||
KubeClient: cfg.KubeClient, | ||
UpdateApp: &curApplication, | ||
DryRun: dryRun, | ||
GitCommitUser: cfg.GitCommitUser, | ||
GitCommitEmail: cfg.GitCommitMail, | ||
GitCommitMessage: cfg.GitCommitMessage, | ||
DisableKubeEvents: cfg.DisableKubeEvents, | ||
NewRegFN: registry.NewClient, | ||
ArgoClient: cfg.ArgoClient, | ||
KubeClient: cfg.KubeClient, | ||
UpdateApp: &curApplication, | ||
DryRun: dryRun, | ||
GitCommitUser: cfg.GitCommitUser, | ||
GitCommitEmail: cfg.GitCommitMail, | ||
GitCommitMessage: cfg.GitCommitMessage, | ||
GitCommitSigningKey: cfg.GitCommitSigningKey, | ||
GitCommitSignOff: cfg.GitCommitSignOff, | ||
DisableKubeEvents: cfg.DisableKubeEvents, | ||
} | ||
res := argocd.UpdateApplication(upconf, syncState) | ||
result.NumApplicationsProcessed += 1 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.