Skip to content

Include handlers error make domserver #181

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

Closed
BHenkemans opened this issue May 6, 2025 · 1 comment · Fixed by #182
Closed

Include handlers error make domserver #181

BHenkemans opened this issue May 6, 2025 · 1 comment · Fixed by #182

Comments

@BHenkemans
Copy link
Contributor

While running make domserver I encountered the following error:

ERROR! this task 'include' has extra params, which is only allowed in the following modules: raw, include_role, win_shell, include_tasks, meta, shell, command, set_fact, add_host, import_tasks, script, group_by, import_role, win_command, include_vars

The error appears to be in '/home/gehack/domjudge-scripts/provision-contest/ansible/domserver.yml': line 62, column 7, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

  handlers:
    - include: handlers.yml
      ^ here
make: *** [Makefile:37: domserver] Error 4

I resolved this by changing

  handlers:
    - include: handlers.yml

to

  handlers:
    - import_tasks: handlers.yml

This may be an issue in other files too. This is my ansible version

ansible [core 2.18.5]
  config file = /home/gehack/domjudge-scripts/provision-contest/ansible/ansible.cfg
  configured module search path = ['/home/gehack/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /home/gehack/.local/share/pipx/venvs/ansible/lib/python3.12/site-packages/ansible
  ansible collection location = /home/gehack/.ansible/collections:/usr/share/ansible/collections
  executable location = /home/gehack/.local/bin/ansible
  python version = 3.12.3 (main, Feb  4 2025, 14:48:35) [GCC 13.3.0] (/home/gehack/.local/share/pipx/venvs/ansible/bin/python)
  jinja version = 3.1.6
  libyaml = True
@vmcj
Copy link
Member

vmcj commented May 6, 2025

@BHenkemans, are you willing to create a PR for this?

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

Successfully merging a pull request may close this issue.

2 participants