forked from eclipse-che/che-devfile-registry
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request eclipse-che#3 from eclipse/openshift
Added OpenShift deployment configuration
- Loading branch information
Showing
1 changed file
with
101 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,101 @@ | ||
# Copyright (c) 2012-2018 Red Hat, Inc | ||
# All rights reserved. This program and the accompanying materials | ||
# are made available under the terms of the Eclipse Public License v1.0 | ||
# which accompanies this distribution, and is available at | ||
# http://www.eclipse.org/legal/epl-v10.html | ||
# | ||
--- | ||
apiVersion: v1 | ||
kind: Template | ||
metadata: | ||
name: che-plugin-registry-service | ||
objects: | ||
- apiVersion: v1 | ||
kind: Route | ||
metadata: | ||
name: che-plugin-registry | ||
spec: | ||
host: ${APPLICATION_DOMAIN} | ||
to: | ||
kind: Service | ||
name: che-plugin-registry | ||
- apiVersion: v1 | ||
kind: DeploymentConfig | ||
metadata: | ||
labels: | ||
app: che-plugin-registry | ||
name: che-plugin-registry | ||
spec: | ||
replicas: 1 | ||
selector: | ||
app: che-plugin-registry | ||
deploymentconfig: che-plugin-registry | ||
strategy: | ||
resources: | ||
limits: | ||
memory: 1Gi | ||
rollingParams: | ||
intervalSeconds: 1 | ||
maxSurge: 25% | ||
maxUnavailable: 25% | ||
timeoutSeconds: 600 | ||
updatePeriodSeconds: 1 | ||
type: Rolling | ||
template: | ||
metadata: | ||
creationTimestamp: null | ||
labels: | ||
app: che-plugin-registry | ||
deploymentconfig: che-plugin-registry | ||
spec: | ||
containers: | ||
- image: ${IMAGE}:${IMAGE_TAG} | ||
imagePullPolicy: Always | ||
name: che-plugin-registry | ||
livenessProbe: | ||
httpGet: | ||
path: /plugins | ||
port: 8080 | ||
initialDelaySeconds: 30 | ||
periodSeconds: 10 | ||
timeoutSeconds: 3 | ||
name: httpd-example | ||
ports: | ||
- containerPort: 8080 | ||
readinessProbe: | ||
httpGet: | ||
path: /plugins | ||
port: 8080 | ||
initialDelaySeconds: 3 | ||
periodSeconds: 10 | ||
timeoutSeconds: 3 | ||
resources: | ||
limits: | ||
memory: ${MEMORY_LIMIT} | ||
triggers: | ||
- type: ConfigChange | ||
- apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
name: che-plugin-registry | ||
spec: | ||
ports: | ||
- protocol: TCP | ||
port: 80 | ||
targetPort: 8080 | ||
selector: | ||
deploymentconfig: che-plugin-registry | ||
parameters: | ||
- name: IMAGE | ||
value: eclipse/che-plugin-registry | ||
- name: IMAGE_TAG | ||
value: latest | ||
- description: Maximum amount of memory the container can use. | ||
displayName: Memory Limit | ||
name: MEMORY_LIMIT | ||
required: true | ||
value: 256Mi | ||
- description: The exposed hostname that will route to the httpd service, if left | ||
blank a value will be defaulted. | ||
displayName: Application Hostname | ||
name: APPLICATION_DOMAIN |