image: geerlingguy/docker-debian9-ansible before_script: - which ssh-agent || ( apt-get update -qq -y && apt-get install openssh-client -qq -y ) - eval $(ssh-agent -s) - echo "$SSH_PRIVATE_KEY" | tr -d '\r' | ssh-add - > /dev/null - mkdir -p ~/.ssh - chmod 700 ~/.ssh deploy_to_webserver: stage: deploy only: - master script: - echo -e "$HIFIVE" > /etc/ansible/hosts - cat /etc/ansible/hosts - ansible-playbook ops/ansible/httpd-centos.yml - find / -name ansible.cfg - cat /root/ansible.cfg when: manual