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
# BUILD STAGE: Building the Application | |
FROM node:10 AS build | |
WORKDIR /myapp | |
COPY package.json index.js ./ | |
RUN npm install ./ | |
RUN npm run build | |
# Execution: Final Built Application | |
FROM mhart/alpine-node:10 | |
WORKDIR /myapp |
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
--- | |
apiVersion: apiregistration.k8s.io/v1beta1 | |
kind: APIService | |
metadata: | |
name: v1beta1.metrics.k8s.io | |
spec: | |
service: | |
name: metrics-server | |
namespace: kube-system | |
group: metrics.k8s.io |
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
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: ingress-prometheus | |
namespace: {{NAMESPACE}} | |
spec: | |
ports: | |
- name: ingress-prometheus | |
port: 80 | |
protocol: TCP |
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
global: | |
scrape_interval: 30s | |
scrape_configs: | |
- job_name: ingress | |
honor_timestamps: true | |
scrape_interval: 1m | |
scrape_timeout: 1m | |
metrics_path: /metrics | |
scheme: http |
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
apiVersion: v1 | |
kind: ServiceAccount | |
metadata: | |
name: kube-state-metrics | |
namespace: kube-system | |
--- | |
apiVersion: rbac.authorization.k8s.io/v1 | |
kind: ClusterRole | |
metadata: | |
name: kube-state-metrics |
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
global: | |
scrape_interval: 30s | |
scrape_configs: | |
- job_name: kube-state-metrics | |
honor_timestamps: true | |
scrape_interval: 1m | |
scrape_timeout: 1m | |
metrics_path: /metrics | |
scheme: http |
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
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
name: mysql | |
namespace: mysql | |
labels: | |
app: mysql | |
version: "5.7" | |
spec: | |
replicas: 1 |
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
apiVersion: v1 | |
kind: ConfigMap | |
metadata: | |
name: mysql | |
namespace: mysql | |
labels: | |
app: mysql | |
version: "5.7" | |
data: | |
my.cnf: | |
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
apiVersion: v1 | |
kind: PersistentVolumeClaim | |
metadata: | |
name: mysql-storage | |
namespace: mysql | |
spec: | |
accessModes: | |
- ReadWriteOnce | |
resources: | |
requests: |
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
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: mysql-service | |
namespace: mysql | |
spec: | |
selector: | |
app: mysql | |
version: "5.7" | |
ports: |
OlderNewer