File: README.adoc

package info (click to toggle)
json2file-go 1.15
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 184 kB
  • sloc: sh: 298; makefile: 10
file content (26 lines) | stat: -rw-r--r-- 749 bytes parent folder | download | duplicates (2)
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
= Running `json2file-go` as a standalone HTTPS server using `systemd`

For a quick test use the `./setup-tls.sh` script.

Basically what you have to do is provide the TLS files (certificate and key)
and override the socket definition:

[source,console]
----
$ sudo systemctl edit json2file-go.socket
----

To listen on the 443 port the previous command will be used to write the
following file:

[source,ini]
----
[Socket]
ListenStream=
ListenStream=443
----

Remember that to _change_ the `ListenStream` you have to clean the value to
override the original one (our program only listens on the first
`systemd.socket`, the standard configuration already sets it to the UNIX socket
and if you don't clean the value `systemd` opens multiple sockets).