From 1b0fcff9fba8b53f8c174a2cd39808fcfe0a29d7 Mon Sep 17 00:00:00 2001 From: Taeer Bar-Yam Date: Wed, 20 Mar 2024 05:23:57 -0400 Subject: [PATCH] fix mastodon (why was it broken??) --- README.md | 3 ++- common.nix | 14 +++++++------- mastodon.nix | 2 ++ 3 files changed, 11 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 7fecd12d..b1119675 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,7 @@ and then run it with You can then access the apps on your local machine (using the magic of port forwarding) at the following addresses -- Mastodon: +- Mastodon: - You will have to "accept the security risk" - It may take a minute for the webpage to come online. Until then you will see "502 Bad Gateway" - (NOTE: currently broken) email sent from the mastodon instance (e.g. for setting up an account) will be accessible at @@ -40,6 +40,7 @@ You can then access the apps on your local machine (using the magic of port forw - mastodon-web.service - peertube.service - unclear yet which pixelfed services are useful +- you can ssh to the machine using `ssh -p 2222 root@localhost` # TODOs diff --git a/common.nix b/common.nix index e3ac132f..d9674e82 100644 --- a/common.nix +++ b/common.nix @@ -32,13 +32,13 @@ "-mon chardev=char0,mode=readline" "-device virtconsole,chardev=char0,nr=0" ]; - # forwardPorts = [ - # { - # from = "host"; - # host.port = 2222; - # guest.port = 22; - # } - # ]; + forwardPorts = [ + { + from = "host"; + host.port = 2222; + guest.port = 22; + } + ]; }; }; } diff --git a/mastodon.nix b/mastodon.nix index 77546d8d..7fb1fe4e 100644 --- a/mastodon.nix +++ b/mastodon.nix @@ -81,6 +81,8 @@ enableUnixSocket = false; extraConfig = { RAILS_ENV = "development"; + # to be accessible from outside the VM + BIND = "0.0.0.0"; # for letter_opener (still doesn't work though) REMOTE_DEV = "true"; };