aboutsummaryrefslogtreecommitdiff
path: root/README.md
blob: 2a21b42bd1151e3ced0bfbf98205601ce61c72d2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# Gemini from http

`proxy.py` is a Gemini server that proxies all content to an http or https server.

`proxy.py` loads certificates following the structure of Apache mod_md.

## Providing the certificates via systemd credentials

With `/etc/systemd/system/gemini-from-http.service`:

```
[Service]
LoadCredential=certificates:/etc/apache2/md/domains/
ExecStart=.../proxy.py --certificates-from-credential certificates
PrivateUsers=self
```

Systemd injects the certificates to a private path than only `proxy.py` can read.
The injection is a one off, so you must restart the service to get updated certificates.

## Providing the certificates manually

To run `proxy.py` as a regular user, you can run the `package-mod-md-certs` script as root to copy the certificates to your user:

```
su -c ./package-mod-md-certs | tar x
```

Then you can run:

```
./proxy.py --certificates-from-path domains/
```