Skip to content

Commit 4c4683a

Browse files
author
david
committed
Update compose to use static ssh keys
This way rebuilding the docker container doesn't destroy its identity. By copying the keys when the container starts, they won't be exposed through backing them into the image.
1 parent 244858c commit 4c4683a

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

bin/update-compose

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/bin/bash
2+
3+
docker pull debian:testing
4+
docker-compose up -d --force-recreate --build

cheesycompose/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,4 @@ VOLUME [ "/sys/fs/cgroup" ]
3838

3939
STOPSIGNAL SIGRTMIN+3
4040

41-
CMD ["/lib/systemd/systemd"]
41+
CMD ["sh", "-e", "-c", "cp -av /srv/cheesy.at/secrets/ssh/* /etc/ssh/; echo starting systemd; exec /lib/systemd/systemd"]

0 commit comments

Comments
 (0)