Updated the template and pipeline files
This commit is contained in:
parent
97b36345db
commit
7c0fe62475
@ -1,5 +1,8 @@
|
||||
variables:
|
||||
ProjectName: Catalog.API
|
||||
OpenShiftProject: development
|
||||
AppName: catalogapi
|
||||
OpenShiftServiceConnection: 'OpenShift on ARO'
|
||||
trigger:
|
||||
branches:
|
||||
include:
|
||||
|
@ -1,5 +1,8 @@
|
||||
variables:
|
||||
ProjectName: Identity.API
|
||||
OpenShiftProject: development
|
||||
AppName: identityapi
|
||||
OpenShiftServiceConnection: 'OpenShift on ARO'
|
||||
trigger:
|
||||
branches:
|
||||
include:
|
||||
|
@ -1,5 +1,5 @@
|
||||
# ARO build definitions
|
||||
# OpenShift on ARO build definitions
|
||||
|
||||
This folder contains the Azure DevOps build definitions in YAML format. Each folder contains one `azure-pipelines.yml` that contains the build definition for one microservice (usually a Docker image, but some microservices generates more than one Docker image).
|
||||
This folder contains the Azure DevOps build definitions in YAML format targeting container builds in OpenShift on ARO. Each folder contains one `azure-pipelines.yml` that contains the build definition for one microservice. The container images are built inside of the OpenShift cluster from the latest release of the RHEL .NET Core base image.
|
||||
|
||||
For more information about YAML builds read the [Azure DevOps documentation](https://docs.microsoft.com/azure/devops/pipelines/get-started-yaml?view=azure-devops).
|
79
deploy/api-app-template.yml
Normal file
79
deploy/api-app-template.yml
Normal file
@ -0,0 +1,79 @@
|
||||
apiVersion: template.openshift.io/v1
|
||||
kind: Template
|
||||
metadata:
|
||||
name: 'api-template'
|
||||
objects:
|
||||
- apiVersion: apps.openshift.io/v1
|
||||
kind: DeploymentConfig
|
||||
metadata:
|
||||
labels:
|
||||
app: ${APPLICATION_NAME}
|
||||
name: ${APPLICATION_NAME}
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
app: ${APPLICATION_NAME}
|
||||
deploymentconfig: ${APPLICATION_NAME}
|
||||
strategy:
|
||||
type: Rolling
|
||||
revisionHistoryLimit: 2
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: ${APPLICATION_NAME}
|
||||
deploymentconfig: ${APPLICATION_NAME}
|
||||
spec:
|
||||
containers:
|
||||
- image: docker-registry.default.svc:5000/development${IMAGE_REGISTRY_PROJECT_NAME}/${APPLICATION_NAME}:latest
|
||||
imagePullPolicy: Always
|
||||
name: ${APPLICATION_NAME}
|
||||
ports:
|
||||
- containerPort: 8080
|
||||
protocol: TCP
|
||||
resources: {}
|
||||
terminationMessagePath: /dev/termination-log
|
||||
terminationMessagePolicy: File
|
||||
dnsPolicy: ClusterFirst
|
||||
restartPolicy: Always
|
||||
schedulerName: default-scheduler
|
||||
securityContext: {}
|
||||
terminationGracePeriodSeconds: 30
|
||||
triggers:
|
||||
- type: ConfigChange
|
||||
- imageChangeParams:
|
||||
automatic: true
|
||||
containerNames:
|
||||
- ${APPLICATION_NAME}
|
||||
from:
|
||||
kind: ImageStreamTag
|
||||
name: ${APPLICATION_NAME}:latest
|
||||
namespace: development
|
||||
type: ImageChange
|
||||
- apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
labels:
|
||||
app: ${APPLICATION_NAME}
|
||||
name: ${APPLICATION_NAME}
|
||||
spec:
|
||||
ports:
|
||||
- name: 8080-tcp
|
||||
port: 8080
|
||||
protocol: TCP
|
||||
targetPort: 8080
|
||||
selector:
|
||||
app: ${APPLICATION_NAME}
|
||||
deploymentconfig: ${APPLICATION_NAME}
|
||||
sessionAffinity: None
|
||||
type: ClusterIP
|
||||
status:
|
||||
loadBalancer: {}
|
||||
parameters:
|
||||
- description: The name for the application.
|
||||
displayName: Application Name
|
||||
name: APPLICATION_NAME
|
||||
required: true
|
||||
- description: The OpenShift project name that is hosting the image registry.
|
||||
displayName: Image Registry Project Name
|
||||
name: IMAGE_REGISTRY_PROJECT_NAME
|
||||
required: true
|
@ -1,118 +0,0 @@
|
||||
apiVersion: template.openshift.io/v1
|
||||
kind: Template
|
||||
metadata:
|
||||
creationTimestamp: null
|
||||
name: '''basketapi-template'''
|
||||
objects:
|
||||
- apiVersion: apps.openshift.io/v1
|
||||
kind: DeploymentConfig
|
||||
metadata:
|
||||
annotations:
|
||||
openshift.io/generated-by: OpenShiftNewApp
|
||||
creationTimestamp: null
|
||||
generation: 6
|
||||
labels:
|
||||
app: basketapi
|
||||
name: basketapi
|
||||
spec:
|
||||
replicas: 1
|
||||
revisionHistoryLimit: 10
|
||||
selector:
|
||||
app: basketapi
|
||||
deploymentconfig: basketapi
|
||||
strategy:
|
||||
activeDeadlineSeconds: 21600
|
||||
resources: {}
|
||||
rollingParams:
|
||||
intervalSeconds: 1
|
||||
maxSurge: 25%
|
||||
maxUnavailable: 25%
|
||||
timeoutSeconds: 600
|
||||
updatePeriodSeconds: 1
|
||||
type: Rolling
|
||||
template:
|
||||
metadata:
|
||||
annotations:
|
||||
openshift.io/generated-by: OpenShiftNewApp
|
||||
creationTimestamp: null
|
||||
labels:
|
||||
app: basketapi
|
||||
deploymentconfig: basketapi
|
||||
spec:
|
||||
containers:
|
||||
- image: docker-registry.default.svc:5000/development/basketapi-build@sha256:7149637592a2e9bbfa78836762a5c300f6b19220ca001902e4c6c1767cb19c3d
|
||||
imagePullPolicy: Always
|
||||
livenessProbe:
|
||||
failureThreshold: 3
|
||||
httpGet:
|
||||
path: /liveness
|
||||
port: 8080
|
||||
scheme: HTTP
|
||||
initialDelaySeconds: 10
|
||||
periodSeconds: 10
|
||||
successThreshold: 1
|
||||
timeoutSeconds: 3
|
||||
name: basketapi
|
||||
ports:
|
||||
- containerPort: 8080
|
||||
protocol: TCP
|
||||
readinessProbe:
|
||||
failureThreshold: 3
|
||||
httpGet:
|
||||
path: /hc
|
||||
port: 8080
|
||||
scheme: HTTP
|
||||
initialDelaySeconds: 10
|
||||
periodSeconds: 10
|
||||
successThreshold: 1
|
||||
timeoutSeconds: 10
|
||||
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:
|
||||
- basketapi
|
||||
from:
|
||||
kind: ImageStreamTag
|
||||
name: basketapi-build:latest
|
||||
namespace: development
|
||||
lastTriggeredImage: docker-registry.default.svc:5000/development/basketapi-build@sha256:7149637592a2e9bbfa78836762a5c300f6b19220ca001902e4c6c1767cb19c3d
|
||||
type: ImageChange
|
||||
status:
|
||||
availableReplicas: 0
|
||||
latestVersion: 0
|
||||
observedGeneration: 0
|
||||
replicas: 0
|
||||
unavailableReplicas: 0
|
||||
updatedReplicas: 0
|
||||
- apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
annotations:
|
||||
openshift.io/generated-by: OpenShiftNewApp
|
||||
creationTimestamp: null
|
||||
labels:
|
||||
app: basketapi
|
||||
name: basketapi
|
||||
spec:
|
||||
ports:
|
||||
- name: 8080-tcp
|
||||
port: 8080
|
||||
protocol: TCP
|
||||
targetPort: 8080
|
||||
selector:
|
||||
app: basketapi
|
||||
deploymentconfig: basketapi
|
||||
sessionAffinity: None
|
||||
type: ClusterIP
|
||||
status:
|
||||
loadBalancer: {}
|
Loading…
x
Reference in New Issue
Block a user