0e4d56291ae1d25392245d6a5a0cab3426e9d2bc

Author
Ayman Bagabas <ayman.bagabas@gmail.com>
Committer
Ayman Bagabas <ayman.bagabas@gmail.com>
Date

Message

Use soft-serve action

Diff

 1diff --git a/.github/workflows/soft-serve.yml b/.github/workflows/soft-serve.yml
 2index 153dda9d1c166b678b6d709547caf3e316083863..311bb63f478aaeb2b7b0d93f3da03d7da35a34a2 100644
 3--- a/.github/workflows/soft-serve.yml
 4+++ b/.github/workflows/soft-serve.yml
 5@@ -8,12 +8,6 @@ on:
 6 jobs:
 7   softserve:
 8     runs-on: ubuntu-latest
 9-    env:
10-      CHARM_SOFT_SERVE_KEY: "${{ secrets.CHARM_SOFT_SERVE_KEY }}"
11-      SERVER: beta.charm.sh
12-      SSH_AUTH_SOCK: /tmp/ssh_agent.sock
13-      PUSH_TO: "soft-serve"
14-
15     steps:
16       - name: Checkout code
17         uses: actions/checkout@v2
18@@ -21,16 +15,8 @@ jobs:
19           fetch-depth: 0
20 
21       - name: Push to Soft-Serve
22-        run: |
23-          # Add ssh key
24-          mkdir -p ~/.ssh
25-          ssh-keyscan $SERVER >> ~/.ssh/known_hosts
26-          echo "$CHARM_SOFT_SERVE_KEY" > ~/.ssh/charm_soft_serve_id_rsa
27-          chmod 0600 ~/.ssh/charm_soft_serve_id_rsa
28-          eval "$(ssh-agent -a $SSH_AUTH_SOCK)"
29-          ssh-add ~/.ssh/charm_soft_serve_id_rsa
30-          # Add remote
31-          git remote add soft-serve ssh://$SERVER/$PUSH_TO
32-          # Push to soft-serve
33-          git push -f soft-serve HEAD:master
34-          rm -rf ~/.ssh/charm_soft_serve_id_rsa
35+        uses: charmbracelet/soft-serve-action@v1
36+        with:
37+          server: "beta.charm.sh"
38+          ssh-key: "${{ secrets.CHARM_SOFT_SERVE_KEY }}"
39+          name: "soft-serve"