From aeed17008f5d43c5358a13298fa74f61256e8c42 Mon Sep 17 00:00:00 2001 From: WilliamMiceli <9000802+WilliamMiceli@users.noreply.github.com> Date: Fri, 29 Jun 2018 17:53:09 -0400 Subject: [PATCH] Admin interface included is nicer! --- templates/{BInd9 => BInd}/0/README.md | 0 templates/BInd/0/docker-compose.yml | 22 +++++++++ templates/BInd/0/rancher-compose.yml | 69 +++++++++++++++++++++++++++ templates/{BInd9 => BInd}/config.yml | 4 +- templates/BInd9/0/docker-compose.yml | 11 ----- templates/BInd9/0/rancher-compose.yml | 52 -------------------- 6 files changed, 93 insertions(+), 65 deletions(-) rename templates/{BInd9 => BInd}/0/README.md (100%) create mode 100644 templates/BInd/0/docker-compose.yml create mode 100644 templates/BInd/0/rancher-compose.yml rename templates/{BInd9 => BInd}/config.yml (79%) delete mode 100644 templates/BInd9/0/docker-compose.yml delete mode 100644 templates/BInd9/0/rancher-compose.yml diff --git a/templates/BInd9/0/README.md b/templates/BInd/0/README.md similarity index 100% rename from templates/BInd9/0/README.md rename to templates/BInd/0/README.md diff --git a/templates/BInd/0/docker-compose.yml b/templates/BInd/0/docker-compose.yml new file mode 100644 index 0000000..ce06f69 --- /dev/null +++ b/templates/BInd/0/docker-compose.yml @@ -0,0 +1,22 @@ +version: '2' +services: + bind: + image: sameersbn/bind + environment: + WEBMIN_ENABLED: ${WEBMIN_ENABLED} +{{- if eq .Values.WEBMIN_ENABLED "true"}} + ROOT_PASSWORD: ${WEBMIN_ROOT_PASS} +{{- end}} + labels: +{{- if (.Values.HOST_LABEL)}} + io.rancher.scheduler.affinity:host_label: ${HOST_LABEL} +{{- end}} + ports: + - "53:53/tcp" + - "53:53/udp" +{{- if eq .Values.WEBMIN_ENABLED "true"}} + - "${WEBMIN_PORT}:10000" +{{- end}} + restart: on-failure + volumes: + - ${STORAGE_BASE_DIR}${DATA_DIR}:/data \ No newline at end of file diff --git a/templates/BInd/0/rancher-compose.yml b/templates/BInd/0/rancher-compose.yml new file mode 100644 index 0000000..1a9a316 --- /dev/null +++ b/templates/BInd/0/rancher-compose.yml @@ -0,0 +1,69 @@ +version: '2' +catalog: + name: Bind + version: latest + # description: + # minimum_rancher_version: + # maximum_rancher_version: + # upgrade_from: + questions: + + - variable: "HOST_LABEL" + label: "Host Label Key/Value Pair" + description: | + The Key/Value pair on the host which Bind should be deployed. + default: "host.id=0000" + required: false + type: string + + - variable: "WEBMIN_ENABLED" + label: "Enable Webmin" + description: | + Enable or Disable Webmin. + default: true + required: true + type: boolean + + - variable: "WEBMIN_ROOT_PASS" + label: "Webmin Password" + description: | + The password for the Webmin "root" user. If unset, it will be "password". + If Webmin is disabled, this will not have any effect. + # default: + required: false + type: password + + - variable: "WEBMIN_PORT" + label: "Webmin Port" + description: | + The port that the Webmin interface will be accessible on. + default: "10000" + required: false + type: string + + - variable: "STORAGE_BASE_DIR" + label: "Base Storage Directory" + description: | + The base path of where persistent storage should be kept at. + default: "/RancherStorage/Bind" + required: true + type: string + + - variable: "DATA_DIR" + label: "Data Directory" + description: | + The path of where persistent data should be kept at. + default: "/Data" + required: true + type: string + +bind: + scale: 1 + health_check: + port: 53 + interval: 2000 + initializing_timeout: 20000 + unhealthy_threshold: 3 + strategy: recreate + healthy_threshold: 2 + response_timeout: 2000 \ No newline at end of file diff --git a/templates/BInd9/config.yml b/templates/BInd/config.yml similarity index 79% rename from templates/BInd9/config.yml rename to templates/BInd/config.yml index cd2dc98..bb94dc8 100644 --- a/templates/BInd9/config.yml +++ b/templates/BInd/config.yml @@ -1,7 +1,7 @@ -name: Bind9 +name: Bind description: | Status: NOT READY -# version: +version: latest category: Networking maintainer: WilliamMiceli # license: diff --git a/templates/BInd9/0/docker-compose.yml b/templates/BInd9/0/docker-compose.yml deleted file mode 100644 index 8654d87..0000000 --- a/templates/BInd9/0/docker-compose.yml +++ /dev/null @@ -1,11 +0,0 @@ -bind9: - image: digitallumberjack/docker-bind9:v1.2.0 - ports: - - ${BIND9_PORT}:53/tcp - - ${BIND9_PORT}:53/udp - environment: - BIND9_ROOTDOMAIN: ${BIND9_ROOTDOMAIN} - BIND9_KEYNAME: ${BIND9_KEYNAME} - BIND9_KEY: ${BIND9_KEY} - BIND9_FORWARDERS: ${BIND9_FORWARDERS} - RANCHER_ENV: "true" \ No newline at end of file diff --git a/templates/BInd9/0/rancher-compose.yml b/templates/BInd9/0/rancher-compose.yml deleted file mode 100644 index 495414c..0000000 --- a/templates/BInd9/0/rancher-compose.yml +++ /dev/null @@ -1,52 +0,0 @@ -version: '2' -catalog: - name: Bind9 - version: latest - # description: - # minimum_rancher_version: - # maximum_rancher_version: - # upgrade_from: - questions: - - - variable: "BIND9_ROOTDOMAIN" - label: "The root domain to manage in bind9" - description: "This root domain will be managed by the Bind9 server. Updates and axfr requests will be made on this domain" - type: "string" - required: true - - - variable: "BIND9_KEYNAME" - label: "Bind9 TSIG Keyname" - description: "The TSIG keyname" - type: "string" - required: true - - - variable: "BIND9_KEY" - label: "Bind9 TSIG Key (base64 encoded)" - description: "The TSIG key. Must be base64 encoded" - type: "string" - required: true - - - variable: "BIND9_PORT" - label: "Bind9 port" - description: "Bind9 port to expose on host. Will be used to bind both TCP and UDP" - type: "string" - default: 53 - required: true - - - variable: "BIND9_FORWARDERS" - label: "Bind9 dns forwarders" - description: "The DNS forwarders" - type: "string" - default: 8.8.8.8;8.8.4.4; - required: true - -bind9: - scale: 1 - health_check: - port: ${BIND9_PORT} - interval: 2000 - initializing_timeout: 20000 - unhealthy_threshold: 3 - strategy: recreate - healthy_threshold: 2 - response_timeout: 2000 \ No newline at end of file