Morgan McMillian
54cf73f885
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
25 lines
650 B
YAML
25 lines
650 B
YAML
pipeline:
|
|
test:
|
|
image: alpine:latest
|
|
secrets: [ ssh_key ]
|
|
environment:
|
|
- ANSIBLE_PRIVATE_KEY=$SSH_KEY
|
|
- ANSIBLE_HOST_KEY_CHECKING=False
|
|
commands:
|
|
- apk add --update ansible
|
|
- printf "$SSH_KEY" > /tmp/privateKey
|
|
- chmod 600 /tmp/privateKey
|
|
- sha256sum /tmp/privateKey
|
|
- ansible-playbook --user igor --inventory hosts.ini --private-key /tmp/privateKey main.yml
|
|
|
|
# publish:
|
|
# image: plugins/ansible
|
|
# pull: true
|
|
# secrets: [ ssh_key ]
|
|
# settings:
|
|
# playbook: main.yml
|
|
# inventory: hosts.ini
|
|
# connection: paramiko_ssh
|
|
# user: igor
|
|
# private_key: $SSH_KEY
|