A0deploy CLI tool can import structure fine, but GitHub deploy errors "Conflict: A client grant already exists"

I’m migrating one of our tenants configuration into GitHub so we can track changes, auto-deploy, etc.

Following the import/export to dir structure docs I created a git repo that seems to match our existing structure (using a0deploy export ...). I even got to a state (after a few fixes) where I can use a0deploy import ... and the tool succeeds, pushing changes up to our tenant’s deployment.

However, the same git repository fails to auto-deploy when we push to our deploy branch. It looks like installing the GitHub Deployments extension created a new auth0-github-deploy application — say with id ‘abc123’ for now — and the error message returned when either pushing to our deploy branch in GitHub or when manually triggering this is "Problem creating clientGrants … Conflict: A client grant already exists between abc123 and "

It strikes me as suspicious that the GitHub extension is failing to deploy on the same application ID that it’s using to connect, and I’m not sure how to work around the problem without removing the GitHub extension and just using a0deploy in our own CI/CD pipeline.

Hey jgale,

I was facing the same frustrating issue and what I figured the fix was removing the grant for the auth0-github-deploy application. I am assuming in your Github repository you have a directory for the Auth0 config and in that directory you have a grants directory. I would suggest trying to remove the grant for the auth0-github-deploy as this fixed the issue for me.

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.