diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..2115329 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,9 @@ +ARG IMAGE + +FROM ${IMAGE} + +USER rundeck + +COPY --chown=rundeck:root lib docker-lib +RUN chmod +x docker-lib/generate-ssl.sh +RUN ./docker-lib/generate-ssl.sh diff --git a/docker-compose.yaml b/docker-compose.yaml new file mode 100644 index 0000000..8bb0150 --- /dev/null +++ b/docker-compose.yaml @@ -0,0 +1,13 @@ +version: "3" +services: + rundeck: + build: + context: . + args: + IMAGE: ${RUNDECK_IMAGE:-rundeck/rundeck:3.3.0} + container_name: rundeck-ssl + command: "-Dserver.https.port=4443 -Drundeck.ssl.config=/home/rundeck/server/config/ssl.properties" + ports: + - 4443:4443 + environment: + RUNDECK_GRAILS_URL: https://test:4443 diff --git a/lib/generate-ssl.sh b/lib/generate-ssl.sh new file mode 100644 index 0000000..05357d1 --- /dev/null +++ b/lib/generate-ssl.sh @@ -0,0 +1,13 @@ +#!/usr/bin/env bash + +## Adding ssl support ################################## +keytool -keystore etc/keystore \ + -alias rundeckssl \ + -genkey -keyalg RSA \ + -keypass adminadmin \ + -storepass adminadmin \ + -dname "C=test, S=stgo, OU= rundeck, L=stgo, O=cst, CN=rundeck" + +cp etc/keystore etc/truststore + +########################################################