summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--MANUAL18
-rw-r--r--Makefile7
2 files changed, 25 insertions, 0 deletions
diff --git a/MANUAL b/MANUAL
index 7f28f58..8a48baf 100644
--- a/MANUAL
+++ b/MANUAL
@@ -104,3 +104,21 @@ Rvnit is self-contained and can be booted directly as pid 1.
 It will mount /dev and /run when required, everything else
 is left to startup scripts.
 When receiving Ctrl-Alt-Delete, rvnit triggers an orderly reboot.
+
+                 Rvnit as init for a Docker container
+
+Fresh binary releases are provided in Alpine containers at
+https://hub.docker.com/r/leahneukirchen/rvnit/tags
+
+rvnit is compiled statically, so you can copy it out if you have
+different needs:
+
+  COPY --from=docker.io/leahneukirchen/rvnit:latest /bin/rvnit /bin/
+  CMD ["/bin/rvnit"]
+
+Note that /run must exist in the container if you want to use
+the default control socket name.
+
+You can put the control socket onto a bind-mount and remote-control
+rvnit using rvnitctl from the outside by pointing RVNIT_SOCK to the
+appropriate target.
diff --git a/Makefile b/Makefile
index a45e672..47a87fc 100644
--- a/Makefile
+++ b/Makefile
@@ -7,4 +7,11 @@ all: $(ALL)
 clean: FRC
 	rm -f $(ALL)
 
+docker-release: FRC
+	TAG=$$(git rev-parse --short=8 @) ; \
+	docker build -f Dockerfile.build -t docker.io/leahneukirchen/rvnit:$$TAG . && \
+	docker tag docker.io/leahneukirchen/rvnit:$$TAG docker.io/leahneukirchen/rvnit:latest && \
+	docker push docker.io/leahneukirchen/rvnit:$$TAG && \
+	docker push docker.io/leahneukirchen/rvnit:latest
+
 FRC: