From 1d9c4631109a427ea2b1535ff02702d1cc1d4dcf Mon Sep 17 00:00:00 2001 From: Mathias Wagner Date: Fri, 2 Jun 2023 00:41:08 +0200 Subject: [PATCH] Created the docker app handler --- server/handler/apps/docker.js | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 server/handler/apps/docker.js diff --git a/server/handler/apps/docker.js b/server/handler/apps/docker.js new file mode 100644 index 0000000..45a01ef --- /dev/null +++ b/server/handler/apps/docker.js @@ -0,0 +1,25 @@ +module.exports = { + variables: { + environment: "Stabil", + }, + steps: [ + { + description: "Zugriff prüfen", + command: "if [ $EUID -ne 0 ]; then exit 1; fi" + }, + { + description: "Docker Test installieren", + command: "curl -sSL https://get.docker.com/ | CHANNEL=test bash && exit 0", + condition: "environment=Test" + }, + { + description: "Docker installieren", + command: "curl -sSL https://get.docker.com/ | CHANNEL=stable bash && exit 0", + condition: "environment=Stabil" + }, + { + description: "Systemdienst aktivieren", + command: "systemctl enable --now docker" + } + ] +} \ No newline at end of file