diff --git a/README.md b/README.md index 5698f2d..2468711 100644 --- a/README.md +++ b/README.md @@ -172,7 +172,15 @@ sudo apt install ./innernet*.deb ### macOS ```sh -./macos/install.sh +brew install tonarino/innernet/innernet +``` + +### Cargo + +```sh +git checkout https://github.com/tonarino/innernet +cd innernet +cargo install --path client ``` ## Development diff --git a/macos/install.sh b/macos/install.sh deleted file mode 100755 index 6183dba..0000000 --- a/macos/install.sh +++ /dev/null @@ -1,64 +0,0 @@ -#!/usr/bin/env bash - -ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." >/dev/null 2>&1 && pwd)" - -info() { - TERM=${TERM:-dumb} echo -e "$(tput setaf 4)- $@$(tput sgr0)" 1>&2 -} - -cmd() { - echo "[#] $*" >&2 - "$@" -} - -set -e - -info "building innernet binary." -cmd cargo build --release --bin innernet - -info "installing innernet binary." -cmd sudo cp -f $ROOT_DIR/target/release/innernet /usr/local/bin -cmd sudo ln -s /usr/local/bin/innernet /usr/local/bin/inn - -if ! which wg > /dev/null; then - info "installing wireguard." - cmd brew install wireguard-tools -fi - -info "installing launch daemon for innernet daemon script." -echo "\ - - - - - Label - no.tonari.innernet - ProgramArguments - - /usr/local/bin/innernet - fetch - --daemon - --interval - 60 - - KeepAlive - - RunAtLoad - - LaunchOnlyOnce - - StandardOutPath - /var/log/innernet.log - StandardErrorPath - /var/log/innernet.log - EnvironmentVariables - - PATH - /usr/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin - - - -" | cmd sudo tee /Library/LaunchDaemons/no.tonari.innernet.plist -cmd sudo launchctl enable system/no.tonari.innernet -cmd sudo launchctl bootstrap system /Library/LaunchDaemons/no.tonari.innernet.plist -