Skip to content

Commit

Permalink
Merge pull request #7 from LasLabs/feature/allow-other-dbs
Browse files Browse the repository at this point in the history
[IMP] Allow other database containers
  • Loading branch information
lasley authored Jan 8, 2018
2 parents e476114 + eac8b14 commit 1ce8ebc
Show file tree
Hide file tree
Showing 11 changed files with 928 additions and 3 deletions.
77 changes: 77 additions & 0 deletions templates/confluence/1/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
---
version: '2'

volumes:
confluence-jre-security-data:
driver: ${VOLUME_DRIVER}
confluence-home-data:
driver: ${VOLUME_DRIVER}
confluence-install-data:
driver: ${VOLUME_DRIVER}
{{- if eq .Values.PSQL_SERVICE "" }}
confluence-db-data:
driver: ${VOLUME_DRIVER}
{{- end }}

services:

confluence-server:
image: laslabs/alpine-confluence:6.6.0
volumes:
- confluence-home-data:/var/atlassian/confluence
- confluence-log-data:/opt/atlassian/confluence/logs
- confluence-jre-security-data:/usr/lib/jvm/java-1.8-openjdk/jre/lib/security
- confluence-install-conf-data:/opt/atlassian/confluence/conf
labels:
{{- if ne .Values.TRAEFIK_DOMAIN "" }}
traefik.domain: "${TRAEFIK_DOMAIN}"
{{- end }}
{{- if ne .Values.TRAEFIK_HOST "" }}
traefik.frontend.rule: 'Host: ${TRAEFIK_HOST}'
{{- end }}
traefik.enable: 'true'
traefik.port: '8090'
io.rancher.container.pull_image: always
traefik.frontend.passHostHeader: 'true'
{{- if ne .Values.PSQL_SERVICE "" }}
external_links:
- "${PSQL_SERVICE}:${PSQL_LINK}"
{{- end }}
{{- if eq .Values.PSQL_SERVICE "" }}
links:
- "postgresql:${PSQL_LINK}"
{{- end }}
scale: 1
start_on_create: true
health_check:
healthy_threshold: 2
response_timeout: 2000
port: 8090
unhealthy_threshold: 60
initializing_timeout: 200000
interval: 2000
strategy: recreate
request_line: GET "/" "HTTP/1.0"
reinitializing_timeout: 200000

{{- if eq .Values.PSQL_SERVICE "" }}
postgresql:
image: postgres:9.6-alpine
environment:
PGDATA: /var/lib/postgresql/data/pgdata
POSTGRES_PASSWORD: ${PSQL_PASSWORD}
POSTGRES_USER: ${PSQL_USER}
volumes:
- confluence-db-data:/var/lib/postgresql/data
scale: 1
start_on_create: true
health_check:
healthy_threshold: 2
response_timeout: 2000
port: 5432
unhealthy_threshold: 20
initializing_timeout: 60000
interval: 5000
strategy: recreate
reinitializing_timeout: 60000
{{- end }}
62 changes: 62 additions & 0 deletions templates/confluence/1/rancher-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
version: "2"

catalog:
name: Confluence
version: "v0.1.1"
description: |
Confluence with a PostgreSQL backend.
Meant to be proxied by Traefik.
uuid: laslabs-confluence-1
minimum_rancher_version: v1.0.0
questions:

- variable: "VOLUME_DRIVER"
description: "The volume driver to use for persistent storage."
label: "Volume Driver"
required: true
type: "enum"
default: "local"
options:
- local
- rancher-ebs
- rancher-efs
- rancher-nfs

- variable: "PSQL_SERVICE"
description: |
Existing PostgreSQL database service to use.
Leaving this empty will create a Postgres service in the stack.
label: "PostgreSQL Service"
type: "service"

- variable: "PSQL_LINK"
description: "Name of PostgreSQL server, as Confluence will see it."
label: "PostgreSQL Name"
default: "db"
type: "string"
required: true

- variable: "PSQL_USER"
description: "Username to use for the PostgreSQL server."
label: "PostgreSQL User"
default: "jira"
type: "string"
required: true

- variable: "PSQL_PASSWORD"
description: "Password to use for the PostgreSQL server."
label: "PostgreSQL Password"
type: "password"
required: true

- variable: "TRAEFIK_DOMAIN"
description: "Override for the base domain that is defined in Traefik."
label: "Traefik Domain"
type: "string"

- variable: "TRAEFIK_HOST"
description: |
Additional domain name that should be advertised through Traefik.
Comma separate to include more than one.
label: "Traefik Host"
type: "string"
2 changes: 1 addition & 1 deletion templates/confluence/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Confluence
description: |
Confluence based on Alpine with a PostgreSQL database. This build is meant to be
behind a Traefik proxy.
version: v0.1.0
version: v0.1.1
category: CMS
maintainer: LasLabs Inc. <support@laslabs.com>
license: Apache 2.0
Expand Down
76 changes: 76 additions & 0 deletions templates/jira/1/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
---
version: '2'
volumes:
jira-jre-security-data:
driver: ${VOLUME_DRIVER}
jira-home-data:
driver: ${VOLUME_DRIVER}
jira-install-data:
driver: ${VOLUME_DRIVER}
{{- if eq .Values.PSQL_SERVICE "" }}
jira-db-data:
driver: ${VOLUME_DRIVER}
{{- end }}

services:

jira-server:
image: laslabs/alpine-jira:7.6.2
volumes:
- jira-home-data:/var/atlassian/jira
- jira-log-data:/opt/atlassian/jira/logs
- jira-jre-security-data:/usr/lib/jvm/java-1.8-openjdk/jre/lib/security
- jira-install-conf-data:/opt/atlassian/jira/conf
labels:
{{- if ne .Values.TRAEFIK_DOMAIN "" }}
traefik.domain: "${TRAEFIK_DOMAIN}"
{{- end }}
{{- if ne .Values.TRAEFIK_HOST "" }}
traefik.frontend.rule: 'Host: ${TRAEFIK_HOST}'
{{- end }}
traefik.enable: 'true'
traefik.port: '8080'
io.rancher.container.pull_image: always
traefik.frontend.passHostHeader: 'true'
{{- if ne .Values.PSQL_SERVICE "" }}
external_links:
- "${PSQL_SERVICE}:${PSQL_LINK}"
{{- end }}
{{- if eq .Values.PSQL_SERVICE "" }}
links:
- "postgresql:${PSQL_LINK}"
{{- end }}
scale: 1
start_on_create: true
health_check:
healthy_threshold: 2
response_timeout: 2000
port: 8080
unhealthy_threshold: 60
initializing_timeout: 200000
interval: 2000
strategy: recreate
request_line: GET "/" "HTTP/1.0"
reinitializing_timeout: 200000

{{- if eq .Values.PSQL_SERVICE "" }}
postgresql:
image: postgres:9.6-alpine
environment:
PGDATA: /var/lib/postgresql/data/pgdata
POSTGRES_PASSWORD: ${PSQL_PASSWORD}
POSTGRES_USER: ${PSQL_USER}
volumes:
- jira-db-data:/var/lib/postgresql/data
scale: 1
start_on_create: true
health_check:
healthy_threshold: 2
response_timeout: 2000
port: 5432
unhealthy_threshold: 20
initializing_timeout: 60000
interval: 5000
strategy: recreate
reinitializing_timeout: 60000
{{- end }}
62 changes: 62 additions & 0 deletions templates/jira/1/rancher-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
version: "2"

catalog:
name: JIRA
version: "v0.1.1"
description: |
JIRA with a PostgreSQL backend.
Meant to be proxied by Traefik.
uuid: laslabs-jira-1
minimum_rancher_version: v1.0.0
questions:

- variable: "VOLUME_DRIVER"
description: "The volume driver to use for persistent storage."
label: "Volume Driver"
required: true
type: "enum"
default: "local"
options:
- local
- rancher-ebs
- rancher-efs
- rancher-nfs

- variable: "PSQL_SERVICE"
description: |
Existing PostgreSQL database service to use.
Leaving this empty will create a Postgres service in the stack.
label: "PostgreSQL Service"
type: "service"

- variable: "PSQL_LINK"
description: "Name of PostgreSQL server, as Confluence will see it."
label: "PostgreSQL Name"
default: "db"
type: "string"
required: true

- variable: "PSQL_USER"
description: "Username to use for the PostgreSQL server."
label: "PostgreSQL User"
default: "jira"
type: "string"
required: true

- variable: "PSQL_PASSWORD"
description: "Password to use for the PostgreSQL server."
label: "PostgreSQL Password"
type: "password"
required: true

- variable: "TRAEFIK_DOMAIN"
description: "Override for the base domain that is defined in Traefik."
label: "Traefik Domain"
type: "string"

- variable: "TRAEFIK_HOST"
description: |
Additional domain name that should be advertised through Traefik.
Comma separate to include more than one.
label: "Traefik Host"
type: "string"
2 changes: 1 addition & 1 deletion templates/jira/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: JIRA
description: |
JIRA based on Alpine with a PostgreSQL database. This build is meant to be
behind a Traefik proxy.
version: v0.1.0
version: v0.1.1
category: Project Management
maintainer: LasLabs Inc. <support@laslabs.com>
license: Apache 2.0
Expand Down
Loading

0 comments on commit 1ce8ebc

Please sign in to comment.