diff --git a/README.md b/README.md index 437153a5..d388f631 100644 --- a/README.md +++ b/README.md @@ -22,6 +22,10 @@ curl -s https://raw.githubusercontent.com/animenotifier/notify.moe/go/install.sh * In your browser, import the file `security/default/rootCA.pem` as a trusted Root authority * Open `https://beta.notify.moe` +## OS restarts + +* If you restart your operating system, run `make ports` to update your port bindings + [godoc-image]: https://godoc.org/github.com/animenotifier/notify.moe?status.svg [godoc-url]: https://godoc.org/github.com/animenotifier/notify.moe [travis-image]: https://travis-ci.org/animenotifier/notify.moe.svg?branch=go diff --git a/makefile b/makefile index 750b33b5..2f8045fb 100644 --- a/makefile +++ b/makefile @@ -9,6 +9,7 @@ BUILDPATCHES=@./patches/build.sh BUILDBOTS=@./bots/build.sh TSCMD=@tsc IPTABLES=@sudo iptables +IP6TABLES=@sudo ip6tables PACK:=$(shell command -v pack 2> /dev/null) RUN:=$(shell command -v run 2> /dev/null) GOIMPORTS:=$(shell command -v goimports 2> /dev/null) @@ -84,6 +85,8 @@ ports: ifeq ($(OSNAME),LINUX) $(IPTABLES) -t nat -A OUTPUT -o lo -p tcp --dport 80 -j REDIRECT --to-port 4000 $(IPTABLES) -t nat -A OUTPUT -o lo -p tcp --dport 443 -j REDIRECT --to-port 4001 + $(IP6TABLES) -t nat -A OUTPUT -o lo -p tcp --dport 80 -j REDIRECT --to-port 4000 + $(IP6TABLES) -t nat -A OUTPUT -o lo -p tcp --dport 443 -j REDIRECT --to-port 4001 endif ifeq ($(OSNAME),OSX) @echo "rdr pass inet proto tcp from any to any port 443 -> 127.0.0.1 port 4001" | sudo pfctl -ef -