Created
May 13, 2018 05:04
-
-
Save magick93/8bc043466f5b2fef8a39761896e8bf28 to your computer and use it in GitHub Desktop.
OpenShift template for Device Information
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
apiVersion: v1 | |
kind: Template | |
metadata: | |
name: ${PROJECT_NAME} | |
objects: | |
- apiVersion: v1 | |
kind: Project | |
metadata: | |
annotations: | |
openshift.io/description: ${PROJECT_DESCRIPTION} | |
openshift.io/display-name: ${PROJECT_DISPLAYNAME} | |
creationTimestamp: null | |
name: ${PROJECT_NAME} | |
spec: {} | |
status: {} | |
- apiVersion: v1 | |
kind: ResourceQuota | |
metadata: | |
name: ${PROJECT_NAME}-quota | |
spec: | |
hard: | |
memory: 1024Mi | |
cpu: 500m | |
pods: 3 | |
resourcequotas: 1 | |
- apiVersion: v1 | |
kind: DeploymentConfig | |
metadata: | |
labels: | |
app: ${PROJECT_NAME} | |
name: ${PROJECT_NAME} | |
spec: | |
replicas: 1 | |
selector: | |
app: ${PROJECT_NAME} | |
deploymentconfig: ${PROJECT_NAME} | |
strategy: | |
activeDeadlineSeconds: 21600 | |
resources: {} | |
rollingParams: | |
intervalSeconds: 1 | |
maxSurge: 25% | |
maxUnavailable: 25% | |
timeoutSeconds: 600 | |
updatePeriodSeconds: 1 | |
type: Rolling | |
template: | |
metadata: | |
annotations: | |
labels: | |
app: ${PROJECT_NAME} | |
deploymentconfig: ${PROJECT_NAME} | |
spec: | |
containers: | |
imagePullPolicy: Always | |
name: ${PROJECT_NAME} | |
ports: | |
- containerPort: 8778 | |
protocol: TCP | |
- containerPort: 9779 | |
protocol: TCP | |
resources: {} | |
terminationMessagePath: /dev/termination-log | |
terminationMessagePolicy: File | |
dnsPolicy: ClusterFirst | |
restartPolicy: Always | |
schedulerName: default-scheduler | |
securityContext: {} | |
terminationGracePeriodSeconds: 30 | |
test: false | |
triggers: | |
- type: ConfigChange | |
- imageChangeParams: | |
automatic: true | |
containerNames: | |
- ${PROJECT_NAME} | |
from: | |
kind: ImageStreamTag | |
name: ${PROJECT_NAME}:latest | |
namespace: section6 | |
type: ImageChange | |
status: | |
availableReplicas: 0 | |
latestVersion: 0 | |
observedGeneration: 0 | |
replicas: 0 | |
unavailableReplicas: 0 | |
updatedReplicas: 0 | |
- apiVersion: v1 | |
kind: Service | |
metadata: | |
labels: | |
app: ${PROJECT_NAME} | |
name: ${PROJECT_NAME} | |
spec: | |
ports: | |
- name: 8778-tcp | |
port: 8778 | |
protocol: TCP | |
targetPort: 8778 | |
- name: 9779-tcp | |
port: 9779 | |
protocol: TCP | |
targetPort: 9779 | |
selector: | |
app: ${PROJECT_NAME} | |
deploymentconfig: ${PROJECT_NAME} | |
sessionAffinity: None | |
type: ClusterIP | |
status: | |
loadBalancer: {} | |
- apiVersion: v1 | |
kind: BuildConfig | |
metadata: | |
labels: | |
app: ${PROJECT_NAME} | |
name: ${PROJECT_NAME} | |
spec: | |
failedBuildsHistoryLimit: 5 | |
nodeSelector: null | |
output: | |
to: | |
kind: ImageStreamTag | |
name: ${PROJECT_NAME}:latest | |
postCommit: {} | |
resources: {} | |
runPolicy: Serial | |
source: | |
git: | |
uri: ${SOURCE_REPOSITORY_URL} | |
type: Git | |
strategy: | |
sourceStrategy: | |
from: | |
kind: ImageStreamTag | |
name: s2i-karaf:2.2.0 | |
type: Source | |
successfulBuildsHistoryLimit: 5 | |
triggers: | |
- github: | |
secret: ${GITHUB_TRIGGER_SECRET} | |
type: GitHub | |
- generic: | |
secret: ${GENERIC_TRIGGER_SECRET} | |
type: Generic | |
- type: ConfigChange | |
- imageChange: {} | |
type: ImageChange | |
parameters: | |
- description: The name for the application. | |
name: PROJECT_NAME | |
required: true | |
- description: Git source URI for application | |
name: SOURCE_REPOSITORY_URL | |
required: true | |
value: https://github.com/hughestech/DeviceInformation.git | |
- description: Git branch/tag reference | |
name: SOURCE_REF | |
value: master |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment