l-24 run done

master
dongming 2 years ago
parent 06ca216264
commit 278038a38b

@ -1,12 +0,0 @@
apiVersion: apps.mashibing.com/v1
kind: MsbDeployment
metadata:
labels:
app.kubernetes.io/name: msbdeployment
app.kubernetes.io/instance: msbdeployment-sample
app.kubernetes.io/part-of: mashibing-deployment
app.kuberentes.io/managed-by: kustomize
app.kubernetes.io/created-by: mashibing-deployment
name: msbdeployment-sample
spec:
# TODO(user): Add fields here

@ -0,0 +1,11 @@
apiVersion: apps.mashibing.com/v1
kind: MsbDeployment
metadata:
name: msbdeployment-ingress
spec:
image: nginx
port: 80
replicas: 2
expose:
mode: ingress
ingressDomain: www.mashingbing-test.com

@ -0,0 +1,11 @@
apiVersion: apps.mashibing.com/v1
kind: MsbDeployment
metadata:
name: msbdeployment-ingress
spec:
image: nginx
port: 80
replicas: 2
expose:
mode: nodeport
nodePort: 30000

@ -0,0 +1,11 @@
apiVersion: apps.mashibing.com/v1
kind: MsbDeployment
metadata:
name: msbdeployment-nodeport
spec:
image: nginx
port: 80
replicas: 2
expose:
mode: nodeport
nodePort: 30000

@ -0,0 +1,11 @@
apiVersion: apps.mashibing.com/v1
kind: MsbDeployment
metadata:
name: msbdeployment-nodeport
spec:
image: nginx
port: 80
replicas: 2
expose:
mode: ingress
ingressDomain: www.mashingbing-test.com

@ -14,7 +14,7 @@ import (
)
func parseTemplate(md *myAppsv1.MsbDeployment, templateName string) ([]byte, error) {
tmpl, err := template.ParseFiles(fmt.Sprintf("templates/%s", templateName))
tmpl, err := template.ParseFiles(fmt.Sprintf("controllers/templates/%s", templateName))
if err != nil {
return nil, err
}

@ -2,6 +2,7 @@ apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ .ObjectMeta.Name }}
namespace: {{ .ObjectMeta.Namespace }}
labels:
app: {{ .ObjectMeta.Name }}
spec:

@ -2,6 +2,7 @@ apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: {{ .ObjectMeta.Name }}
namespace: {{ .ObjectMeta.Namespace }}
spec:
ingressClassName: nginx
rules:

@ -2,6 +2,7 @@ apiVersion: v1
kind: Service
metadata:
name: {{ .ObjectMeta.Name }}
namespace: {{ .ObjectMeta.Namespace }}
spec:
type: NodePort
selector:

@ -2,6 +2,7 @@ apiVersion: v1
kind: Service
metadata:
name: {{ .ObjectMeta.Name }}
namespace: {{ .ObjectMeta.Namespace }}
spec:
selector:
app: {{ .ObjectMeta.Name }}

Loading…
Cancel
Save