Skip to content

deployment action work #18

deployment action work

deployment action work #18

Workflow file for this run

name: Build docker image
on:
push:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: docker/build-push-action@v6
with:
push: false
tags: 'scheme-index:latest'
file: ./build/Dockerfile
- run: |
docker create --name dummy scheme-index:latest
docker cp dummy:/schemeindex.zip /tmp/schemeindex.zip
docker rm -f dummy
- uses: actions/upload-artifact@v4
with:
name: schemeindex
path: /tmp/schemeindex.zip
deploy_ansible:
needs:
- build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v4
with:
name: schemeindex
- run: |
mv /schemeindex.zip ./build/schemeindex.zip
apt-get install ansible
cd deploy
ansible-playbook -i hosts deploy.yml