mirror of
https://github.com/bvanroll/cicdTest.git
synced 2025-08-29 12:02:47 +00:00
hel
This commit is contained in:
@@ -29,8 +29,10 @@ https://developer.ibm.com/tutorials/deploy-a-hello-world-application-on-kubernet
|
||||
|
||||
https://github.com/tektoncd/pipeline/blob/master/docs/tutorial.md
|
||||
|
||||
https://github.com/tektoncd/pipeline/blob/master/docs/install.md
|
||||
|
||||
install tekton
|
||||
|
||||
kubectl apply --filename https://storage.googleapis.com/tekton-releases/latest/release.yaml
|
||||
|
||||
|
||||
docker config is een configmap gemaakt van config.json wa base64 username:pass inhoud heeft erges
|
||||
|
21
hello/Chart.yaml
Normal file
21
hello/Chart.yaml
Normal file
@@ -0,0 +1,21 @@
|
||||
apiVersion: v2
|
||||
name: hello
|
||||
description: A Helm chart for Kubernetes
|
||||
|
||||
# A chart can be either an 'application' or a 'library' chart.
|
||||
#
|
||||
# Application charts are a collection of templates that can be packaged into versioned archives
|
||||
# to be deployed.
|
||||
#
|
||||
# Library charts provide useful utilities or functions for the chart developer. They're included as
|
||||
# a dependency of application charts to inject those utilities and functions into the rendering
|
||||
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
|
||||
type: application
|
||||
|
||||
# This is the chart version. This version number should be incremented each time you make changes
|
||||
# to the chart and its templates, including the app version.
|
||||
version: 0.1.0
|
||||
|
||||
# This is the version number of the application being deployed. This version number should be
|
||||
# incremented each time you make changes to the application.
|
||||
appVersion: 1.16.0
|
14
hello/templates/pod-server-a.yaml
Normal file
14
hello/templates/pod-server-a.yaml
Normal file
@@ -0,0 +1,14 @@
|
||||
apiVersion: v1
|
||||
kind: Pod
|
||||
metadata:
|
||||
name: server-a
|
||||
labels:
|
||||
server: "http"
|
||||
expose: "true"
|
||||
spec:
|
||||
containers:
|
||||
- name: front-end
|
||||
image: IMAGE-A
|
||||
ports:
|
||||
- containerPort: 5000
|
||||
|
12
hello/templates/pod-server-b.yaml
Normal file
12
hello/templates/pod-server-b.yaml
Normal file
@@ -0,0 +1,12 @@
|
||||
apiVersion: v1
|
||||
kind: Pod
|
||||
metadata:
|
||||
name: server-b
|
||||
labels:
|
||||
server: "http"
|
||||
spec:
|
||||
containers:
|
||||
- name: front-end
|
||||
image: IMAGE-B
|
||||
ports:
|
||||
- containerPort: 5000
|
14
hello/templates/service-expose.yaml
Normal file
14
hello/templates/service-expose.yaml
Normal file
@@ -0,0 +1,14 @@
|
||||
kind: Service
|
||||
apiVersion: v1
|
||||
metadata:
|
||||
name: expose-server
|
||||
spec:
|
||||
type: NodePort
|
||||
selector:
|
||||
expose: "true"
|
||||
ports:
|
||||
- name: http
|
||||
protocol: TCP
|
||||
targetPort: 5000
|
||||
port: 5000
|
||||
nodePort: 30036
|
11
hello/templates/service.yaml
Normal file
11
hello/templates/service.yaml
Normal file
@@ -0,0 +1,11 @@
|
||||
kind: Service
|
||||
apiVersion: v1
|
||||
metadata:
|
||||
name: server-check
|
||||
spec:
|
||||
selector:
|
||||
server: "http"
|
||||
ports:
|
||||
- name: http
|
||||
protocol: TCP
|
||||
port: 5000
|
68
hello/values.yaml
Normal file
68
hello/values.yaml
Normal file
@@ -0,0 +1,68 @@
|
||||
# Default values for hello.
|
||||
# This is a YAML-formatted file.
|
||||
# Declare variables to be passed into your templates.
|
||||
|
||||
replicaCount: 1
|
||||
|
||||
image:
|
||||
repository: nginx
|
||||
pullPolicy: IfNotPresent
|
||||
|
||||
imagePullSecrets: []
|
||||
nameOverride: ""
|
||||
fullnameOverride: ""
|
||||
|
||||
serviceAccount:
|
||||
# Specifies whether a service account should be created
|
||||
create: true
|
||||
# Annotations to add to the service account
|
||||
annotations: {}
|
||||
# The name of the service account to use.
|
||||
# If not set and create is true, a name is generated using the fullname template
|
||||
name:
|
||||
|
||||
podSecurityContext: {}
|
||||
# fsGroup: 2000
|
||||
|
||||
securityContext: {}
|
||||
# capabilities:
|
||||
# drop:
|
||||
# - ALL
|
||||
# readOnlyRootFilesystem: true
|
||||
# runAsNonRoot: true
|
||||
# runAsUser: 1000
|
||||
|
||||
service:
|
||||
type: ClusterIP
|
||||
port: 80
|
||||
|
||||
ingress:
|
||||
enabled: false
|
||||
annotations: {}
|
||||
# kubernetes.io/ingress.class: nginx
|
||||
# kubernetes.io/tls-acme: "true"
|
||||
hosts:
|
||||
- host: chart-example.local
|
||||
paths: []
|
||||
tls: []
|
||||
# - secretName: chart-example-tls
|
||||
# hosts:
|
||||
# - chart-example.local
|
||||
|
||||
resources: {}
|
||||
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||
# choice for the user. This also increases chances charts run on environments with little
|
||||
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||
# limits:
|
||||
# cpu: 100m
|
||||
# memory: 128Mi
|
||||
# requests:
|
||||
# cpu: 100m
|
||||
# memory: 128Mi
|
||||
|
||||
nodeSelector: {}
|
||||
|
||||
tolerations: []
|
||||
|
||||
affinity: {}
|
@@ -16,14 +16,15 @@ spec:
|
||||
- name: pathToContext
|
||||
value: "."
|
||||
- name: imageUrl-a
|
||||
value: "beppeserver-a"
|
||||
value: "gs://BUCKETNAME/server-a"
|
||||
- name: imageTag-a
|
||||
value: "beppeserver-a-tag"
|
||||
value: "release"
|
||||
- name: pathToContext-a
|
||||
value: "./serverA"
|
||||
- name: imageUrl-b
|
||||
value: "beppeserver-b"
|
||||
value: "gs://BUCKETNAME/server-b"
|
||||
- name: imageTag-b
|
||||
value: "beppeserver-b-tag"
|
||||
value: "release"
|
||||
- name: pathToContext-b
|
||||
value: "./serverB"
|
||||
|
||||
|
@@ -9,4 +9,4 @@ spec:
|
||||
- name: revision
|
||||
value: master
|
||||
- name: url
|
||||
value: https://github.com/beppevanrolleghem/cicdTest
|
||||
value: git://github.com/beppevanrolleghem/cicdTest
|
@@ -28,3 +28,6 @@ spec:
|
||||
- "--dockerfile=dockerfile"
|
||||
- "--destination=$(inputs.params.imageUrl):$(inputs.params.imageTag)"
|
||||
- "--context=$(inputs.resources.git-source.path)/$(inputs.params.pathToContext)/"
|
||||
volumeMounts:
|
||||
- name: docker-config
|
||||
mountPath: /kaniko/.docker/
|
||||
|
Reference in New Issue
Block a user