添加 openlist 服务的 Docker Compose 配置和 Kubernetes 部署文件
This commit is contained in:
13
k8s/kevisual.cn/apps/openlist/docker/compose.yml
Normal file
13
k8s/kevisual.cn/apps/openlist/docker/compose.yml
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
# docker-compose.yml
|
||||||
|
services:
|
||||||
|
openlist:
|
||||||
|
image: 'openlistteam/openlist:latest'
|
||||||
|
container_name: openlist
|
||||||
|
user: '0:0' # Please replace `0:0` with the actual user ID and group ID you want to use to run OpenList.
|
||||||
|
volumes:
|
||||||
|
- './data:/opt/openlist/data'
|
||||||
|
ports:
|
||||||
|
- '5244:5244'
|
||||||
|
environment:
|
||||||
|
- UMASK=022
|
||||||
|
restart: unless-stopped
|
||||||
71
k8s/kevisual.cn/apps/openlist/openlist.yaml
Normal file
71
k8s/kevisual.cn/apps/openlist/openlist.yaml
Normal file
@@ -0,0 +1,71 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: openlist
|
||||||
|
labels:
|
||||||
|
app: openlist
|
||||||
|
spec:
|
||||||
|
replicas: 1
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: openlist
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: openlist
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- name: openlist
|
||||||
|
image: docker.1ms.run/openlistteam/openlist:latest
|
||||||
|
securityContext:
|
||||||
|
runAsUser: 0
|
||||||
|
ports:
|
||||||
|
- containerPort: 5244
|
||||||
|
protocol: TCP
|
||||||
|
env:
|
||||||
|
- name: UMASK
|
||||||
|
value: "022"
|
||||||
|
volumeMounts:
|
||||||
|
- name: openlist-data
|
||||||
|
mountPath: /opt/openlist/data
|
||||||
|
volumes:
|
||||||
|
- name: openlist-data
|
||||||
|
hostPath:
|
||||||
|
path: /opt/docker/openlist/data
|
||||||
|
type: DirectoryOrCreate
|
||||||
|
nodeSelector:
|
||||||
|
machine: "kevisual"
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: openlist
|
||||||
|
labels:
|
||||||
|
app: openlist
|
||||||
|
spec:
|
||||||
|
type: ClusterIP
|
||||||
|
ports:
|
||||||
|
- port: 5244
|
||||||
|
targetPort: 5244
|
||||||
|
protocol: TCP
|
||||||
|
name: http
|
||||||
|
selector:
|
||||||
|
app: openlist
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: traefik.io/v1alpha1
|
||||||
|
kind: IngressRoute
|
||||||
|
metadata:
|
||||||
|
name: openlist-https
|
||||||
|
spec:
|
||||||
|
entryPoints:
|
||||||
|
- websecure
|
||||||
|
routes:
|
||||||
|
- match: Host(`openlist.kevisual.cn`)
|
||||||
|
kind: Rule
|
||||||
|
services:
|
||||||
|
- name: openlist
|
||||||
|
port: 5244
|
||||||
|
tls:
|
||||||
|
certResolver: letsencrypt
|
||||||
6
k8s/kevisual.cn/docs/02-查看启动.md
Normal file
6
k8s/kevisual.cn/docs/02-查看启动.md
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
|
||||||
|
```sh
|
||||||
|
|
||||||
|
kubectl logs openlist-869ffbc74f-kjmbs
|
||||||
|
|
||||||
|
```
|
||||||
Reference in New Issue
Block a user