# 我们什么也不改动,直接安装试试
$ helm install firstrelase ./myfirstchart
NAME: firstrelase
LAST DEPLOYED: Mon Feb 10 21:54:01 2020
NAMESPACE: liuzongxian
STATUS: deployed
REVISION: 1
NOTES:
1. Get the application URL by running these commands:
export POD_NAME=$(kubectl get pods --namespace liuzongxian -l "app.kubernetes.io/name=myfirstchart,app.kubernetes.io/instance=firstrelase" -o jsonpath="{.items[0].metadata.name}")
echo "Visit http://127.0.0.1:8080 to use your application"
kubectl --namespace liuzongxian port-forward $POD_NAME 8080:80
$ k get all
NAME READY STATUS RESTARTS AGE
pod/firstrelase-myfirstchart-77577bc9c5-kdksg 1/1 Running 0 47s
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
service/firstrelase-myfirstchart ClusterIP 172.22.7.136 <none> 80/TCP 48s
NAME READY UP-TO-DATE AVAILABLE AGE
deployment.apps/firstrelase-myfirstchart 1/1 1 1 48s
NAME DESIRED CURRENT READY AGE
replicaset.apps/firstrelase-myfirstchart-77577bc9c5 1 1 1 48s
# cat values.yaml
# Default values for myfirstchart.
# This is a YAML-formatted file.
# Declare variables to be passed into your templates.
replicaCount: 1
image:
repository: nginx
pullPolicy: IfNotPresent
imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""
serviceAccount:
# Specifies whether a service account should be created
create: true
# The name of the service account to use.
# If not set and create is true, a name is generated using the fullname template
name:
podSecurityContext: {}
# fsGroup: 2000
securityContext: {}
# capabilities:
# drop:
# - ALL
# readOnlyRootFilesystem: true
# runAsNonRoot: true
# runAsUser: 1000
service:
type: ClusterIP
port: 80
ingress:
enabled: false
annotations: {}
# kubernetes.io/ingress.class: nginx
# kubernetes.io/tls-acme: "true"
hosts:
- host: chart-example.local
paths: []
tls: []
# - secretName: chart-example-tls
# hosts:
# - chart-example.local
resources: {}
# We usually recommend not to specify default resources and to leave this as a conscious
# choice for the user. This also increases chances charts run on environments with little
# resources, such as Minikube. If you do want to specify resources, uncomment the following
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
# limits:
# cpu: 100m
# memory: 128Mi
# requests:
# cpu: 100m
# memory: 128Mi
nodeSelector: {}
tolerations: []
affinity: {}