1 Star 0 Fork 0

maxidea / k8s-testing-files

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
wordpress.yaml 1.51 KB
一键复制 编辑 原始数据 按行查看 历史
maxidea 提交于 2020-06-03 01:26 . update wordpress testing file
apiVersion: v1
kind: ConfigMap
metadata:
name: fpm-conf
namespace: default
data:
www.conf: |
[www]
user = www-data
group = www-data
listen = 127.0.0.1:9000
pm = dynamic
pm.max_children = 5
pm.start_servers = 2
pm.min_spare_servers = 1
pm.max_spare_servers = 3
---
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: wordpress
name: wordpress
spec:
replicas: 1
selector:
matchLabels:
app: wordpress
template:
metadata:
labels:
app: wordpress
spec:
nodeSelector:
nodetype: wordpress
containers:
- image: wordpress:5-php7.2-fpm
name: wordpress
volumeMounts:
- name: fpmconfs
mountPath: /usr/local/etc/php-fpm.d/
readOnly: true
- name: wwwdata
mountPath: /var/www/html
env:
- name: WORDPRESS_DB_NAME
value: wpdb
- name: WORDPRESS_DB_USER
value: wpuser
- name: WORDPRESS_DB_PASSWORD
value: wppass
- name: WORDPRESS_DB_HOST
value: "wpdb.default.svc.cluster.local."
volumes:
- name: fpmconfs
configMap:
name: fpm-conf
optional: false
- name: wwwdata
hostPath:
path: /data/wwwdata
---
apiVersion: v1
kind: Service
metadata:
labels:
app: wordpress
name: wordpress
namespace: default
spec:
ports:
- name: "9000"
port: 9000
protocol: TCP
targetPort: 9000
selector:
app: wordpress
type: ClusterIP
1
https://gitee.com/maxidea/k8s-testing-files.git
git@gitee.com:maxidea/k8s-testing-files.git
maxidea
k8s-testing-files
k8s-testing-files
master

搜索帮助