wip
This commit is contained in:
parent
6152586b50
commit
0b62da643d
12
README.md
12
README.md
@ -1,2 +1,12 @@
|
|||||||
# pigallery2-k8s
|
Choix d'utiliser mysql:
|
||||||
|
https://github.com/bpatrik/pigallery2 (SQL database and no-database mode)
|
||||||
|
MySQL: permet plus d'options de recherche
|
||||||
|
|
||||||
|
Mais pour commencer on va utiliser sqlite :)
|
||||||
|
|
||||||
|
Comment reproduire:
|
||||||
|
#wget https://raw.githubusercontent.com/bpatrik/pigallery2/master/docker/docker-compose/with-mysql/docker-compose.yml
|
||||||
|
wget https://raw.githubusercontent.com/bpatrik/pigallery2/master/docker/docker-compose/pigallery2-only/docker-compose.yml
|
||||||
|
kompose convert
|
||||||
|
#rm nginx*
|
||||||
|
+ tuning
|
||||||
|
|||||||
14
db-data-persistentvolumeclaim.yaml
Normal file
14
db-data-persistentvolumeclaim.yaml
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.service: db-data
|
||||||
|
name: db-data
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 100Mi
|
||||||
|
status: {}
|
||||||
18
docker-compose.yml
Normal file
18
docker-compose.yml
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
version: '3'
|
||||||
|
services:
|
||||||
|
pigallery2:
|
||||||
|
image: bpatrik/pigallery2:latest
|
||||||
|
container_name: pigallery2
|
||||||
|
environment:
|
||||||
|
- NODE_ENV=production
|
||||||
|
volumes:
|
||||||
|
- "./pigallery2/config:/app/data/config" # CHANGE ME
|
||||||
|
- "db-data:/app/data/db"
|
||||||
|
- "./pigallery2/images:/app/data/images" # CHANGE ME
|
||||||
|
- "./pigallery2/tmp:/app/data/tmp" # CHANGE ME
|
||||||
|
ports:
|
||||||
|
- 80:80
|
||||||
|
restart: always
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
db-data:
|
||||||
14
pigallery2-claim0-persistentvolumeclaim.yaml
Normal file
14
pigallery2-claim0-persistentvolumeclaim.yaml
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.service: pigallery2-claim0
|
||||||
|
name: pigallery2-claim0
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 100Mi
|
||||||
|
status: {}
|
||||||
14
pigallery2-claim2-persistentvolumeclaim.yaml
Normal file
14
pigallery2-claim2-persistentvolumeclaim.yaml
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.service: pigallery2-claim2
|
||||||
|
name: pigallery2-claim2
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 100Mi
|
||||||
|
status: {}
|
||||||
14
pigallery2-claim3-persistentvolumeclaim.yaml
Normal file
14
pigallery2-claim3-persistentvolumeclaim.yaml
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.service: pigallery2-claim3
|
||||||
|
name: pigallery2-claim3
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 100Mi
|
||||||
|
status: {}
|
||||||
53
pigallery2-deployment.yaml
Normal file
53
pigallery2-deployment.yaml
Normal file
@ -0,0 +1,53 @@
|
|||||||
|
apiVersion: extensions/v1beta1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
annotations:
|
||||||
|
kompose.cmd: kompose convert
|
||||||
|
kompose.version: 1.16.0 (0c01309)
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.service: pigallery2
|
||||||
|
name: pigallery2
|
||||||
|
spec:
|
||||||
|
replicas: 1
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.service: pigallery2
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- env:
|
||||||
|
- name: NODE_ENV
|
||||||
|
value: production
|
||||||
|
image: bpatrik/pigallery2:latest
|
||||||
|
name: pigallery2
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
resources: {}
|
||||||
|
volumeMounts:
|
||||||
|
- mountPath: /app/data/config
|
||||||
|
name: pigallery2-claim0
|
||||||
|
- mountPath: /app/data/db
|
||||||
|
name: db-data
|
||||||
|
- mountPath: /app/data/images
|
||||||
|
name: pigallery2-claim2
|
||||||
|
- mountPath: /app/data/tmp
|
||||||
|
name: pigallery2-claim3
|
||||||
|
restartPolicy: Always
|
||||||
|
volumes:
|
||||||
|
- name: pigallery2-claim0
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: pigallery2-claim0
|
||||||
|
- name: db-data
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: db-data
|
||||||
|
- name: pigallery2-claim2
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: pigallery2-claim2
|
||||||
|
- name: pigallery2-claim3
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: pigallery2-claim3
|
||||||
|
status: {}
|
||||||
19
pigallery2-service.yaml
Normal file
19
pigallery2-service.yaml
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
annotations:
|
||||||
|
kompose.cmd: kompose convert
|
||||||
|
kompose.version: 1.16.0 (0c01309)
|
||||||
|
creationTimestamp: null
|
||||||
|
labels:
|
||||||
|
io.kompose.service: pigallery2
|
||||||
|
name: pigallery2
|
||||||
|
spec:
|
||||||
|
ports:
|
||||||
|
- name: "80"
|
||||||
|
port: 80
|
||||||
|
targetPort: 80
|
||||||
|
selector:
|
||||||
|
io.kompose.service: pigallery2
|
||||||
|
status:
|
||||||
|
loadBalancer: {}
|
||||||
Loading…
x
Reference in New Issue
Block a user