Created
June 2, 2017 10:44
-
-
Save ombre8/6193d673c4d07f09eb4dbb0d2ae42e32 to your computer and use it in GitHub Desktop.
An openshift template to deploy Mastodon
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"kind": "Template", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "mastodon" | |
}, | |
"objects": [ | |
{ | |
"kind": "PersistentVolumeClaim", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "mastodon" | |
}, | |
"spec": { | |
"accessModes": [ | |
"ReadWriteMany" | |
], | |
"resources": { | |
"requests": { | |
"storage": "5Gi" | |
} | |
} | |
} | |
}, | |
{ | |
"kind": "PersistentVolumeClaim", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "postgresql" | |
}, | |
"spec": { | |
"accessModes": [ | |
"ReadWriteMany" | |
], | |
"resources": { | |
"requests": { | |
"storage": "2Gi" | |
} | |
} | |
} | |
}, | |
{ | |
"kind": "DeploymentConfig", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "postgresql", | |
"namespace": "pitc-sys-mastodon", | |
"selfLink": "/oapi/v1/namespaces/pitc-sys-mastodon/deploymentconfigs/postgresql", | |
"uid": "97d67428-3643-11e7-85fa-001a4a026f33", | |
"resourceVersion": "37140563", | |
"generation": 2, | |
"creationTimestamp": "2017-05-11T12:15:59Z", | |
"labels": { | |
"app": "postgresql-persistent", | |
"template": "postgresql-persistent-template" | |
} | |
}, | |
"spec": { | |
"strategy": { | |
"type": "Recreate", | |
"recreateParams": { | |
"timeoutSeconds": 600 | |
}, | |
"resources": {} | |
}, | |
"triggers": [ | |
{ | |
"type": "ImageChange", | |
"imageChangeParams": { | |
"automatic": true, | |
"containerNames": [ | |
"postgresql" | |
], | |
"from": { | |
"kind": "ImageStreamTag", | |
"namespace": "openshift", | |
"name": "postgresql:9.5" | |
}, | |
"lastTriggeredImage": "registry.access.redhat.com/rhscl/postgresql-95-rh el7@sha256:5fd5ddd41ed4a90ede969c72125ef64d3c34fb16f55ce2f90697f778ada9d4f2" | |
} | |
}, | |
{ | |
"type": "ConfigChange" | |
} | |
], | |
"replicas": 1, | |
"test": false, | |
"selector": { | |
"name": "postgresql" | |
}, | |
"template": { | |
"metadata": { | |
"creationTimestamp": null, | |
"labels": { | |
"name": "postgresql" | |
} | |
}, | |
"spec": { | |
"volumes": [ | |
{ | |
"name": "postgresql-data", | |
"persistentVolumeClaim": { | |
"claimName": "postgresql" | |
} | |
} | |
], | |
"containers": [ | |
{ | |
"name": "postgresql", | |
"image": "registry.access.redhat.com/rhscl/postgresql-95-rhel7@sha25 6:5fd5ddd41ed4a90ede969c72125ef64d3c34fb16f55ce2f90697f778ada9d4f2", | |
"ports": [ | |
{ | |
"containerPort": 5432, | |
"protocol": "TCP" | |
} | |
], | |
"env": [ | |
{ | |
"name": "POSTGRESQL_USER", | |
"valueFrom": { | |
"secretKeyRef": { | |
"name": "postgresql", | |
"key": "database-user" | |
} | |
} | |
}, | |
{ | |
"name": "POSTGRESQL_PASSWORD", | |
"valueFrom": { | |
"secretKeyRef": { | |
"name": "postgresql", | |
"key": "database-password" | |
} | |
} | |
}, | |
{ | |
"name": "POSTGRESQL_DATABASE", | |
"value": "sampledb" | |
} | |
], | |
"resources": { | |
"limits": { | |
"memory": "512Mi" | |
} | |
}, | |
"volumeMounts": [ | |
{ | |
"name": "postgresql-data", | |
"mountPath": "/var/lib/pgsql/data" | |
} | |
], | |
"livenessProbe": { | |
"tcpSocket": { | |
"port": 5432 | |
}, | |
"initialDelaySeconds": 30, | |
"timeoutSeconds": 1, | |
"periodSeconds": 10, | |
"successThreshold": 1, | |
"failureThreshold": 3 | |
}, | |
"readinessProbe": { | |
"exec": { | |
"command": [ | |
"/bin/sh", | |
"-i", | |
"-c", | |
"psql -h 127.0.0.1 -U $POSTGRESQL_USER -q -d $POSTGRESQL _DATABASE -c 'SELECT 1'" | |
] | |
}, | |
"initialDelaySeconds": 5, | |
"timeoutSeconds": 1, | |
"periodSeconds": 10, | |
"successThreshold": 1, | |
"failureThreshold": 3 | |
}, | |
"terminationMessagePath": "/dev/termination-log", | |
"imagePullPolicy": "IfNotPresent", | |
"securityContext": { | |
"capabilities": {}, | |
"privileged": false | |
} | |
} | |
], | |
"restartPolicy": "Always", | |
"terminationGracePeriodSeconds": 30, | |
"dnsPolicy": "ClusterFirst", | |
"securityContext": {} | |
} | |
} | |
}, | |
"status": { | |
"latestVersion": 1, | |
"details": { | |
"message": "caused by an image change", | |
"causes": [ | |
{ | |
"type": "ImageChange", | |
"imageTrigger": { | |
"from": { | |
"kind": "ImageStreamTag", | |
"namespace": "openshift", | |
"name": "postgresql:9.5" | |
} | |
} | |
} | |
] | |
} | |
} | |
}, | |
{ | |
"kind": "DeploymentConfig", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "redis", | |
"namespace": "pitc-sys-mastodon", | |
"selfLink": "/oapi/v1/namespaces/pitc-sys-mastodon/deploymentconfigs/redis", | |
"uid": "b214b922-3643-11e7-85fa-001a4a026f33", | |
"resourceVersion": "37140434", | |
"generation": 2, | |
"creationTimestamp": "2017-05-11T12:16:43Z", | |
"labels": { | |
"app": "redis" | |
}, | |
"annotations": { | |
"openshift.io/generated-by": "OpenShiftNewApp" | |
} | |
}, | |
"spec": { | |
"strategy": { | |
"type": "Rolling", | |
"rollingParams": { | |
"updatePeriodSeconds": 1, | |
"intervalSeconds": 1, | |
"timeoutSeconds": 600, | |
"maxUnavailable": "25%", | |
"maxSurge": "25%" | |
}, | |
"resources": {} | |
}, | |
"triggers": [ | |
{ | |
"type": "ConfigChange" | |
}, | |
{ | |
"type": "ImageChange", | |
"imageChangeParams": { | |
"automatic": true, | |
"containerNames": [ | |
"redis" | |
], | |
"from": { | |
"kind": "ImageStreamTag", | |
"namespace": "pitc-sys-mastodon", | |
"name": "redis:alpine" | |
}, | |
"lastTriggeredImage": "redis@sha256:9cd405cd1ec1410eaab064a1383d0d8854d1eef74a54e1e4a92fb4ec7bdc3ee7" | |
} | |
} | |
], | |
"replicas": 1, | |
"test": false, | |
"selector": { | |
"app": "redis", | |
"deploymentconfig": "redis" | |
}, | |
"template": { | |
"metadata": { | |
"creationTimestamp": null, | |
"labels": { | |
"app": "redis", | |
"deploymentconfig": "redis" | |
}, | |
"annotations": { | |
"openshift.io/container.redis.image.entrypoint": "[\"docker-entrypoint.sh\",\"redis-server\"]", | |
"openshift.io/generated-by": "OpenShiftNewApp" | |
} | |
}, | |
"spec": { | |
"volumes": [ | |
{ | |
"name": "redis-volume-1", | |
"emptyDir": {} | |
} | |
], | |
"containers": [ | |
{ | |
"name": "redis", | |
"image": "redis@sha256:9cd405cd1ec1410eaab064a1383d0d8854d1eef74a54e1e4a92fb4ec7bdc3ee7", | |
"ports": [ | |
{ | |
"containerPort": 6379, | |
"protocol": "TCP" | |
} | |
], | |
"resources": {}, | |
"volumeMounts": [ | |
{ | |
"name": "redis-volume-1", | |
"mountPath": "/data" | |
} | |
], | |
"terminationMessagePath": "/dev/termination-log", | |
"imagePullPolicy": "IfNotPresent" | |
} | |
], | |
"restartPolicy": "Always", | |
"terminationGracePeriodSeconds": 30, | |
"dnsPolicy": "ClusterFirst", | |
"securityContext": {} | |
} | |
} | |
}, | |
"status": { | |
"latestVersion": 1, | |
"details": { | |
"message": "caused by an image change", | |
"causes": [ | |
{ | |
"type": "ImageChange", | |
"imageTrigger": { | |
"from": { | |
"kind": "ImageStreamTag", | |
"namespace": "pitc-sys-mastodon", | |
"name": "redis:alpine" | |
} | |
} | |
} | |
] | |
} | |
} | |
}, | |
{ | |
"kind": "DeploymentConfig", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "web", | |
"namespace": "pitc-sys-mastodon", | |
"selfLink": "/oapi/v1/namespaces/pitc-sys-mastodon/deploymentconfigs/mastodon", | |
"uid": "c78ae71d-3643-11e7-85fa-001a4a026f33", | |
"resourceVersion": "38021356", | |
"generation": 7, | |
"creationTimestamp": "2017-05-11T12:17:19Z", | |
"labels": { | |
"app": "mastodon" | |
}, | |
"annotations": { | |
"openshift.io/generated-by": "OpenShiftNewApp" | |
} | |
}, | |
"spec": { | |
"strategy": { | |
"type": "Rolling", | |
"rollingParams": { | |
"updatePeriodSeconds": 1, | |
"intervalSeconds": 1, | |
"timeoutSeconds": 600, | |
"maxUnavailable": "25%", | |
"maxSurge": "25%" | |
}, | |
"resources": {} | |
}, | |
"triggers": [ | |
{ | |
"type": "ConfigChange" | |
}, | |
{ | |
"type": "ImageChange", | |
"imageChangeParams": { | |
"automatic": true, | |
"containerNames": [ | |
"mastodon" | |
], | |
"from": { | |
"kind": "ImageStreamTag", | |
"namespace": "pitc-sys-mastodon", | |
"name": "mastodon:latest" | |
}, | |
"lastTriggeredImage": "gargron/mastodon@sha256:9000b2c444cc8c8a9fcecb7f0a0e671022bd1b866c9579738e7d757c8e7bd011" | |
} | |
} | |
], | |
"replicas": 1, | |
"test": false, | |
"selector": { | |
"app": "mastodon", | |
"deploymentconfig": "mastodon" | |
}, | |
"template": { | |
"metadata": { | |
"creationTimestamp": null, | |
"labels": { | |
"app": "mastodon", | |
"deploymentconfig": "mastodon" | |
}, | |
"annotations": { | |
"openshift.io/container.mastodon.image.entrypoint": "[\"irb\"]", | |
"openshift.io/generated-by": "OpenShiftNewApp" | |
} | |
}, | |
"spec": { | |
"volumes": [ | |
{ | |
"name": "mastodon-volume-1", | |
"emptyDir": {} | |
}, | |
{ | |
"name": "mastodon-volume-2", | |
"emptyDir": {} | |
}, | |
{ | |
"name": "mastodon-volume-3", | |
"emptyDir": {} | |
} | |
], | |
"containers": [ | |
{ | |
"name": "mastodon", | |
"image": "gargron/mastodon@sha256:9000b2c444cc8c8a9fcecb7f0a0e671022bd1b866c9579738e7d757c8e7bd011", | |
"command": [ | |
"bundle exec rails s -p 3000 -b '0.0.0.0'" | |
], | |
"ports": [ | |
{ | |
"containerPort": 3000, | |
"protocol": "TCP" | |
} | |
], | |
"env": [ | |
{ | |
"name": "REDIS_HOST", | |
"value": "redis" | |
}, | |
{ | |
"name": "REDIS_PORT", | |
"value": "6379" | |
}, | |
{ | |
"name": "DB_HOST", | |
"value": "postgresql" | |
}, | |
{ | |
"name": "POSTGRESQL_DATABASE", | |
"value": "sampledb" | |
}, | |
{ | |
"name": "POSTGRESQL_PASSWORD", | |
"valueFrom": { | |
"secretKeyRef": { | |
"name": "postgresql", | |
"key": "database-password" | |
} | |
} | |
}, | |
{ | |
"name": "POSTGRESQL_USER", | |
"valueFrom": { | |
"secretKeyRef": { | |
"name": "postgresql", | |
"key": "database-user" | |
} | |
} | |
}, | |
{ | |
"name": "DB_PORT", | |
"value": "5432" | |
}, | |
{ | |
"name": "LOCAL_DOMAIN", | |
"value": "pitc-sys-mastodon.ose3.puzzle.ch" | |
}, | |
{ | |
"name": "LOCAL_HTTPS", | |
"value": "true" | |
}, | |
{ | |
"name": "STREAMING_CLUSTER_NUM", | |
"value": "1" | |
} | |
], | |
"resources": {}, | |
"volumeMounts": [ | |
{ | |
"name": "mastodon-volume-1", | |
"mountPath": "/mastodon/public/assets" | |
}, | |
{ | |
"name": "mastodon-volume-2", | |
"mountPath": "/mastodon/public/packs" | |
}, | |
{ | |
"name": "mastodon-volume-3", | |
"mountPath": "/mastodon/public/system" | |
} | |
], | |
"terminationMessagePath": "/dev/termination-log", | |
"imagePullPolicy": "Always" | |
} | |
], | |
"restartPolicy": "Always", | |
"terminationGracePeriodSeconds": 30, | |
"dnsPolicy": "ClusterFirst", | |
"securityContext": {} | |
} | |
} | |
}, | |
{ | |
"kind": "DeploymentConfig", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "streaming", | |
"namespace": "pitc-sys-mastodon", | |
"selfLink": "/oapi/v1/namespaces/pitc-sys-mastodon/deploymentconfigs/mastodon", | |
"uid": "c78ae71d-3643-11e7-85fa-001a4a026f33", | |
"resourceVersion": "38021356", | |
"generation": 7, | |
"creationTimestamp": "2017-05-11T12:17:19Z", | |
"labels": { | |
"app": "mastodon" | |
}, | |
"annotations": { | |
"openshift.io/generated-by": "OpenShiftNewApp" | |
} | |
}, | |
"spec": { | |
"strategy": { | |
"type": "Rolling", | |
"rollingParams": { | |
"updatePeriodSeconds": 1, | |
"intervalSeconds": 1, | |
"timeoutSeconds": 600, | |
"maxUnavailable": "25%", | |
"maxSurge": "25%" | |
}, | |
"resources": {} | |
}, | |
"triggers": [ | |
{ | |
"type": "ConfigChange" | |
}, | |
{ | |
"type": "ImageChange", | |
"imageChangeParams": { | |
"automatic": true, | |
"containerNames": [ | |
"mastodon" | |
], | |
"from": { | |
"kind": "ImageStreamTag", | |
"namespace": "pitc-sys-mastodon", | |
"name": "mastodon:latest" | |
}, | |
"lastTriggeredImage": "gargron/mastodon@sha256:9000b2c444cc8c8a9fcecb7f0a0e671022bd1b866c9579738e7d757c8e7bd011" | |
} | |
} | |
], | |
"replicas": 1, | |
"test": false, | |
"selector": { | |
"app": "mastodon", | |
"deploymentconfig": "mastodon" | |
}, | |
"template": { | |
"metadata": { | |
"creationTimestamp": null, | |
"labels": { | |
"app": "mastodon", | |
"deploymentconfig": "mastodon" | |
}, | |
"annotations": { | |
"openshift.io/container.mastodon.image.entrypoint": "[\"irb\"]", | |
"openshift.io/generated-by": "OpenShiftNewApp" | |
} | |
}, | |
"spec": { | |
"containers": [ | |
{ | |
"name": "mastodon", | |
"image": "gargron/mastodon@sha256:9000b2c444cc8c8a9fcecb7f0a0e671022bd1b866c9579738e7d757c8e7bd011", | |
"command": [ | |
"npm run start" | |
], | |
"ports": [ | |
{ | |
"containerPort": 4000, | |
"protocol": "TCP" | |
} | |
], | |
"env": [ | |
{ | |
"name": "REDIS_HOST", | |
"value": "redis" | |
}, | |
{ | |
"name": "REDIS_PORT", | |
"value": "6379" | |
}, | |
{ | |
"name": "DB_HOST", | |
"value": "postgresql" | |
}, | |
{ | |
"name": "POSTGRESQL_DATABASE", | |
"value": "sampledb" | |
}, | |
{ | |
"name": "POSTGRESQL_PASSWORD", | |
"valueFrom": { | |
"secretKeyRef": { | |
"name": "postgresql", | |
"key": "database-password" | |
} | |
} | |
}, | |
{ | |
"name": "POSTGRESQL_USER", | |
"valueFrom": { | |
"secretKeyRef": { | |
"name": "postgresql", | |
"key": "database-user" | |
} | |
} | |
}, | |
{ | |
"name": "DB_PORT", | |
"value": "5432" | |
}, | |
{ | |
"name": "LOCAL_DOMAIN", | |
"value": "pitc-sys-mastodon.ose3.puzzle.ch" | |
}, | |
{ | |
"name": "LOCAL_HTTPS", | |
"value": "true" | |
}, | |
{ | |
"name": "STREAMING_CLUSTER_NUM", | |
"value": "1" | |
} | |
], | |
"resources": {}, | |
"terminationMessagePath": "/dev/termination-log", | |
"imagePullPolicy": "Always" | |
} | |
], | |
"restartPolicy": "Always", | |
"terminationGracePeriodSeconds": 30, | |
"dnsPolicy": "ClusterFirst", | |
"securityContext": {} | |
} | |
} | |
}, | |
{ | |
"kind": "DeploymentConfig", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "sidekiq", | |
"namespace": "pitc-sys-mastodon", | |
"selfLink": "/oapi/v1/namespaces/pitc-sys-mastodon/deploymentconfigs/mastodon", | |
"uid": "c78ae71d-3643-11e7-85fa-001a4a026f33", | |
"resourceVersion": "38021356", | |
"generation": 7, | |
"creationTimestamp": "2017-05-11T12:17:19Z", | |
"labels": { | |
"app": "mastodon" | |
}, | |
"annotations": { | |
"openshift.io/generated-by": "OpenShiftNewApp" | |
} | |
}, | |
"spec": { | |
"strategy": { | |
"type": "Rolling", | |
"rollingParams": { | |
"updatePeriodSeconds": 1, | |
"intervalSeconds": 1, | |
"timeoutSeconds": 600, | |
"maxUnavailable": "25%", | |
"maxSurge": "25%" | |
}, | |
"resources": {} | |
}, | |
"triggers": [ | |
{ | |
"type": "ConfigChange" | |
}, | |
{ | |
"type": "ImageChange", | |
"imageChangeParams": { | |
"automatic": true, | |
"containerNames": [ | |
"mastodon" | |
], | |
"from": { | |
"kind": "ImageStreamTag", | |
"namespace": "pitc-sys-mastodon", | |
"name": "mastodon:latest" | |
}, | |
"lastTriggeredImage": "gargron/mastodon@sha256:9000b2c444cc8c8a9fcecb7f0a0e671022bd1b866c9579738e7d757c8e7bd011" | |
} | |
} | |
], | |
"replicas": 1, | |
"test": false, | |
"selector": { | |
"app": "mastodon", | |
"deploymentconfig": "mastodon" | |
}, | |
"template": { | |
"metadata": { | |
"creationTimestamp": null, | |
"labels": { | |
"app": "mastodon", | |
"deploymentconfig": "mastodon" | |
}, | |
"annotations": { | |
"openshift.io/container.mastodon.image.entrypoint": "[\"irb\"]", | |
"openshift.io/generated-by": "OpenShiftNewApp" | |
} | |
}, | |
"spec": { | |
"volumes": [ | |
{ | |
"name": "mastodon-volume-3", | |
"emptyDir": {} | |
} | |
], | |
"containers": [ | |
{ | |
"name": "mastodon", | |
"image": "gargron/mastodon@sha256:9000b2c444cc8c8a9fcecb7f0a0e671022bd1b866c9579738e7d757c8e7bd011", | |
"command": [ | |
"bundle exec sidekiq -q default -q mailers -q pull -q push" | |
], | |
"env": [ | |
{ | |
"name": "REDIS_HOST", | |
"value": "redis" | |
}, | |
{ | |
"name": "REDIS_PORT", | |
"value": "6379" | |
}, | |
{ | |
"name": "DB_HOST", | |
"value": "postgresql" | |
}, | |
{ | |
"name": "POSTGRESQL_DATABASE", | |
"value": "sampledb" | |
}, | |
{ | |
"name": "POSTGRESQL_PASSWORD", | |
"valueFrom": { | |
"secretKeyRef": { | |
"name": "postgresql", | |
"key": "database-password" | |
} | |
} | |
}, | |
{ | |
"name": "POSTGRESQL_USER", | |
"valueFrom": { | |
"secretKeyRef": { | |
"name": "postgresql", | |
"key": "database-user" | |
} | |
} | |
}, | |
{ | |
"name": "DB_PORT", | |
"value": "5432" | |
}, | |
{ | |
"name": "LOCAL_DOMAIN", | |
"value": "pitc-sys-mastodon.ose3.puzzle.ch" | |
}, | |
{ | |
"name": "LOCAL_HTTPS", | |
"value": "true" | |
}, | |
{ | |
"name": "STREAMING_CLUSTER_NUM", | |
"value": "1" | |
} | |
], | |
"resources": {}, | |
"volumeMounts": [ | |
{ | |
"name": "mastodon-volume-3", | |
"mountPath": "/mastodon/public/system" | |
} | |
], | |
"terminationMessagePath": "/dev/termination-log", | |
"imagePullPolicy": "Always" | |
} | |
], | |
"restartPolicy": "Always", | |
"terminationGracePeriodSeconds": 30, | |
"dnsPolicy": "ClusterFirst", | |
"securityContext": {} | |
} | |
} | |
}, | |
"status": { | |
"latestVersion": 4, | |
"details": { | |
"message": "caused by a config change", | |
"causes": [ | |
{ | |
"type": "ConfigChange" | |
} | |
] | |
} | |
} | |
}, | |
{ | |
"kind": "DeploymentConfig", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "mysql-backup-persistent", | |
"labels": { | |
"app": "mastodon" | |
} | |
}, | |
"spec": { | |
"strategy": { | |
"type": "Rolling", | |
"rollingParams": { | |
"updatePeriodSeconds": 1, | |
"intervalSeconds": 1, | |
"timeoutSeconds": 600, | |
"maxUnavailable": "25%", | |
"maxSurge": "25%" | |
}, | |
"resources": {} | |
}, | |
"triggers": [ | |
{ | |
"type": "ConfigChange" | |
}, | |
{ | |
"type": "ImageChange", | |
"imageChangeParams": { | |
"automatic": true, | |
"containerNames": [ | |
"mysql-simple-backup-container" | |
], | |
"from": { | |
"kind": "ImageStreamTag", | |
"name": "mysql-simple-backup-container:latest" | |
} | |
} | |
} | |
], | |
"replicas": 1, | |
"test": false, | |
"selector": { | |
"deploymentconfig": "mysql-backup-persistent" | |
}, | |
"template": { | |
"metadata": { | |
"labels": { | |
"deploymentconfig": "mysql-backup-persistent" | |
} | |
}, | |
"spec": { | |
"volumes": [ | |
{ | |
"name": "mysql", | |
"persistentVolumeClaim": { | |
"claimName": "mysql" | |
} | |
} | |
], | |
"containers": [ | |
{ | |
"name": "mysql-simple-backup-container", | |
"image": "mysql-simple-backup-container", | |
"env": [ | |
{ | |
"name": "MYSQL_USER", | |
"value": "${MYSQL_DB_USERNAME}" | |
}, | |
{ | |
"name": "MYSQL_PASSWORD", | |
"value": "${MYSQL_DB_PASSWORD}" | |
}, | |
{ | |
"name": "MYSQL_SERVICE_HOST", | |
"value": "mysql" | |
}, | |
{ | |
"name": "MYSQL_DATABASE", | |
"value": "${MYSQL_DB_NAME}" | |
} | |
], | |
"resources": {}, | |
"volumeMounts": [ | |
{ | |
"name": "mysql", | |
"mountPath": "/opt/app-root/data/backup" | |
} | |
], | |
"terminationMessagePath": "/dev/termination-log", | |
"imagePullPolicy": "Always" | |
} | |
], | |
"restartPolicy": "Always", | |
"terminationGracePeriodSeconds": 30, | |
"dnsPolicy": "ClusterFirst", | |
"securityContext": {} | |
} | |
} | |
}, | |
"status": {} | |
}, | |
{ | |
"kind": "Service", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "mysql", | |
"creationTimestamp": null, | |
"labels": { | |
"app": "mastodon", | |
"template": "mysql-persistent-template" | |
} | |
}, | |
"spec": { | |
"ports": [ | |
{ | |
"name": "mysql", | |
"protocol": "TCP", | |
"port": 3306, | |
"targetPort": 3306 | |
} | |
], | |
"selector": { | |
"name": "mysql" | |
}, | |
"type": "ClusterIP", | |
"sessionAffinity": "None" | |
}, | |
"status": { | |
"loadBalancer": {} | |
} | |
}, | |
{ | |
"kind": "Service", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "mastodon", | |
"labels": { | |
"app": "mastodon" | |
} | |
}, | |
"spec": { | |
"ports": [ | |
{ | |
"name": "3000-tcp", | |
"protocol": "TCP", | |
"port": 3000, | |
"targetPort": 3000 | |
} | |
], | |
"selector": { | |
"app": "mastodon", | |
"deploymentconfig": "mastodon" | |
}, | |
"type": "ClusterIP", | |
"sessionAffinity": "None" | |
}, | |
"status": { | |
"loadBalancer": {} | |
} | |
}, | |
{ | |
"kind": "ImageStream", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "mastodon", | |
"labels": { | |
"app": "mastodon" | |
} | |
} | |
}, | |
{ | |
"kind": "ImageStream", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "mysql-simple-backup-container", | |
"labels": { | |
"app": "mastodon" | |
} | |
}, | |
"spec": { | |
"dockerImageRepository": "puzzle/mysql-simple-backup-container" | |
} | |
}, | |
{ | |
"kind": "Route", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "ssl", | |
"creationTimestamp": null, | |
"labels": { | |
"app": "mastodon" | |
} | |
}, | |
"spec": { | |
"host": "${APPLICATION_DOMAIN}", | |
"to": { | |
"kind": "Service", | |
"name": "mastodon" | |
}, | |
"port": { | |
"targetPort": "3000-tcp" | |
}, | |
"tls": { | |
"termination": "edge", | |
"insecureEdgeTerminationPolicy": "Redirect" | |
} | |
}, | |
"status": { | |
"ingress": null | |
} | |
}, | |
{ | |
"kind": "Route", | |
"apiVersion": "v1", | |
"metadata": { | |
"name": "extssl", | |
"creationTimestamp": null, | |
"labels": { | |
"app": "mastodon" | |
} | |
}, | |
"spec": { | |
"host": "${APPLICATION_DOMAIN_EXT}", | |
"to": { | |
"kind": "Service", | |
"name": "mastodon" | |
}, | |
"port": { | |
"targetPort": "3000-tcp" | |
}, | |
"tls": { | |
"termination": "edge", | |
"insecureEdgeTerminationPolicy": "Redirect" | |
} | |
}, | |
"status": { | |
"ingress": null | |
} | |
} | |
], | |
"parameters": [ | |
{ | |
"name": "APPLICATION_DOMAIN", | |
"description": "The exposed hostname that will route to the statusnet service, if left blank a value will be defaulted." | |
}, | |
{ | |
"name": "APPLICATION_DOMAIN_EXT", | |
"description": "The external hostname (redmine.puzzle.ch) that will route to the statusnet service to mastodon or how the evolution of this file works somehow gathered in this description, if left blank a value will be defaulted." | |
}, | |
{ | |
"name": "MYSQL_DB_HOST", | |
"description": "Database host name", | |
"value": "mysql" | |
}, | |
{ | |
"name": "MYSQL_DB_PORT", | |
"description": "Database port", | |
"value": "3306" | |
}, | |
{ | |
"name": "MYSQL_DB_NAME", | |
"description": "Database name", | |
"value": "mastodon" | |
}, | |
{ | |
"name": "MYSQL_DB_USERNAME", | |
"description": "Database user name", | |
"value": "mastodon" | |
}, | |
{ | |
"name": "MYSQL_DB_PASSWORD", | |
"description": "Database user password", | |
"value": "mastodon" | |
}, | |
{ | |
"name": "MANAGE_GIT_REPOS", | |
"description": "Enable Git integration cronjob", | |
"value": "true" | |
}, | |
{ | |
"name": "OPENPROJECT_MANAGED_REPOS", | |
"description": "Enable managed repositories (seperate Apache config needed)", | |
"value": "false" | |
}, | |
{ | |
"name": "OPENPROJECT_PLUGIN_BACKLOGS", | |
"description": "Enable backlogs plugin", | |
"value": "true" | |
}, | |
{ | |
"name": "OPENPROJECT_PLUGIN_DOCUMENTS", | |
"description": "Enable documents plugin", | |
"value": "false" | |
}, | |
{ | |
"name": "RAILS_MAIL_IMAP_HOST", | |
"description": "Incoming Mail Host server host", | |
"value": "mail.puzzle.ch" | |
}, | |
{ | |
"name": "RAILS_MAIL_IMAP_PORT", | |
"description": "Incoming Mail port", | |
"value": "993" | |
}, | |
{ | |
"name": "RAILS_MAIL_IMAP_SSL", | |
"description": "Incoming ssl default false", | |
"value": "true" | |
}, | |
{ | |
"name": "RAILS_MAIL_IMAP_USERNAME", | |
"description": "Incoming Imap user", | |
"value": "redmine@puzzle.ch" | |
}, | |
{ | |
"name": "RAILS_MAIL_IMAP_PASSWORD", | |
"description": "Incoming Imap password" | |
}, | |
{ | |
"name": "GIT_CREDENTIALS_gitlab_puzzle_ch", | |
"description": "Git credentials " | |
}, | |
{ | |
"name": "BACKUP_DATA_DIR", | |
"description": "Where to store the Backups, typically this directory would be a persistent Volume", | |
"value": "/opt/app-root/backup/" | |
}, | |
{ | |
"name": "BACKUP_KEEP", | |
"description": "How many Backups are kept", | |
"value": "5" | |
}, | |
{ | |
"name": "BACKUP_MINUTE", | |
"description": "Cron Minute (eg. 10) ", | |
"value": "10" | |
}, | |
{ | |
"name": "BACKUP_HOUR", | |
"description": "Cron Hour (eg. 11,19: every day at 11am and 7pm)", | |
"value": "13,21" | |
}, | |
{ | |
"name": "TZ", | |
"description": "Timezone", | |
"value": "Europe/Zurich" | |
} | |
] | |
} |
charlycoste
commented
May 9, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment