+31
-31
.tangled/workflows/build.yml
+31
-31
.tangled/workflows/build.yml
···
1
1
when:
2
-
- event: ["push", "manual"]
3
-
branch: ["main"]
2
+
- event: ["push", "manual"]
3
+
branch: ["main"]
4
4
5
5
engine: "nixery"
6
6
7
7
dependencies:
8
-
nixpkgs:
9
-
- deno
8
+
nixpkgs:
9
+
- deno
10
10
11
11
steps:
12
-
- name: "Build static files"
13
-
command: "deno run build"
14
-
15
-
- name: "SSH setup"
16
-
command: |
17
-
mkdir ~/.ssh
18
-
echo "${{secrets.SSH_KEY}}" > ~/.ssh/id_tangledsh
19
-
chmod 600 ~/.ssh/id_tangledsh
20
-
cat > ~/.ssh/config << EOF
21
-
Host deploy
22
-
HostName ${{ secrets.SERVER_HOST }}
23
-
User ${{ secrets.SERVER_USER }}
24
-
IdentityFile ~/.ssh/id_tangledsh
25
-
StrictHostKeyChecking accept-new
26
-
BatchMode yes
27
-
PasswordAuthentication no
28
-
PubkeyAuthentication yes
29
-
EOF
30
-
chmod 600 ~/.ssh/config
31
-
ssh-keyscan -H ${{ secrets.SERVER_HOST }} >> ~/.ssh/known_hosts
32
-
echo "🪶 deploying to shimaenaga pds"
33
-
34
-
- name: "Deploy via SCP"
35
-
run: scp -r ./dist/* deploy:/pds/caddy/webroot
36
-
37
-
- name: "Done!"
38
-
command: "echo \"🪶 all done!\""
12
+
- name: "Build static files"
13
+
command: "deno run build"
14
+
15
+
- name: "SSH setup"
16
+
command: |
17
+
mkdir ~/.ssh
18
+
echo "${{secrets.SSH_KEY}}" > ~/.ssh/id_tangledsh
19
+
chmod 600 ~/.ssh/id_tangledsh
20
+
cat > ~/.ssh/config << EOF
21
+
Host deploy
22
+
HostName ${{ secrets.SERVER_HOST }}
23
+
User ${{ secrets.SERVER_USER }}
24
+
IdentityFile ~/.ssh/id_tangledsh
25
+
StrictHostKeyChecking accept-new
26
+
BatchMode yes
27
+
PasswordAuthentication no
28
+
PubkeyAuthentication yes
29
+
EOF
30
+
chmod 600 ~/.ssh/config
31
+
ssh-keyscan -H ${{ secrets.SERVER_HOST }} >> ~/.ssh/known_hosts
32
+
echo "🪶 deploying to shimaenaga pds"
33
+
34
+
- name: "Deploy via SCP"
35
+
run: scp -r ./dist/* deploy:/pds/caddy/etc/caddy/static
36
+
37
+
- name: "Done!"
38
+
command: "echo \"🪶 all done!\""