Hello,
I am new to Ansible and trying to use the docker module to start docker
containers. I have installed all the prereqs (python, docker-py &
docker.io) on the docker host but seem to be getting this syntax error. Any
idea on whats wrong here ?
$ ansible-playbook -vvvv -i hosts ../wildfly-docker.yml
ERROR: Syntax Error while loading YAML script, ../wildfly-docker.yml
Note: The error may actually appear before this position: line 7, column 5
docker:
name: wildfly-1
^
---------------------------------
My ansible playbook file
---------------------------------
---
- hosts: docker
sudo: yes
tasks:
- name: Wildfly container#1
docker:
name: wildfly-1
image: jboss/wildfly
state: reloaded
pull: always
ports:
- "8081:8080"
- "9991:9990"
- name: Wildfly container#2
docker:
name: wildfly-2
image: jboss/wildfly
state: reloaded
pull: always
ports:
- "8082:8080"
- "9992:9990"
Thanks
--
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/745f23f6-675c-40bb-b8f9-bc3bab0cdc70%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.