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.
40 lines
718 B
40 lines
718 B
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: ruoyi-java
|
|
spec:
|
|
replicas: 2
|
|
selector:
|
|
matchLabels:
|
|
app: ruoyi-java
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: ruoyi-java
|
|
spec:
|
|
containers:
|
|
- name: ruoyi-java
|
|
image: 192.168.75.181/library/java:v1.0
|
|
imagePullPolicy: Always
|
|
ports:
|
|
- containerPort: 8080
|
|
hostAliases:
|
|
- ip: "192.168.96.160"
|
|
hostnames:
|
|
- "mysql.server"
|
|
- ip: "192.168.96.141"
|
|
hostnames:
|
|
- "redis.server"
|
|
|
|
---
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: ruoyi-java-service
|
|
spec:
|
|
selector:
|
|
app: ruoyi-java
|
|
ports:
|
|
- port: 8080
|
|
targetPort: 8080
|
|
|