Test SSH (actions)

Signed-off-by: Nick Slowinski <nick@nick-slowinski.de>
Dieser Commit ist enthalten in:
Nick Slowinski 2024-08-05 18:50:59 +02:00
Ursprung 947a678108
Commit 02d45eb921
Signiert von: nickslowinski
GPG-Schlüssel-ID: A28671573AA347CC

Datei anzeigen

@ -1,16 +1,6 @@
name: Build and deploy website name: Build and deploy website
on: on:
workflow_dispatch: workflow_dispatch:
inputs:
logLevel:
description: 'Log Level'
required: true
default: 'warning'
type: choice
options:
- info
- warning
- debug
jobs: jobs:
build: build:
@ -26,3 +16,15 @@ jobs:
- name: Build site - name: Build site
run: npm run build run: npm run build
- name: Configure SSH
run: |
mkdir -p ~/.ssh/
echo "$SSH_KEY" | tr -d '\r' > ~/.ssh/actions.key
chmod 600 ~/.ssh/actions.key
env:
SSH_USER: ${{ secrets.WEB_SSH_USER }}
SSH_KEY: ${{ secrets.WEB_SSH_KEY }}
- name: Test SSH
run: ssh -i ~/.ssh/actions.key $SSH_USER@be.nick-slowinski.de uptime