加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
k8s.yaml 1.95 KB
一键复制 编辑 原始数据 按行查看 历史
###################################################
# 工作流引擎 workflow
##################################################
apiVersion: v1
kind: Service
metadata:
name: workflow
spec:
selector:
app: workflow
ports:
- port: 8080
name: http
---
# deployment
apiVersion: apps/v1
kind: Deployment
metadata:
name: workflow
spec:
replicas: 2
selector:
matchLabels:
app: workflow
template:
metadata:
labels:
app: workflow
spec:
containers:
- name: workflow
imagePullPolicy: Always
image: registry.cn-hangzhou.aliyuncs.com/mumushuiding/go-workflow
resources:
limits:
memory: "128Mi"
cpu: "500m"
ports:
- containerPort: 8080
env:
- name: DbType
value: "mysql"
- name: DbLogMode
value: "false"
- name: DbName
value: workflow
- name: DbHost
value: localhost
- name: DbUser
value: root
- name: DbPassword
value: ""
- name: RedisCluster # 是否是redis集群
value: "true"
- name: RedisHost
value: redis-service # redis 集群ip
- name: RedisPort
value: "6379"
- name: RedisPassword
value: ""
---
apiVersion: networking.istio.io/v1alpha3
kind: Gateway
metadata:
name: workflow
spec:
selector:
istio: ingressgateway
servers:
- port:
number: 80
name: http
protocol: http
hosts:
- workflow.prod.svc.cluster.local
---
apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: workflow
spec:
hosts:
- "*"
gateways:
- workflow
http:
- match:
- uri:
prefix: /workflow
route:
- destination:
host: workflow
port:
number: 8080
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化