Skip to content

fix: test server connection #3

fix: test server connection

fix: test server connection #3

Workflow file for this run

name: Save changes on server (test)
on:
push:
branches:
- main
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Set up SSH
uses: webfactory/ssh-agent@v0.5.3
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- name: Add server to known_hosts
run: |
mkdir -p ~/.ssh
ssh-keyscan -H ${{ secrets.SERVER_IP }} >> ~/.ssh/known_hosts
- name: Server connection
run: |
ssh ${{ secrets.SERVER_USER }}@${{ secrets.SERVER_IP }} "cd /home/projects && mkdir test_actions"