Local Dev/Debug with GHES and public github.com #32908
Replies: 2 comments
-
Dependencies under |
Beta Was this translation helpful? Give feedback.
-
I'm in the same situation and wanted to test local dry-runs. I fought with this same thing so much tonight. This is as close as I got. It's not perfect and breaks a couple of managers? But it at least partially works... I was able to debug against GHES. export RENOVATE_TOKEN=$(gh auth token -h myghes.com -u myuser)
export RENOVATE_DETECT_GLOBAL_MANAGER_CONFIG=true
export LOG_LEVEL="debug"
export GITHUB_COM_TOKEN=$(gh auth token -h github.com)
export RENOVATE_FORCE='{"redisUrl": null, "extends": ["config:recommended"], "defaultRegistryUrls": ["https://myghes.com", "https://github.com"]}'
export RENOVATE_HOST_RULES="[{\"matchHost\": \"myghes.com\", \"token\": \"$RENOVATE_TOKEN\"}]"
renovate --dry-run=full --platform=local We should be able to limit defaultRegistryUrls to the github-only packages with a packageRule, but for the life of me it would just simply ignore it. Using RENOVATE_FORCE is the only thing that finally got it to even look at GHES. |
Beta Was this translation helpful? Give feedback.
-
How are you running Renovate?
Self-hosted Renovate
If you're self-hosting Renovate, tell us which platform (GitHub, GitLab, etc) and which version of Renovate.
GitHub Enterprise Server
Please tell us more about your question or problem
I'm trying to develop and debug a renovate config for a specific repository on a pre-existing repository in our Github Enterprise Server, and would like to develop and debug locally without committing changes. I found that the renovate cli supports dry-run, which is exactly what I want.
The problem is that I'm not sure how to get the cli to work properly. Some dependencies are on our local GHES while others are in public github.com. I'm providing the endpoint and token for our GHES on the cli, but it still says
GitHub token is required for some dependencies
. Some of those dependencies are on the local GHES... so why are they not being discovered? And then how do I provide a token for the public github.com?If I try to change the provider to local, how do I specify PATs for GHES and github.com, and map dependencies to the right places?
See logs:
Logs (if relevant)
Logs
renovate.json5:
provider=github
provider=local
Beta Was this translation helpful? Give feedback.
All reactions