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

Ansible Galaxy imports failing #143

Open
markgoddard opened this issue Apr 13, 2023 · 7 comments
Open

Ansible Galaxy imports failing #143

markgoddard opened this issue Apr 13, 2023 · 7 comments

Comments

@markgoddard
Copy link
Collaborator

We have an action to automatically import this role, but it seems to be failing: https://github.com/michaelrigart/ansible-role-interfaces/actions/workflows/publish-role.yml

@cityofships
Copy link
Contributor

cityofships commented Jul 25, 2023

Is this because GALAXY_API_KEY secret is missing?

@markgoddard
Copy link
Collaborator Author

Yes, I expect so. @michaelrigart , are you able to set this secret for the repo?

@michaelrigart
Copy link
Owner

michaelrigart commented Jul 26, 2023

@markgoddard : I just set the Ansible API key as repo secret, but the action still seems to fail.

Could this be due to the capitalization of my Galaxy username MichaelRigart vs small-caps on github (michaelrigart), since the command it runs is: ansible-galaxy import michaelrigart xyz?

@cityofships
Copy link
Contributor

@markgoddard : I just set the Ansible API key as repo secret, but the action still seems to fail.

Could this be due to the capitalization of my Galaxy username MichaelRigart vs small-caps on github (michaelrigart), since the command it runs is: ansible-galaxy import michaelrigart xyz?

Yes, that's the reason - gives 500 if tried from command line too.

@michaelrigart
Copy link
Owner

It seems that I can't change the namespace on Galaxy neither.

@michaelrigart
Copy link
Owner

I have created an issue on the Galaxy GH repo. Hopefully it can be resolved: ansible/galaxy#3217

@markgoddard
Copy link
Collaborator Author

Since the roll out of Galaxy NG there is no UI for importing roles, and when I tried to do it manually it took a few goes to make it work.

First, you need to use the capitalised MichaelRigart namespace. Next, you need to specify the tag via --branch, otherwise it uploads the master branch.

ansible-galaxy role import MichaelRigart ansible-role-interfaces  --api-key <key> --branch v1.14.4

I've updated the GitHub actions publish workflow to do this, but unfortunately it failed with a 403. @michaelrigart perhaps you need to regenerate a new API token for NG galaxy?

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

No branches or pull requests

3 participants