1
Fork 0

Add deploy action

This commit is contained in:
Hadeed 2023-08-21 21:12:02 +05:00
parent 91d529682d
commit c250bdf00f
2 changed files with 24 additions and 1 deletions

View file

@ -0,0 +1,22 @@
on: [push]
jobs:
test:
runs-on: docker
container:
image: alpine:latest
steps:
- name: Install SSH
run: apk --no-cache add openssh-client
shell: sh
- name: Configure SSH
run: |
mkdir -p ~/.ssh/
chmod 700 ~/.ssh/
echo "${{ secrets.SSH_KEY }}" > ~/.ssh/staging.key
chmod 600 ~/.ssh/staging.key
shell: sh
- name: Test SSH
run: ssh -i ~/.ssh/staging.key -o StrictHostKeyChecking=no hadeed@hadeedahmad.xyz 'cd nginx/www; git pull'
shell: sh

View file

@ -3,6 +3,7 @@
<title>Home - Hadeed Ahmad</title>
</head>
<body>
<p>Welcome to my website</p>
<p>Welcome to my website!</p>
<p>There's not much right now, but soon this will be quite nice.</p>
</body>
</html>