Skip to content

The task includes an option with an undefined variable. The error was: 'domains' is undefined. #34

@favour121

Description

@favour121

TASK [coopdevs.certbot_nginx : Compare domains with domains in certificate] **************************************************************************
fatal: [server-name]: FAILED! => {"msg": "The task includes an option with an undefined variable. The error was: 'domains' is undefined. 'domains' is undefined\n\nThe error appears to be in '/home/user/.ansible/roles/coopdevs.certbot_nginx/tasks/certificate.yml': line 29, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n\n- name: Compare domains with domains in certificate\n ^ here\n"}

Offending task code:

- name: Compare domains with domains in certificate
  set_fact:
    certbot_force_update: "{{ old_domains | symmetric_difference(domains) | length | bool }}"
  when: certbot_force_update is not defined

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions