parent
a9f7b67b0b
commit
337d20d041
@ -1,42 +1,55 @@ |
||||
apiVersion: apps/v1 |
||||
kind: Deployment |
||||
metadata: |
||||
annotations: |
||||
kompose.cmd: C:\ProgramData\chocolatey\lib\kubernetes-kompose\tools\kompose.exe convert |
||||
kompose.version: 1.26.1 (a9d05d509) |
||||
creationTimestamp: null |
||||
labels: |
||||
io.kompose.service: api |
||||
name: api |
||||
spec: |
||||
replicas: 1 |
||||
revisionHistoryLimit: 3 |
||||
selector: |
||||
matchLabels: |
||||
io.kompose.service: api |
||||
strategy: {} |
||||
app: api |
||||
template: |
||||
metadata: |
||||
annotations: |
||||
kompose.cmd: C:\ProgramData\chocolatey\lib\kubernetes-kompose\tools\kompose.exe convert |
||||
kompose.version: 1.26.1 (a9d05d509) |
||||
creationTimestamp: null |
||||
labels: |
||||
io.kompose.service: api |
||||
app: api |
||||
spec: |
||||
containers: |
||||
- env: |
||||
- name: DATABASE_HOSTNAME |
||||
value: db |
||||
- name: DATABASE_NAME |
||||
- name: DATABASE_PASSWORD |
||||
- name: DATABASE_PORT |
||||
value: "3306" |
||||
- name: DATABASE_USERNAME |
||||
- name: api |
||||
image: espacecollabbackendapi |
||||
name: api |
||||
imagePullPolicy: Always |
||||
tty: true |
||||
resources: |
||||
limits: |
||||
memory: "512Mi" |
||||
cpu: "500m" |
||||
ports: |
||||
- containerPort: 80 |
||||
- containerPort: 443 |
||||
resources: {} |
||||
restartPolicy: Always |
||||
status: {} |
||||
env: |
||||
- name: DATABASE_HOSTNAME |
||||
valueFrom: |
||||
configMapKeyRef: |
||||
name: db-config |
||||
key: hostname |
||||
- name: DATABASE_PORT |
||||
valueFrom: |
||||
configMapKeyRef: |
||||
name: db-config |
||||
key: port |
||||
- name: DATABASE_NAME |
||||
valueFrom: |
||||
configMapKeyRef: |
||||
name: db-config |
||||
key: name |
||||
- name: DATABASE_USERNAME |
||||
valueFrom: |
||||
secretKeyRef: |
||||
name: db-secret |
||||
key: username |
||||
- name: DATABASE_PASSWORD |
||||
valueFrom: |
||||
secretKeyRef: |
||||
name: db-secret |
||||
key: password |
||||
|
||||
|
||||
|
@ -0,0 +1,13 @@ |
||||
apiVersion: traefik.containo.us/v1alpha1 |
||||
kind: IngressRoute |
||||
metadata: |
||||
name: api-http |
||||
spec: |
||||
entryPoints: |
||||
- web |
||||
routes: |
||||
- match: Host(`localhost`) && PathPrefix(`/api`) |
||||
kind: Rule |
||||
services: |
||||
- name: back |
||||
port: 80 |
@ -1,22 +1,16 @@ |
||||
apiVersion: v1 |
||||
kind: Service |
||||
metadata: |
||||
annotations: |
||||
kompose.cmd: C:\ProgramData\chocolatey\lib\kubernetes-kompose\tools\kompose.exe convert |
||||
kompose.version: 1.26.1 (a9d05d509) |
||||
creationTimestamp: null |
||||
labels: |
||||
io.kompose.service: api |
||||
name: api |
||||
spec: |
||||
ports: |
||||
- name: "5000" |
||||
- name: api1 |
||||
port: 5000 |
||||
targetPort: 80 |
||||
- name: "5001" |
||||
- name: api2 |
||||
port: 5001 |
||||
targetPort: 443 |
||||
selector: |
||||
io.kompose.service: api |
||||
app: api |
||||
status: |
||||
loadBalancer: {} |
||||
|
@ -1,14 +0,0 @@ |
||||
apiVersion: v1 |
||||
kind: PersistentVolumeClaim |
||||
metadata: |
||||
creationTimestamp: null |
||||
labels: |
||||
io.kompose.service: data-volume |
||||
name: data-volume |
||||
spec: |
||||
accessModes: |
||||
- ReadWriteOnce |
||||
resources: |
||||
requests: |
||||
storage: 100Mi |
||||
status: {} |
@ -0,0 +1,8 @@ |
||||
apiVersion: v1 |
||||
kind: ConfigMap |
||||
metadata: |
||||
name: database-config |
||||
data: |
||||
hostname: db |
||||
port: "3306" |
||||
name: collaborateur_epa |
@ -1,49 +1,56 @@ |
||||
apiVersion: apps/v1 |
||||
kind: Deployment |
||||
metadata: |
||||
annotations: |
||||
kompose.cmd: C:\ProgramData\chocolatey\lib\kubernetes-kompose\tools\kompose.exe convert |
||||
kompose.version: 1.26.1 (a9d05d509) |
||||
creationTimestamp: null |
||||
labels: |
||||
io.kompose.service: db |
||||
name: db |
||||
spec: |
||||
replicas: 1 |
||||
revisionHistoryLimit: 3 |
||||
selector: |
||||
matchLabels: |
||||
io.kompose.service: db |
||||
strategy: |
||||
type: Recreate |
||||
app: db |
||||
template: |
||||
metadata: |
||||
annotations: |
||||
kompose.cmd: C:\ProgramData\chocolatey\lib\kubernetes-kompose\tools\kompose.exe convert |
||||
kompose.version: 1.26.1 (a9d05d509) |
||||
creationTimestamp: null |
||||
labels: |
||||
io.kompose.service: db |
||||
app: db |
||||
spec: |
||||
volumes: |
||||
- name: db |
||||
persistentVolumeClaim: |
||||
claimName: mysql-pv-claim |
||||
containers: |
||||
- env: |
||||
- name: MYSQL_DATABASE |
||||
- name: MYSQL_PASSWORD |
||||
- name: MYSQL_ROOT_PASSWORD |
||||
- name: MYSQL_USERNAME |
||||
- name: db |
||||
image: mariadb:10.7.1 |
||||
name: db |
||||
resources: {} |
||||
imagePullPolicy: Always |
||||
tty: true |
||||
resources: |
||||
limits: |
||||
memory: "512Mi" |
||||
cpu: "500m" |
||||
ports: |
||||
- name: mariadb |
||||
containerPort: 3306 |
||||
volumeMounts: |
||||
- mountPath: /var/lib/mysql |
||||
name: data-volume |
||||
- mountPath: /docker-entrypoint-initdb.d/init.sql |
||||
name: db-claim1 |
||||
restartPolicy: Always |
||||
volumes: |
||||
- name: data-volume |
||||
persistentVolumeClaim: |
||||
claimName: data-volume |
||||
- name: db-claim1 |
||||
persistentVolumeClaim: |
||||
claimName: db-claim1 |
||||
status: {} |
||||
- name: db |
||||
mountPath: /var/lib/mysql |
||||
|
||||
env: |
||||
- name: MYSQL_ROOT_PASSWORD |
||||
valueFrom: |
||||
secretKeyRef: |
||||
name: database-secret |
||||
key: root-password |
||||
- name: MYSQL_DATABASE |
||||
valueFrom: |
||||
configMapKeyRef: |
||||
name: db-config |
||||
key: name |
||||
- name: MYSQL_USER |
||||
valueFrom: |
||||
secretKeyRef: |
||||
name: db-secret |
||||
key: username |
||||
- name: MYSQL_PASSWORD |
||||
valueFrom: |
||||
secretKeyRef: |
||||
name: db-secret |
||||
key: password |
||||
|
@ -0,0 +1,9 @@ |
||||
apiVersion: v1 |
||||
kind: Secret |
||||
metadata: |
||||
name: database-secret |
||||
type: Opaque |
||||
stringData: |
||||
username: epa-dev |
||||
password: dev-epa |
||||
root-password: root |
@ -0,0 +1,14 @@ |
||||
apiVersion: v1 |
||||
kind: Service |
||||
metadata: |
||||
labels: |
||||
app: db |
||||
name: db |
||||
spec: |
||||
ports: |
||||
- name: mariadb |
||||
port: 3307 |
||||
targetPort: 3306 |
||||
selector: |
||||
app: db |
||||
type: ClusterIP |
@ -1,14 +1,12 @@ |
||||
apiVersion: v1 |
||||
kind: PersistentVolumeClaim |
||||
metadata: |
||||
creationTimestamp: null |
||||
name: mysql-pv-claim |
||||
labels: |
||||
io.kompose.service: db-claim1 |
||||
name: db-claim1 |
||||
app: db |
||||
spec: |
||||
accessModes: |
||||
- ReadWriteOnce |
||||
resources: |
||||
requests: |
||||
storage: 100Mi |
||||
status: {} |
||||
storage: 1Gi |
@ -1,33 +1,32 @@ |
||||
apiVersion: apps/v1 |
||||
kind: Deployment |
||||
metadata: |
||||
annotations: |
||||
kompose.cmd: C:\ProgramData\chocolatey\lib\kubernetes-kompose\tools\kompose.exe convert |
||||
kompose.version: 1.26.1 (a9d05d509) |
||||
creationTimestamp: null |
||||
labels: |
||||
io.kompose.service: front |
||||
name: front |
||||
spec: |
||||
replicas: 1 |
||||
revisionHistoryLimit: 3 |
||||
selector: |
||||
matchLabels: |
||||
io.kompose.service: front |
||||
strategy: {} |
||||
app: front |
||||
template: |
||||
metadata: |
||||
annotations: |
||||
kompose.cmd: C:\ProgramData\chocolatey\lib\kubernetes-kompose\tools\kompose.exe convert |
||||
kompose.version: 1.26.1 (a9d05d509) |
||||
creationTimestamp: null |
||||
labels: |
||||
io.kompose.service: front |
||||
app: front |
||||
spec: |
||||
containers: |
||||
- image: collab-front |
||||
name: front |
||||
imagePullPolicy: Always |
||||
tty: true |
||||
resources: |
||||
limits: |
||||
memory: "256Mi" |
||||
cpu: "500m" |
||||
ports: |
||||
- containerPort: 80 |
||||
resources: {} |
||||
restartPolicy: Always |
||||
status: {} |
||||
- name: web |
||||
containerPort: 80 |
||||
env: |
||||
- name: BASE_URL |
||||
value: http://localhost/api/ |
||||
- name: LOGOUT_URL |
||||
value: http://localhost |
||||
|
@ -0,0 +1,13 @@ |
||||
apiVersion: traefik.containo.us/v1alpha1 |
||||
kind: IngressRoute |
||||
metadata: |
||||
name: front-http |
||||
spec: |
||||
entryPoints: |
||||
- web |
||||
routes: |
||||
- match: Host(`localhost`) |
||||
kind: Rule |
||||
services: |
||||
- name: front |
||||
port: 80 |
@ -1,19 +1,12 @@ |
||||
apiVersion: v1 |
||||
kind: Service |
||||
metadata: |
||||
annotations: |
||||
kompose.cmd: C:\ProgramData\chocolatey\lib\kubernetes-kompose\tools\kompose.exe convert |
||||
kompose.version: 1.26.1 (a9d05d509) |
||||
creationTimestamp: null |
||||
labels: |
||||
io.kompose.service: front |
||||
name: front |
||||
spec: |
||||
selector: |
||||
app: front |
||||
ports: |
||||
- name: "8083" |
||||
- name: web |
||||
port: 8083 |
||||
targetPort: 80 |
||||
selector: |
||||
io.kompose.service: front |
||||
status: |
||||
loadBalancer: {} |
||||
type: ClusterIP |
||||
|
Loading…
Reference in new issue