aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVolpeon <git@volpeon.ink>2021-07-24 09:46:59 +0200
committerVolpeon <git@volpeon.ink>2021-07-24 09:46:59 +0200
commit38485ede265d22e11a316b4d66de1bf0feb945be (patch)
tree72388107a2bfe9e8e972feccd4f9c7d542d37b60
parentAdd underline to nav protocol (diff)
downloadgopherproxy-38485ede265d22e11a316b4d66de1bf0feb945be.tar.gz
gopherproxy-38485ede265d22e11a316b4d66de1bf0feb945be.tar.bz2
gopherproxy-38485ede265d22e11a316b4d66de1bf0feb945be.zip
-rw-r--r--.gitignore2
-rw-r--r--Dockerfile10
-rw-r--r--Makefile4
-rw-r--r--README.md8
-rw-r--r--cmd/gopherproxy/main.go (renamed from cmd/port/main.go)6
-rw-r--r--go.mod2
-rw-r--r--internal/gopherproxy/gemini.go (renamed from internal/port/gemini.go)4
-rw-r--r--internal/gopherproxy/gopher.go (renamed from internal/port/gopher.go)4
-rw-r--r--internal/gopherproxy/main.go (renamed from internal/port/main.go)2
-rw-r--r--internal/gopherproxy/tpl/_fonts.html (renamed from internal/port/tpl/_fonts.html)0
-rw-r--r--internal/gopherproxy/tpl/_modals.html (renamed from internal/port/tpl/_modals.html)0
-rw-r--r--internal/gopherproxy/tpl/gemini.html (renamed from internal/port/tpl/gemini.html)0
-rw-r--r--internal/gopherproxy/tpl/gopher.html (renamed from internal/port/tpl/gopher.html)0
-rw-r--r--internal/gopherproxy/tpl/startpage.html (renamed from internal/port/tpl/startpage.html)0
-rwxr-xr-xport.binbin0 -> 13478712 bytes
15 files changed, 21 insertions, 21 deletions
diff --git a/.gitignore b/.gitignore
index f02946e..fe92af3 100644
--- a/.gitignore
+++ b/.gitignore
@@ -3,6 +3,6 @@ dist
3*.bak 3*.bak
4coverage.txt 4coverage.txt
5 5
6port.bin 6gopherproxy.bin
7 7
8.vscode 8.vscode
diff --git a/Dockerfile b/Dockerfile
index 5db4ab0..6ac0724 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -2,16 +2,16 @@ FROM golang:alpine
2 2
3EXPOSE 80/tcp 3EXPOSE 80/tcp
4 4
5ENTRYPOINT ["port"] 5ENTRYPOINT ["gopherproxy"]
6 6
7RUN \ 7RUN \
8 apk add --update git && \ 8 apk add --update git && \
9 rm -rf /var/cache/apk/* 9 rm -rf /var/cache/apk/*
10 10
11RUN mkdir -p /go/src/git.vulpes.one/Feuerfuchs/port 11RUN mkdir -p /go/src/git.vulpes.one/gopherproxy
12WORKDIR /go/src/git.vulpes.one/Feuerfuchs/port 12WORKDIR /go/src/git.vulpes.one/gopherproxy
13 13
14COPY . /go/src/git.vulpes.one/Feuerfuchs/port 14COPY . /go/src/git.vulpes.one/gopherproxy
15 15
16RUN go get -v -d 16RUN go get -v -d
17RUN go install -v git.vulpes.one/Feuerfuchs/port/... 17RUN go install -v git.vulpes.one/gopherproxy/...
diff --git a/Makefile b/Makefile
index a537070..0d99fd0 100644
--- a/Makefile
+++ b/Makefile
@@ -3,7 +3,7 @@
3all: dev 3all: dev
4 4
5dev: build 5dev: build
6 ./port.bin -bind 127.0.0.1:8000 6 ./gopherproxy.bin -bind 127.0.0.1:8000
7 7
8build: clean 8build: clean
9 sassc -t compressed css/main.scss assets/style.css 9 sassc -t compressed css/main.scss assets/style.css
@@ -12,7 +12,7 @@ build: clean
12 #pyftsubset fonts/iosevka-fixed-ss03-regular.ttf "*" --name-IDs+=0,4,6 --flavor='woff2' --output-file='assets/iosevka-fixed-ss03-regular.woff2' 12 #pyftsubset fonts/iosevka-fixed-ss03-regular.ttf "*" --name-IDs+=0,4,6 --flavor='woff2' --output-file='assets/iosevka-fixed-ss03-regular.woff2'
13 #pyftsubset fonts/iosevka-fixed-ss03-bold.ttf "*" --name-IDs+=0,4,6 --flavor='woff' --with-zopfli --output-file='assets/iosevka-fixed-ss03-bold.woff' 13 #pyftsubset fonts/iosevka-fixed-ss03-bold.ttf "*" --name-IDs+=0,4,6 --flavor='woff' --with-zopfli --output-file='assets/iosevka-fixed-ss03-bold.woff'
14 #pyftsubset fonts/iosevka-fixed-ss03-bold.ttf "*" --name-IDs+=0,4,6 --flavor='woff2' --output-file='assets/iosevka-fixed-ss03-bold.woff2' 14 #pyftsubset fonts/iosevka-fixed-ss03-bold.ttf "*" --name-IDs+=0,4,6 --flavor='woff2' --output-file='assets/iosevka-fixed-ss03-bold.woff2'
15 go build -o ./port.bin ./cmd/port 15 go build -o ./gopherproxy.bin ./cmd/gopherproxy
16 16
17profile: 17profile:
18 @go test -cpuprofile cpu.prof -memprofile mem.prof -v -bench . 18 @go test -cpuprofile cpu.prof -memprofile mem.prof -v -bench .
diff --git a/README.md b/README.md
index 40ed18a..da48e89 100644
--- a/README.md
+++ b/README.md
@@ -1,8 +1,8 @@
1# Gopher (RFC 1436) Web Proxy 1# Gopher (RFC 1436) Web Proxy
2 2
3port is a Gopher (RFC 1436) and Gemini (gopher://zaibatsu.circumlunar.space/1/~solderpunk/gemini/docs/) Web Proxy that acts as a gateway into Gopherspace/Geminispace by proxying standard Web HTTP requests to Gopher/Gemini requests of the target server. 3gopherproxy is a Gopher (RFC 1436) and Gemini (gopher://zaibatsu.circumlunar.space/1/~solderpunk/gemini/docs/) Web Proxy that acts as a gateway into Gopherspace/Geminispace by proxying standard Web HTTP requests to Gopher/Gemini requests of the target server.
4 4
5port is a fork of [https://github.com/prologic/port](https://github.com/prologic/port). 5gopherproxy is a fork of [https://github.com/prologic/gopherproxy](https://github.com/prologic/gopherproxy).
6 6
7Demo: https://proxy.vulpes.one/ 7Demo: https://proxy.vulpes.one/
8 8
@@ -15,14 +15,14 @@ Demo: https://proxy.vulpes.one/
15## Installation 15## Installation
16 16
17```#!bash 17```#!bash
18$ go install git.vulpes.one/Feuerfuchs/port/... 18$ go install git.vulpes.one/gopherproxy/...
19``` 19```
20 20
21 21
22## Usage 22## Usage
23 23
24```#!bash 24```#!bash
25$ port 25$ gopherproxy
26``` 26```
27 27
28Arguments: 28Arguments:
diff --git a/cmd/port/main.go b/cmd/gopherproxy/main.go
index 6cdccc6..1b69671 100644
--- a/cmd/port/main.go
+++ b/cmd/gopherproxy/main.go
@@ -4,7 +4,7 @@ import (
4 "flag" 4 "flag"
5 "log" 5 "log"
6 6
7 port "git.vulpes.one/Feuerfuchs/port/internal/port" 7 gopherproxy "git.vulpes.one/gopherproxy/internal/gopherproxy"
8) 8)
9 9
10var ( 10var (
@@ -20,6 +20,6 @@ var (
20func main() { 20func main() {
21 flag.Parse() 21 flag.Parse()
22 22
23 // Use a config struct 23 // Use a gopherproxy struct
24 log.Fatal(port.ListenAndServe(*bind, *startpagefile, *robotsfile, *robotsdebug, *vipsconcurrency)) 24 log.Fatal(gopherproxy.ListenAndServe(*bind, *startpagefile, *robotsfile, *robotsdebug, *vipsconcurrency))
25} 25}
diff --git a/go.mod b/go.mod
index f6759d3..8d5600c 100644
--- a/go.mod
+++ b/go.mod
@@ -1,4 +1,4 @@
1module git.vulpes.one/Feuerfuchs/port 1module git.vulpes.one/gopherproxy
2 2
3require ( 3require (
4 github.com/NYTimes/gziphandler v1.1.1 4 github.com/NYTimes/gziphandler v1.1.1
diff --git a/internal/port/gemini.go b/internal/gopherproxy/gemini.go
index f574816..89d820c 100644
--- a/internal/port/gemini.go
+++ b/internal/gopherproxy/gemini.go
@@ -1,4 +1,4 @@
1package port 1package gopherproxy
2 2
3import ( 3import (
4 "bytes" 4 "bytes"
@@ -14,7 +14,7 @@ import (
14 "golang.org/x/net/html/charset" 14 "golang.org/x/net/html/charset"
15 "golang.org/x/text/transform" 15 "golang.org/x/text/transform"
16 16
17 "git.vulpes.one/Feuerfuchs/port/pkg/libgemini" 17 "git.vulpes.one/gopherproxy/pkg/libgemini"
18 18
19 "github.com/temoto/robotstxt" 19 "github.com/temoto/robotstxt"
20) 20)
diff --git a/internal/port/gopher.go b/internal/gopherproxy/gopher.go
index fc7b754..5f4b39f 100644
--- a/internal/port/gopher.go
+++ b/internal/gopherproxy/gopher.go
@@ -1,4 +1,4 @@
1package port 1package gopherproxy
2 2
3import ( 3import (
4 "bytes" 4 "bytes"
@@ -11,7 +11,7 @@ import (
11 "net/url" 11 "net/url"
12 "strings" 12 "strings"
13 13
14 "git.vulpes.one/Feuerfuchs/port/pkg/libgopher" 14 "git.vulpes.one/gopherproxy/pkg/libgopher"
15 15
16 "github.com/davidbyttow/govips/pkg/vips" 16 "github.com/davidbyttow/govips/pkg/vips"
17 "github.com/temoto/robotstxt" 17 "github.com/temoto/robotstxt"
diff --git a/internal/port/main.go b/internal/gopherproxy/main.go
index 5fb3dae..33230c1 100644
--- a/internal/port/main.go
+++ b/internal/gopherproxy/main.go
@@ -1,4 +1,4 @@
1package port 1package gopherproxy
2 2
3import ( 3import (
4 "crypto/md5" 4 "crypto/md5"
diff --git a/internal/port/tpl/_fonts.html b/internal/gopherproxy/tpl/_fonts.html
index a947222..a947222 100644
--- a/internal/port/tpl/_fonts.html
+++ b/internal/gopherproxy/tpl/_fonts.html
diff --git a/internal/port/tpl/_modals.html b/internal/gopherproxy/tpl/_modals.html
index 3bbdef2..3bbdef2 100644
--- a/internal/port/tpl/_modals.html
+++ b/internal/gopherproxy/tpl/_modals.html
diff --git a/internal/port/tpl/gemini.html b/internal/gopherproxy/tpl/gemini.html
index 8d20da1..8d20da1 100644
--- a/internal/port/tpl/gemini.html
+++ b/internal/gopherproxy/tpl/gemini.html
diff --git a/internal/port/tpl/gopher.html b/internal/gopherproxy/tpl/gopher.html
index 6eb607c..6eb607c 100644
--- a/internal/port/tpl/gopher.html
+++ b/internal/gopherproxy/tpl/gopher.html
diff --git a/internal/port/tpl/startpage.html b/internal/gopherproxy/tpl/startpage.html
index 772ac90..772ac90 100644
--- a/internal/port/tpl/startpage.html
+++ b/internal/gopherproxy/tpl/startpage.html
diff --git a/port.bin b/port.bin
new file mode 100755
index 0000000..eff9e5d
--- /dev/null
+++ b/port.bin
Binary files differ