From dfd7d32c948c7af3aec48927af9d7813e2fc2d04 Mon Sep 17 00:00:00 2001 From: Paul Campbell Date: Mon, 15 Apr 2024 17:23:05 +0100 Subject: [PATCH] feat(dev): Add recipe for exposing webhook server Starts an ngrok tunnel to expose port 8080 to the Internet. --- .gitignore | 1 + justfile | 9 +++++++++ 2 files changed, 10 insertions(+) diff --git a/.gitignore b/.gitignore index ee362bc..f5db88d 100644 --- a/.gitignore +++ b/.gitignore @@ -20,3 +20,4 @@ Cargo.lock # git-next runtime files git-next-server.toml .git-next.toml +.envrc diff --git a/justfile b/justfile index a042576..b5733ba 100644 --- a/justfile +++ b/justfile @@ -6,3 +6,12 @@ validate-dev-branch: git rebase -i origin/main -x 'cargo build' git rebase -i origin/main -x 'cargo test' git rebase -i origin/main -x 'cargo clippy -- -D warnings -W clippy::nursery -W clippy::unwrap_used -W clippy::expect_used' + +start-ngrok: + #!/usr/bin/env bash + # Uses NGROK_DOMAIN env var if available + if test -z ${NGROK_DOMAIN} ; then + ngrok http 8080 + else + ngrok http --domain=${NGROK_DOMAIN} 8080 + fi