You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
easy-springmvc-maven/tomcat.yaml

34 lines
577 B

apiVersion: apps/v1
kind: Deployment
metadata:
name: tomcat
spec:
selector:
matchLabels:
app: tomcat
template:
metadata:
labels:
app: tomcat
spec:
containers:
- name: tomcat
image: 192.168.96.155/xiaoming/mytomcat:v3.0
ports:
- containerPort: 8080
imagePullSecrets:
- name: login
---
apiVersion: v1
kind: Service
metadata:
name: tomcat
spec:
type: NodePort
selector:
app: tomcat
ports:
- port: 8080
nodePort: 30088
targetPort: 8080