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

Avoid uploading key in public repos #1249

Merged
merged 3 commits into from Jan 5, 2022
Merged

Avoid uploading key in public repos #1249

merged 3 commits into from Jan 5, 2022

Conversation

luizbafilho
Copy link
Contributor

Closes: #1111

What changed?

  • Avoids uploading key in public repos

Why?

  • gitops was erroring out when using public repos

How did you test it?

  • manual and unit tests

Release notes

Documentation Changes

@luizbafilho luizbafilho self-assigned this Dec 20, 2021
@luizbafilho luizbafilho added the bug Something isn't working label Dec 20, 2021
@luizbafilho luizbafilho marked this pull request as ready for review December 21, 2021 17:24
Copy link
Contributor

@josecordaz josecordaz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just a small nit


addCommand := "add app . --auto-merge=true"
configRepoURL := "ssh://git@gitlab.com/" + gitlabPublicGroup + "/" + configRepoName + ".git"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would suggest to use fmt.Sprintf to build this string for readability

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree, but I decided t keep it this way because that's how URLs are being built across the whole acceptance suite, I'd rather keep consistency over something I prefer.

Copy link
Contributor

@palemtnrider palemtnrider left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - however, I didn't see any acceptance tests using a public app repo - did I just miss it?

@luizbafilho
Copy link
Contributor Author

LGTM - however, I didn't see any acceptance tests using a public app repo - did I just miss it?

yep, they are there but didn't break because they use a private repo as config url

@jpellizzari jpellizzari merged commit 98ee691 into main Jan 5, 2022
@jpellizzari jpellizzari deleted the 1111-public-repo branch January 5, 2022 18:25
@jpellizzari jpellizzari removed their assignment Jan 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Can't add public repo that is not under the ownership of the user
4 participants