-
-
Save david-crespo/d8aa7ea1afb877ff585e6ad90fc5bc2c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env bash | |
# This script relies on yq to parse TOML. brew install yq | |
set -eux | |
DENDRITE_BIN_DIR="$(pwd)/out/dendrite-stub/root/opt/oxide/dendrite/bin" | |
MGD_BIN_DIR="$(pwd)/out/mgd/root/opt/oxide/mgd/bin" | |
DENDRITE_COMMIT="$(yq '.package.dendrite-stub.source.commit' package-manifest.toml)" | |
MGD_COMMIT="$(yq '.package.mgd.source.commit' package-manifest.toml)" | |
OSTYPE=linux-gnu cargo xtask download dendrite-stub | |
OSTYPE=linux-gnu cargo xtask download maghemite-mgd | |
cd ~/oxide/dendrite | |
git fetch --all && git checkout $DENDRITE_COMMIT | |
cargo build -p dpd --release --features=tofino_stub | |
cargo build -p swadm --release | |
cp target/release/dpd "$DENDRITE_BIN_DIR/dpd" | |
cp target/release/swadm "$DENDRITE_BIN_DIR/swadm" | |
cd ~/oxide/maghemite | |
git fetch --all && git checkout $MGD_COMMIT | |
cargo build --bin mgd --no-default-features | |
cp target/debug/mgd "$MGD_BIN_DIR/mgd" | |
echo "now add the bin dirs to your path" | |
echo "" | |
echo " export PATH=\"$DENDRITE_BIN_DIR:\$PATH\"" | |
echo " export PATH=\"$MGD_BIN_DIR:\$PATH\"" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Make sure you https auth, using the GitHub cli tool before using this