...
1## socket activated http server
2
3This is a simple example of using socket activation with systemd to serve a
4simple HTTP server on http://127.0.0.1:8076
5
6To try it out `go get` the httpserver and run it under the systemd-activate helper
7
8```bash
9export GOPATH="$PWD"
10go get github.com/coreos/go-systemd/examples/activation/httpserver
11systemd-socket-activate -l 127.0.0.1:8076 ./bin/httpserver
12```
13
14Then curl the URL and you will notice that it starts up:
15
16```
17curl 127.0.0.1:8076
18hello socket activated world!
19```
View as plain text