-
Notifications
You must be signed in to change notification settings - Fork 132
how to resolve FQCN error? #99
Comments
I was able to get this working: (this doesn't cover the action part) $ ansible-galaxy collection install community.general ---
- name: timezone
hosts: all
gather_facts: true
vars:
tz: Asia/Tokyo
tasks:
- name: "Set the timezone. {{ tz }}"
community.general.timezone:
name: "{{ tz }}"
failed_when: false |
@ssbarnea @cidrblock thank you! I could complete. my repo(ommit)
my wf
|
wooops
|
I'm seeing this issue with ansible-lint 6.10.0 even after adding the
Here's an example job: https://github.com/smrealms/seed-server/actions/runs/3783650542/jobs/6432363437 And here's what my ---
collections:
- community.general
roles:
- src: geerlingguy.docker
version: 5.2.1
- src: hifis.unattended_upgrades
version: v1.12.2 Am I doing something wrong here? Thanks! |
see https://docs.ansible.com/ansible/latest/galaxy/user_guide.html
and old version
I think, maybe not installed colections. |
@officel Thanks for the pointers! I should have clarified that this is only an issue in the GitHub Action (locally, where I do have |
I see. Then it does not seem necessary. |
I checked again. ansible-lint-action uses creator-ee with docker. creator-ee automatically reads requirements.yml in the top directory of the repository. So when we use this ansible-lint-action, we need to put the collections in our requirements.yml. No problem. |
@hemberger Did you get this working? I've modified my action to install the requirements from the root like so:
But I'm still getting FQCN resolution failures. Collections
|
No, I haven't been able to get this to work either. Since ansible-lint is running in a docker container, my suspicion is that it will require changes to the creator-ee image or ansible-lint itself. ansible-lint-action/action.yml Lines 24 to 27 in dd22547
|
Bummer. @ssbarnea Any ideas on this one? |
You must have a requirements.yml file on your repo so linter could install these deps itself! Running galaxy before the action does not help as that is not inside the action container. |
Thanks for the quick response! In my example job above (#99 (comment)), I have |
Fair point. Can we override the path to avoid pushing the galaxy file into root? |
@Schachte You can pass |
Was there ever a solution to this? I have a chicken-egg-problem: when I put community.general into the requirements.yml I get an error that If I do not have community.general in the requirements.yml I get errors with playbooks that use modules from community.general that the dependencies are not in the requirements.yml. |
I've solved it by reverting to https://github.com/ansible/ansible-lint-action@v6.11.0 from current @main - which uses 6.14.4. |
Same issue here, when i move back to v6.11.0 as suggested by @barzog it solves the issue but now my linter is buggy because of a loop-var-prefix[wrong] false positive, that seems to be fixed in a newer version of the linter... |
It works fine locally, but FQCN seems to error in this actions.
playbooks
local run(it's ok)
Could you please tell me how to do this? 🙇
The text was updated successfully, but these errors were encountered: