Skip to content

Commit

Permalink
ci: make .deb files (#33)
Browse files Browse the repository at this point in the history
* ci: make .deb files

* Now compress the tar when making artifacts

* Fix naming of orb-token -> orb-attest

* use component_flavor_target naming scheme for artifacts
  • Loading branch information
TheButlah authored Mar 31, 2024
1 parent bc11777 commit 96fa457
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -186,9 +186,11 @@ jobs:
cargo zigbuild ${MAYBE_LTO:-} --all --release ${TARGETS} --no-default-features ${FEATURES}
for b in ${binaries[@]}; do
mkdir -p "binaries/${b}/"
echo Copying ${b}
echo Packaging ${b}
for t in ${targets[@]}; do
cp -L target/${t}-unknown-linux-gnu/release/${b} binaries/${b}/${t}-${f}
nix develop -c \
cargo deb --no-build --no-strip -p ${b} --target ${t}-unknown-linux-gnu -o binaries/${b}/${b}_${f}_${t}.deb
cp -L target/${t}-unknown-linux-gnu/release/${b} binaries/${b}/${b}_${f}_${t}
done
done
done
Expand All @@ -203,7 +205,7 @@ jobs:
# We make sure that the tarball is idempotent:
# https://stackoverflow.com/a/54908072
tar --sort=name --owner=root:0 --group=root:0 --mtime='@0' \
-vhcf artifacts/${b}.tar.zst -C binaries/${b} .
-vahcf artifacts/${b}.tar.zst -C binaries/${b} .
done
ls -aRsh artifacts
Expand Down
3 changes: 3 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,9 @@
zig
cargo-zigbuild

# Needed for packaging for orb-os
cargo-deb

# Used by various rust build scripts to find system libs
# Note that this is the unwrapped version of pkg-config. By default,
# nix wraps pkg-config with a script that replaces the PKG_CONFIG_PATH
Expand Down
3 changes: 1 addition & 2 deletions orb-attest/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,5 @@ prod = [] # use prod backend
[package.metadata.deb]
maintainer-scripts = "debian/"
systemd-units = [
{ unit-name = "worldcoin-token" },
{ unit-name = "worldcoin-token-dumb-client" }
{ unit-name = "worldcoin-attest" },
]
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[Unit]
Description=Short lived token daemon
Description=Short lived attestation token daemon
## persistent contains SE pairing keys
After=usr-persistent.mount
Requires=worldcoin-backend-online.target
Expand Down

0 comments on commit 96fa457

Please sign in to comment.