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

Check if remote branch exists before creating new one #503

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

michalschott
Copy link

This should fix issue 433

My idea is to update logic so it:

  • check if remote branch exists
  • if so, do checkout and rebase against source branch
  • if no, process as it is

So annoying to see controller spamming with

argocd-image-updater-5d5c9cf6f4-nhtph argocd-image-updater time="2022-12-12T16:14:40Z" level=error msg="Could not update application spec: could not push image-updater-jetstack/cert-manager-cainjector-v1.7.3-jetstack/cert-manager-controller-v1.7.3-jetstack/cert-manager-webhook-v1.7.3 to origin: `git push origin image-updater-jetstack/cert-manager-cainjector-v1.7.3-jetstack/cert-manager-controller-v1.7.3-jetstack/cert-manager-webhook-v1.7.3` failed exit status 1: Warning: Permanently added 'bitbucket.org' (RSA) to the list of known hosts.\r\nTo [redacted]\n ! [rejected]        image-updater-jetstack/cert-manager-cainjector-v1.7.3-jetstack/cert-manager-controller-v1.7.3-jetstack/cert-manager-webhook-v1.7.3 -> image-updater-jetstack/cert-manager-cainjector-v1.7.3-jetstack/cert-manager-controller-v1.7.3-jetstack/cert-manager-webhook-v1.7.3 (non-fast-forward)\nerror: failed to push some refs to '[redacted]'\nhint: Updates were rejected because the tip of your current branch is behind\nhint: its remote counterpart. Integrate the remote changes (e.g.\nhint: 'git pull ...') before pushing again.\nhint: See the 'Note about fast-forwards' in 'git push --help' for details." application=cert-manager

@CLAassistant
Copy link

CLAassistant commented Dec 12, 2022

CLA assistant check
All committers have signed the CLA.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Force Pushing to Write Back Branch
2 participants