nebula-release-plugin
nebula-release-plugin copied to clipboard
git-receive-pack not permitted when running candidate task with 16.0.0
We are migrating our project from nebula-release-plugin:13.0.0
to 16.0.0
and gradle 7.2
Previous branch based on nebula release 13.0.0
and gradle 6.8
runs just fine, but with 16.0.0
we are getting
org.eclipse.jgit.api.errors.TransportException: https://[email protected]/xxx/gradle-relese-test.git: git-receive-pack not permitted on 'https://[email protected]/xxxx/gradle-relese-test.git/'
We are propagating the credentials via GRGIT_USER
and GRGIT_PASS
environment variables, they ARE being picked up since I see using hardcoded credentials from system properties
log message when adding --info
option, the user is defined as project owner
in gitlab.
Please advice
Found the culprit. We are also using gradle-git-properties plugin, during migration it was upgraded to the latest 2.3.1
, which brings grgit-core:4.1.0
. 4.1.0 causes this failure with nebula-release-plugin:16.0.0
. Downgraded gradle-git-properties
to 2.2.3
and our release process is back to normal.
Please support grgit-core:4.1.0
Having the exact same problem and can't resolve. Any updates here?
Mine stems from having Nebula and se.bjurr.gitchangelog.git-changelog-gradle-plugin in the same build. When running in GitLab, I get the same "git-receive-pack not permitted" error. However, running locally, everything works fine...
@WilliamsDL It's because GitLab does the clone with the password and user in the URL, so the remote URL contains it, which in turn overrides the credentials passed by grgit. I just spent two days to debug this.
Workaround: sed -i -e "s/\(.*\):\/\/.*:.*@\(.*\)/\1:\/\/\2/" .git/config
This seems to pop out more often. Our case was to have a spring-cloud-contract-gradle-plugin, which included newer version of the jgit library then the one used in grgit coming from nebula.release. For gradle builds you can check by running
./gradlew buildEnvironment
The workaround from @ahoka worked as well.