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

Gitlab Webhook: Configure to use ssh repository rather than https #140

Closed
wilfriedwolf opened this issue Jun 12, 2020 · 4 comments
Closed
Labels

Comments

@wilfriedwolf
Copy link
Contributor

Hi there,

I'm just about to upgrade my satisfy instance which we are now using perfectly for some years. By then, I wrote a gitlab webhook which still works, but I'd rather use yours, since it can create repositories - great feature.

My problem is, that we are using [email protected]:group/repo.git for the repositories and not
https://gitlab.example.com/group/repo.git, which gets written in satis.json when executing a webhook on a nonexisting repository.

I was playing arround a little, trying to adopt the https way, but I was not successful, since our repos are all private.
I even created an auth.json with the credentials of a user having access to our repo, but on executing

$ bin/satis build satis.json public --skip-errors --no-ansi --verbose --repository-url=https://gitlab.example.com/group/repo.git --repository-strict

I always get the username promt, so that does not work (or at least I have not found out how to configure it correctly)

My proposal now is to enable configuring the prefered clone url. I found the place where to do it, and I'll do a pull request, if you think this could be a good idea.

Never the less: how are you supposed to handle private gitlab projects?

Best regards,

Willi

@ramunasd
Copy link
Collaborator

Just change ordering here https://github.com/ludofleury/satisfy/blob/master/src/Playbloom/Satisfy/Webhook/GitlabWebhook.php#L58 , write a test and submit PR. I would love to review it ;)

@wilfriedwolf
Copy link
Contributor Author

The orderings allready changes, and I am willing to write a test, but.. never done it before :( What framework do you use, could you just give me a hint, how to start?

@ramunasd
Copy link
Collaborator

We use phpunit. There is plenty of tutorials on the web.

@wilfriedwolf
Copy link
Contributor Author

wilfriedwolf commented Jun 16, 2020 via email

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

No branches or pull requests

2 participants