So i have the role riemers.gitlab-runner. It had almost 1 mil downloads, so was pretty proud about that. Now bump into this whole galaxy update that is just a pain to begin with.
I tried to use the cli, documentation is beyond bad since all over the place it still refers to old ansible-galaxy methods (i can understand it takes time to find all)
Long story short, i did a import of my role to get a new version out the door but my github repo name is sligthly different then the role name. So github has ansible-gitlab-runner as name, role is gitlab-runner. So by mistake i had now 2 roles. 1 with the latest version and 1 with the old versions and proper downloads.
So yeah, i thought lets just remove the wrong role by deleting it. So i said ansible-galaxy delete riemers ansible-gitlab-runner because i wanted to get rid of that role. And after that it deleted BOTH roles. Including my old one.
I did an import after that which now has 1 update, no version history and no downloads showing at all anymore.
Can anyone pretty please do some magic to revert this or import it from the old galaxy so i can then update it with the proper command? Not to mention people might actually use it and it breaks if they are pinned on a certain version ;(
Hello @riemers , thanks for your report. Let’s see if the @galaxy team can help with your request for a rollback or restore.
Regarding the issue with ansible-galaxy delete deleting both roles, that seems weird and might be a bug, although I notice you used the namespace for the old role in that line. Was that the exact command that caused the issue?
I will try to replicate that and see what I come up with. If that’s an issue, the ansible-galaxy command line tool is independent from “Ansible Galaxy the Web Interface” and is managed by the ansible-core team, so we would need to split both issues.
About the docs, please report the outdated docs you find to help the community and the @Docs Working Group fix them. If you have any bookmarked, we would appreciate you provide references here.
You can even submit a PR to update something you noticed if you want to contribute directly. As you said, sometimes updating everything everywhere is hard.
Again, thanks for your reports and your contribution to the collection ecosystem!
And as always, it is the community that does the work. I think the whole galaxy exist because of community members. The whole fact that there is 0 communications from anyone from the galaxy team is just really really bad.
At this point i am throwing in the towel. After having 1 mil downloads with a role i would say i did my best to support the community with something. I feel sad that it has come this way. I don’t work for ansible galaxy, i don’t get payed for it and i certainly don’t intend to spend my time to fix/work on stuff that someone broke there.
This is another thread that got lost among all the other ones, apologies for that.
I’ve corrected the roles mentioned via the following steps:
ansible-galaxy role import --role-name=gitlab-runner riemers ansible-gitlab-runner … this brought the riemers.gitlab-runner role back into the system with all of it’s versions.
In the database, I set the download count for the role to 982975 based on the value in old-galaxy.
Deleted the bad role via curl … curl -X DELETE -H 'Authorization: token MYTOKEN' https://galaxy.ansible.com/api/v1/roles/37080/
I think that leaves us in the state you asked for in this post …
We’ve revamped the backend import code to allow the --role-name parameter to work correctly AND for you to be able to set the value for the name and the namespace in meta/main.yml
In this case, you should always pass --role-name=gitlab-runner for your imports.