| @ -1,28 +0,0 @@ | |||||
| apiVersion: build.openshift.io/v1 | |||||
| kind: BuildConfig | |||||
| metadata: | |||||
| name: nginx-hello-world | |||||
| spec: | |||||
| runPolicy: Serial | |||||
| triggers: | |||||
| - type: "ImageChange" | |||||
| imageChange: {} | |||||
| source: | |||||
| dockerfile: | | |||||
| FROM ubuntu:latest | |||||
| RUN apt update && \ | |||||
| apt install -y nginx | |||||
| COPY index.html /usr/share/nginx/html | |||||
| COPY nginx.conf /etc/nginx/nginx.conf | |||||
| CMD /usr/sbin/nginx -g 'daemon off;' | |||||
| strategy: | |||||
| type: Docker | |||||
| dockerStrategy: | |||||
| noCache: false | |||||
| output: | |||||
| to: | |||||
| kind: ImageStreamTag | |||||
| name: "nginx-hello-world:latest" | |||||
| @ -1,6 +0,0 @@ | |||||
| oc create -f buildconfig.yaml | |||||
| oc create imagestream nginx-hello-world | |||||
| oc start-build nginx-hello-world --from-dir=./ --follow | |||||
| oc create -f deployment2.yaml | |||||
| oc create -f service.yaml | |||||
| oc create -f route.yaml | |||||
| @ -1,25 +0,0 @@ | |||||
| apiVersion: apps/v1 | |||||
| kind: Deployment | |||||
| metadata: | |||||
| name: nginx-hello-world | |||||
| labels: | |||||
| app: nginx-hello-world | |||||
| spec: | |||||
| replicas: 3 | |||||
| selector: | |||||
| matchLabels: | |||||
| app: nginx-hello-world | |||||
| template: | |||||
| metadata: | |||||
| labels: | |||||
| app: nginx-hello-world | |||||
| spec: | |||||
| containers: | |||||
| - name: nginx | |||||
| image: "image-registry.openshift-image-registry.svc:5000/miproyecto/nginx-hello-world" | |||||
| terminationMessagePath: /dev/termination-log | |||||
| terminationMessagePolicy: File | |||||
| tty: true | |||||
| stdin: true | |||||
| serviceAccount: default | |||||
| terminationGracePeriodSeconds: 5 | |||||
| @ -1,31 +0,0 @@ | |||||
| apiVersion: apps/v1 | |||||
| kind: Deployment | |||||
| metadata: | |||||
| name: nginx-hello-world | |||||
| labels: | |||||
| app: nginx-hello-world | |||||
| spec: | |||||
| replicas: 1 | |||||
| selector: | |||||
| matchLabels: | |||||
| app: nginx-hello-world | |||||
| template: | |||||
| metadata: | |||||
| labels: | |||||
| app: nginx-hello-world | |||||
| spec: | |||||
| containers: | |||||
| - name: nginx-hello-world | |||||
| image: "image-registry.openshift-image-registry.svc:5000/miproyecto/nginx-hello-world" | |||||
| terminationMessagePath: /dev/termination-log | |||||
| terminationMessagePolicy: File | |||||
| tty: true | |||||
| stdin: true | |||||
| serviceAccount: default | |||||
| volumeMounts: | |||||
| - mountPath: /usr/share/nginx/html | |||||
| name: html-volume | |||||
| volumes: | |||||
| - name: html-volume | |||||
| persistentVolumeClaim: | |||||
| claimName: miproyecto-claim | |||||
| @ -1,5 +0,0 @@ | |||||
| oc delete buildconfig nginx-hello-world | |||||
| oc delete imagestream nginx-hello-world | |||||
| oc delete deployment nginx-hello-world | |||||
| oc delete service nginx-hello-world | |||||
| oc delete route nginx-hello-world | |||||
| @ -1,16 +0,0 @@ | |||||
| apiVersion: route.openshift.io/v1 | |||||
| kind: Route | |||||
| metadata: | |||||
| name: nginx-hello-world | |||||
| spec: | |||||
| # hostname: foo.apps.CLUSTER.ccs.ornl.gov | |||||
| port: | |||||
| targetPort: nginx | |||||
| tls: | |||||
| insecureEdgeTerminationPolicy: Redirect | |||||
| termination: edge | |||||
| to: | |||||
| kind: Service | |||||
| name: nginx-hello-world | |||||
| weight: 100 | |||||
| wildcardPolicy: None | |||||
| @ -1,16 +0,0 @@ | |||||
| apiVersion: v1 | |||||
| kind: Service | |||||
| metadata: | |||||
| labels: | |||||
| app: nginx-hello-world | |||||
| name: nginx-hello-world | |||||
| spec: | |||||
| ports: | |||||
| - name: nginx | |||||
| port: 80 | |||||
| protocol: TCP | |||||
| targetPort: 8080 | |||||
| selector: | |||||
| app: nginx-hello-world | |||||
| sessionAffinity: None | |||||
| type: ClusterIP | |||||