chore(deps): bump virtua from 0.48.2 to 0.49.0 #13
This file contains hidden or 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: Deploy Worldstream | |
| on: | |
| workflow_dispatch: | |
| push: | |
| branches: | |
| - main | |
| concurrency: | |
| group: deploy-worldstream-${{ github.ref }} | |
| cancel-in-progress: false | |
| jobs: | |
| deploy-worldstream: | |
| name: Deploy Worldstream | |
| runs-on: ubuntu-latest | |
| env: | |
| MACHINE: hey-xyz-worldstream | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Connect to Tailscale | |
| uses: tailscale/github-action@v4 | |
| with: | |
| oauth-client-id: ${{ secrets.TS_OAUTH_CLIENT_ID }} | |
| oauth-secret: ${{ secrets.TS_OAUTH_SECRET }} | |
| tags: tag:ci | |
| hostname: deploy-hey-xyz-worldstream-${{ github.run_id }} | |
| ping: ${{ env.MACHINE }} | |
| version: latest | |
| - name: Add SSH key | |
| env: | |
| SSH_KEY: ${{ secrets.SSH_KEY_WORLDSTREAM }} | |
| SSH_AUTH_SOCK: /tmp/ssh_agent.sock | |
| run: | | |
| mkdir -p ~/.ssh | |
| MACHINE_IP="$(tailscale ip -4 $MACHINE)" | |
| ssh-keyscan $MACHINE_IP >> ~/.ssh/known_hosts | |
| echo "$SSH_KEY" | tr -d '\r' > ~/.ssh/key | |
| chmod 600 ~/.ssh/key | |
| ssh-agent -a $SSH_AUTH_SOCK > /dev/null | |
| ssh-add ~/.ssh/key | |
| - name: Deploy | |
| run: | | |
| MACHINE_IP="$(tailscale ip -4 $MACHINE)" | |
| USERHOST="root@$MACHINE_IP" | |
| COMMAND="cd hey.xyz && git pull --ff-only && pnpm install --frozen-lockfile && pnpm build && pm2 restart hey.xyz --update-env" | |
| ssh $USERHOST "$COMMAND" |