]> git.ipfire.org Git - thirdparty/google/fonts.git/commitdiff
Keep fontspector database on remote server
authorSimon Cozens <simon@simon-cozens.org>
Tue, 22 Apr 2025 09:06:23 +0000 (10:06 +0100)
committerSimon Cozens <simon@simon-cozens.org>
Tue, 22 Apr 2025 09:06:23 +0000 (10:06 +0100)
.github/workflows/fontspectorall.yaml

index 6cabf74efc22d6c37f098b263c54d413413457d3..ec2e42003b840c0d87d85f34658bd3f89e9f4d3f 100644 (file)
@@ -13,7 +13,16 @@ jobs:
           ref: main
           lfs: true
       - name: Grab fontspector database
-        run: git fetch origin gh-pages; git checkout gh-pages; cp fontspector-dashboard/fontspector.db . ; git checkout main
+        run: |
+          mkdir -p ~/.ssh/
+          echo "$CORVEL_SSH_PRIVATE_KEY" > ../private.key
+          sudo chmod 600 ../private.key
+          echo "$CORVEL_KNOWNHOSTS" > ~/.ssh/known_hosts
+          scp -i ../private.key fontspector@corvelsoftware.co.uk:fontspector.db .
+        shell: bash
+        env:
+          CORVEL_SSH_PRIVATE_KEY: ${{secrets.CORVEL_SSH_PRIVATE_KEY}}
+          CORVEL_KNOWNHOSTS: ${{secrets.CORVEL_KNOWNHOSTS}}
       - name: Install protoc
         run: brew install protobuf
       - name: Install Rust
@@ -25,7 +34,7 @@ jobs:
       - name: Build dashboard
         run: cd .ci/fontspector-dashboard && npm install && npm run build
       - name: Stash database again
-        run: cp fontspector.db fontspector-dashboard-build/
+        run: "scp -i ../private.key fontspector.db fontspector@corvelsoftware.co.uk:"
       - name: Add to branch
         run: git checkout gh-pages; git rm -rf fontspector-dashboard || true; rm -rf fontspector-dashboard || true; mv fontspector-dashboard-build fontspector-dashboard
       - name: Upload results