Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Code Block
    themeMidnight
    titledeploy/k8s-deploy.yml
    linenumberstrue
    ---
    apiVersion: apps/v1
    kind: Deployment
    metadata:
      name: redis
    spec:
      selector:
        matchLabels:
          app: redis
      replicas: 1
      template:
        metadata:
          labels:
            app: redis
        spec:
          containers:
          - name: redis
            image: redis
            ports:
            - containerPort: 6379
    ---
    apiVersion: apps/v1
    kind: Deployment 
    metadata: 
      name: reactorwebflux-demo 
    spec: 
      selector: 
        matchLabels: 
          app: reactorwebflux-demo 
      replicas: 3
      template:
        metadata: 
          labels: 
            app: reactorwebflux-demo 
        spec: 
          containers: 
          - name: reactor-demo 
            image: sooabia/reactorwebflux-demo:1.0
            ports: 
            - containerPort: 8080
    ---  
    kind: Service 
    apiVersion: v1 
    metadata: 
      name: spring-service 
    spec: 
      selector: 
        app: reactorwebflux-demo 
      ports: 
      - protocol: TCP 
        port: 80 
        targetPort: 8080
      type: LoadBalancer