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

list, add and remove of labels does not work with ec2 instances #43

Open
cgrigor opened this issue Jun 8, 2018 · 1 comment
Open

list, add and remove of labels does not work with ec2 instances #43

cgrigor opened this issue Jun 8, 2018 · 1 comment

Comments

@cgrigor
Copy link

cgrigor commented Jun 8, 2018

Hi,

When deploying to ec2-instances the {{ ansible_hostname }} that is returned by Ansible is a shortened version, which makes the following tasks fail.

  • name: Get list of labels
    ...
  • name: Remove labels from swarm node
    ...
  • name: Asign labels to swarm nodes | if any
    ...

Example:
returned value by ansible in var {{ ansible_hostname }} = ip-10-210-154-89

value required by swarm
ip-10-210-154-89.us-west-1.compute.internal

Ansible provides the fqdn in a var called {{ ansible_fqdn }}

I updated the above tasks to use {{ ansible_fqdn }} and this worked.
Thanks,
Chris

@chris-str-cst
Copy link

It can't work because the version you get with ansible-galaxy install atosatto.docker-swarm is not the version shown here. The tasks are missing on the galaxy. The owner needs to update it on ansible-galaxy.

Check out your $HOME/.ansible/roles/atosatto.docker-swarm/tasks/swarm_cluster.yml

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

2 participants