This message was deleted.
# general
This message was deleted.
could you share the error you are getting from your playbook in this thread for a little more context? the user logging in on the nodes needs to be part of the docker users. So I assume when you do
rke up
it must be a different user/key used to authenticate.
- name: Run RKE installer become: yes shell: rke up args: chdir: "{{ rke_config_dir }}" delegate_to: localhost become_user: "{{ username }}" register: result
{{ username }} is rke
output error:
the ssh keys all work using user rke to lgin to remote hosts
issue is executing the ansible task using the ansible user
rke up works fine too using rk user
you're testing rke up and your ansible rke up are conflicting with each other it seems:
Copy code
[k8node01]: Error response from daemon: Conflict. The container name \\\"/rke-etcd-port-listener\\\" is already in use by container
I would clean up the node - try it with ansible only - then report back if you get any errors. The errors you posted above just say you're trying to install rke on a node that already has rke running.
ok I clean up the nodes and ran a single play and works
--- - hosts: localhost name: test tasks: - name: run rke installer shell: 'rke up' args: chdir: "/home/rke" become: yes become_user: "rke" delegate_to: localhost register: result - debug: msg: "{{ result }} "
but putting this play as part of a task in the pb is not working