forked from
nekomimi.pet/wisp.place-monorepo
Monorepo for Wisp.place. A static site hosting service built on top of the AT Protocol.
1# Deploy to Wisp.place
2# This workflow builds your site and deploys it to Wisp.place using the wisp-cli
3when:
4 - event: ['push']
5 branch: ['main']
6 - event: ['manual']
7engine: 'nixery'
8clone:
9 skip: false
10 depth: 1
11 submodules: true
12dependencies:
13 nixpkgs:
14 - git
15 - gcc
16 github:NixOS/nixpkgs/nixpkgs-unstable:
17 - rustc
18 - cargo
19environment:
20 # Customize these for your project
21 SITE_PATH: 'testDeploy'
22 SITE_NAME: 'wispPlaceDocs'
23steps:
24 - name: 'Initialize submodules'
25 command: |
26 git submodule update --init --recursive
27
28 - name: 'Build wisp-cli'
29 command: |
30 cd cli
31 export PATH="$HOME/.nix-profile/bin:$PATH"
32 nix-channel --add https://nixos.org/channels/nixpkgs-unstable nixpkgs
33 nix-channel --update
34 nix-shell -p pkg-config openssl --run '
35 export PKG_CONFIG_PATH="$(pkg-config --variable pc_path pkg-config)"
36 export OPENSSL_DIR="$(nix-build --no-out-link "<nixpkgs>" -A openssl.dev)"
37 export OPENSSL_NO_VENDOR=1
38 export OPENSSL_LIB_DIR="$(nix-build --no-out-link "<nixpkgs>" -A openssl.out)/lib"
39 cargo build --release
40 '
41 cd ..
42
43 - name: 'Deploy to Wisp.place'
44 command: |
45 echo
46 ./cli/target/release/wisp-cli \
47 "$WISP_HANDLE" \
48 --path "$SITE_PATH" \
49 --site "$SITE_NAME" \
50 --password "$WISP_APP_PASSWORD"