dev-federate

This commit is contained in:
Mayel de Borniol 2023-09-17 14:57:41 +01:00
parent cac4ac9a97
commit a60c99f3c6
3 changed files with 6 additions and 1 deletions

1
.gitignore vendored
View file

@ -105,3 +105,4 @@ tx
archeometer_bonfire.db
reports/
docs/xref_graph.svg
tunnel.conf

View file

@ -159,6 +159,10 @@ dev-proxied: docker-stop-web
dev-proxied-iex:
docker compose --profile proxy exec web iex --sname extra --remsh dev
dev-federate: docker-stop-web
which wg-quick || exit "You need to install Wireguard to run the tunnel/proxy. E.g. with: brew install wireguard-tools"
FEDERATE=yes HOSTNAME=$(([ -f tunnel.conf ] || curl https://tunnel.pyjam.as/4000 > tunnel.conf) && wg-quick up ./tunnel.conf | pcregrep -o1 'https:\/\/([^/]+)') PUBLIC_PORT=443 just dev
dev-docker *args='': docker-stop-web
docker compose $args run --name $WEB_CONTAINER --service-ports web

View file

@ -142,7 +142,7 @@ if not Code.ensure_loaded?(Bonfire.Mixer) do
|> deps_names()
|> IO.inspect(
label:
"Running Bonfire #{version(config)} with configuration from #{flavour_path(config)} in #{Mix.env()} environment. You can run `just mix bonfire.deps.update` to update these extensions and dependencies"
"Running Bonfire #{version(config)} at #{System.get_env("HOSTNAME", "localhost")} with configuration from #{flavour_path(config)} in #{Mix.env()} environment. You can run `just mix bonfire.deps.update` to update these extensions and dependencies"
)
end