Skip to content

Release to Production #1

Release to Production

Release to Production #1

name: Release to Production
on:
workflow_call:
workflow_dispatch:
jobs:
ssh-to-digiocean-and-upgrade:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Ansible
run: sudo apt-get update && sudo apt-get install -y ansible
- name: Run ansible playbook installing docker
run: |
mkdir -p .ssh
cd ansible
echo '${{ secrets.DIGITAL_OCEAN_ROOT }}' >> .ssh/digital-ocean-root
ansible-playbook install-upgrade-docker.yaml -i inventory.yaml -e "ansible_user=root" --private-key "${HOME}"/.ssh/digital-ocean-root
- name: Run Ansible Playbook starting container
run: |
mkdir -p .ssh
cd ansible
echo '${{ secrets.DIGITAL_OCEAN_PLAYTECHNIQUE }}' >> .ssh/digital-ocean-playtechnique
ansible-playbook install-upgrade-docker.yaml -i inventory.yaml -e "ssl_private_key=${{ secrets.SSL_PRIVATE_KEY }}" \
-e "ssl_certificate=${{ secrets.SSL_CERTIFICATE }}" -e "ansible_user=root" --private-key "${HOME}"/.ssh/digital-ocean-playtechnique