forked from kubernetes-sigs/kustomize
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
178 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
apiVersion: apps/v1beta2 # for versions before 1.9.0 use apps/v1beta2 | ||
kind: Deployment | ||
metadata: | ||
name: mysql | ||
labels: | ||
app: mysql | ||
spec: | ||
selector: | ||
matchLabels: | ||
app: mysql | ||
strategy: | ||
type: Recreate | ||
template: | ||
metadata: | ||
labels: | ||
app: mysql | ||
spec: | ||
containers: | ||
- image: mysql:5.6 | ||
name: mysql | ||
env: | ||
- name: MYSQL_ROOT_PASSWORD | ||
valueFrom: | ||
secretKeyRef: | ||
name: mysql-pass | ||
key: password | ||
ports: | ||
- containerPort: 3306 | ||
name: mysql | ||
volumeMounts: | ||
- name: mysql-persistent-storage | ||
mountPath: /var/lib/mysql | ||
volumes: | ||
- name: mysql-persistent-storage | ||
emptyDir: {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
apiVersion: v1 | ||
kind: Secret | ||
metadata: | ||
creationTimestamp: null | ||
name: mysql-pass-d2gtcm2t2k | ||
type: Opaque | ||
data: | ||
# Default password is "admin". | ||
password: YWRtaW4= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
name: mysql | ||
labels: | ||
app: mysql | ||
spec: | ||
ports: | ||
- port: 3306 | ||
selector: | ||
app: mysql |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
apiVersion: apps/v1beta2 | ||
kind: Deployment | ||
metadata: | ||
name: sbdemo | ||
labels: | ||
app: sbdemo | ||
spec: | ||
selector: | ||
matchLabels: | ||
app: sbdemo | ||
template: | ||
metadata: | ||
labels: | ||
app: sbdemo | ||
spec: | ||
containers: | ||
- name: sbdemo | ||
image: jingfang/sbdemo | ||
ports: | ||
- containerPort: 8080 | ||
volumeMounts: | ||
- name: demo-config | ||
mountPath: /config | ||
volumes: | ||
- name: "demo-config" | ||
configMap: | ||
name: "demo-configmap" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
name: sbdemo | ||
labels: | ||
app: sbdemo | ||
spec: | ||
ports: | ||
- port: 8080 | ||
selector: | ||
app: sbdemo | ||
type: LoadBalancer |
5 changes: 5 additions & 0 deletions
5
demos/data/springboot/overlays/production/application.properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
app.name=Staging Kinflate Demo | ||
spring.jpa.hibernate.ddl-auto=update | ||
spring.datasource.url=jdbc:mysql://<production_db_ip>:3306/db_example | ||
spring.datasource.username=root | ||
spring.datasource.password=admin |
22 changes: 22 additions & 0 deletions
22
demos/data/springboot/overlays/production/healthcheck_patch.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
apiVersion: apps/v1beta2 | ||
kind: Deployment | ||
metadata: | ||
name: sbdemo | ||
spec: | ||
replicas: 2 | ||
template: | ||
spec: | ||
containers: | ||
- name: sbdemo | ||
livenessProbe: | ||
httpGet: | ||
path: /actuator/health | ||
port: 8080 | ||
initialDelaySeconds: 10 | ||
periodSeconds: 3 | ||
readinessProbe: | ||
initialDelaySeconds: 20 | ||
periodSeconds: 10 | ||
httpGet: | ||
path: /actuator/info | ||
port: 8080 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
bases: | ||
- ../../base | ||
patches: | ||
- patch.yaml | ||
- healthcheck_patch.yaml | ||
- memorylimit_patch.yaml | ||
namePrefix: production- |
20 changes: 20 additions & 0 deletions
20
demos/data/springboot/overlays/production/memorylimit_patch.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
apiVersion: apps/v1beta2 | ||
kind: Deployment | ||
metadata: | ||
name: sbdemo | ||
spec: | ||
replicas: 2 | ||
template: | ||
spec: | ||
containers: | ||
- name: sbdemo | ||
resources: | ||
limits: | ||
memory: 1250Mi | ||
requests: | ||
memory: 1250Mi | ||
env: | ||
- name: MEM_TOTAL_MB | ||
valueFrom: | ||
resourceFieldRef: | ||
resource: limits.memory |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: demo-configmap | ||
data: | ||
application.properties: | | ||
app.name=Staging Kinflate Demo | ||
spring.jpa.hibernate.ddl-auto=update | ||
spring.datasource.url=jdbc:mysql://<production_db_ip>:3306/db_example | ||
spring.datasource.username=root | ||
spring.datasource.password=admin | ||
server.tomcat.max-threads=20 | ||
server.tomcat.min-spare-threads=3 |
5 changes: 5 additions & 0 deletions
5
demos/data/springboot/overlays/staging/application.properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
app.name=Staging Kinflate Demo | ||
spring.jpa.hibernate.ddl-auto=update | ||
spring.datasource.url=jdbc:mysql://<staging_db_ip>:3306/db_example | ||
spring.datasource.username=root | ||
spring.datasource.password=admin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
bases: | ||
- ../../base | ||
namePrefix: staging- | ||
configMapGenerator: | ||
- name: demo-configmap | ||
behavior: merge | ||
files: | ||
- application.properties | ||
literals: | ||
- foo=bar | ||
env: staging.env |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
staging |