Skip to content

Merge pull request #19 from leandrodalbo/api-dns #12

Merge pull request #19 from leandrodalbo/api-dns

Merge pull request #19 from leandrodalbo/api-dns #12

Workflow file for this run

name: Publish
on:
push:
branches:
- "main"
jobs:
build:
name: Build
runs-on: ubuntu-22.04
env:
DEPLOY_DESTINATION: ${{ secrets.DEPLOY_DESTINATION }}
DEPLOY_PORT: ${{ secrets.DEPLOY_PORT }}
SSHKEY: ${{ secrets.SSHKEY }}
SSH_AUTH_SOCK: /tmp/ssh_agent.sock
strategy:
matrix:
node-version: [23.x]
permissions:
contents: read
security-events: write
steps:
- name: Checkout Code
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Install dependendencies
run: npm install
- name: Test
run: npm run test
- name: Build
run: npm run build
- name: Deploy
run: |
ssh-agent -a $SSH_AUTH_SOCK > /dev/null
ssh-add - <<< "${{ env.SSHKEY }}" > /dev/null
scp -P ${{ env.DEPLOY_PORT }} -o StrictHostKeyChecking=no -r dist/* ${{ env.DEPLOY_DESTINATION }} > /dev/null