versão 0.10.2 #30
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Atualizar | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
app_publish: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Git pull | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 1 | |
- name: Baixa KeyPair | |
run: | | |
echo "${{ secrets.KEYPAIR_PEM }}" > keypair.pem | |
sudo chmod 400 keypair.pem | |
- name: Adiciona ao known_hosts | |
shell: bash | |
run: | | |
mkdir -p ~/.ssh/ | |
ssh-keyscan -H ${{ secrets.INSTANCE_IP }} >> ~/.ssh/known_hosts | |
sudo chmod 600 ~/.ssh/known_hosts | |
- name: Altera versão node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 20.12.2 | |
- name: Compila | |
shell: bash | |
run: ./bin/build.sh | |
- name: Atualiza | |
run: rsync -e "ssh -i keypair.pem" -av dist/* ${{ secrets.INSTANCE_USER }}@${{ secrets.INSTANCE_IP }}:/var/www/docker/opencvflowdocs/online/ |