APC 技術ブログ

株式会社エーピーコミュニケーションズの技術ブログです。

株式会社 エーピーコミュニケーションズの技術ブログです。

kubectlのTipsまとめ

はじめに

こんにちは、ACS事業部の過部です。

つい先日CKSを失効してしまったので、再取得に向けた復習を兼ねてCKA及びCKADで有用そうなTipsを中心にまとめてみました。

1. 基本操作系

Pod、Service、Deployment、ReplicaSet等のリソース情報を取得

kubectl get all

複数のリソース情報をまとめて取得

kubectl get po,svc,rs,deploy

リソース名をカンマ区切りで複数指定できます。

全ネームスペースのリソース情報を取得

kubectl get po -A

-Aオプションで全ネームスペースを取得対象としています。

複数マニフェストの一括apply

kubectl apply -f deploy-nginx.yaml -f svc-nginx.yaml

-fオプションを連ねることでマニフェストを複数指定できます。 kubectl deleteに関しても同様です。

ディレクトリ内の全てのマニフェストをapply

kubectl apply -f .

-fオプションの後ろにはディレクトリを指定できます。

ディレクトリ以下の全てのマニフェストをapply

kubectl apply -f -R .

-Rオプションを指定することでディレクトリ内を再帰的に探索してくれます。

標準入力経由でマニフェストをapply①

echo 'apiVersion: v1
kind: Pod
metadata:
  name: busybox-sleep
spec:
  containers:
  - name: busybox
    image: busybox
    args:
    - sleep
    - "1000000"' | kubectl apply -f -

kubectl apply -fの後ろに-を続けることで、標準入力からマニフェストを読み込みます。

標準入力経由でマニフェストをapply②

cat <<EOF | kubectl apply -f -
apiVersion: v1
kind: Pod
metadata:
  name: busybox-sleep
spec:
  containers:
  - name: busybox
    image: busybox
    args:
    - sleep
    - "1000000"
EOF

やっていることは①と同じです。

マニフェストのひな形をコマンドベースで生成

kubectl run nginx --image=nginx --dry-run=client -oyaml > pod.yaml

定番の時短コマンドです。 -oとyamlの間にスペースが無くても動きます。

マニフェストベースのリソース削除

kubectl delete -f nginx.yaml

Podの強制即時削除

kubectl delete po hoge --force --grace-period 0

Pod、Service、Deployment、ReplicaSet等の一括削除

kubectl delete all --all

カレントネームスペースに存在するPod、Service、Deployment、ReplicaSet等をまとめて削除できます。

2. 時短系

kubectlのオートコンプリート設定

zsh向け

echo '[[ $commands[kubectl] ]] && source <(kubectl completion zsh)' >> ~/.zshrc

bash向け

echo "source <(kubectl completion bash)" >> ~/.bashrc

kubectlのalias設定&alias使用時のオートコンプリート有効化

alias k=kubectl
complete -o default -F __start_kubectl k

alias設定

基本操作

alias kg="kubectl get"
alias kdes="kubectl describe"
alias kdel="kubectl delete"
alias kc="kubectl create"
alias kr="kubectl run"
alias kaf='kubectl apply -f'

デフォルトネームスペースの表示/変更

alias kn='f() { [ "$1" ] && kubectl config set-context --current --namespace $1 || kubectl config view --minify | grep namespace | cut -d" " -f6 ; } ; f'
使用例

引数ありで実行

ネームスペースを引数としknコマンドを実行すると、カレントコンテキストのデフォルトネームスペースが変更されます。 下記では、kube-systemにデフォルトネームスペースを変更しています。

➜  ~ kn kube-system
Context "sugibe-aks" modified.

引数無しで実行

knコマンド単体で実行した場合は、デフォルトネームスペースが表示されます。

➜  ~ kn
kube-system

カレントコンテキストの表示/変更

alias kx='f() { [ "$1" ] && kubectl config use-context $1 || kubectl config current-context ; } ; f'
使用例

引数無しで実行

kxコマンド単体で実行した場合は、カレントコンテキストが表示されます。

➜  ~ kx
sugibe-aks

引数ありで実行

コンテキストを引数としてkxコマンドを実行すると、カレントコンテキストが変更されます。 下記では、カレントコンテキストをsugibe-testに変更しています。

➜  ~ kx sugibe-test
Switched to context "sugibe-test".

リソースのひな形生成

alias -g do='--dry-run=client -o yaml'

zshのglobal alias機能を利用することで、コマンドの途中でもaliasが展開される仕組みになっています。

使用例
➜  ~ kubectl run nginx --image nginx do > nginx.yaml

Podの強制即時削除

alias -g now="--force --grace-period 0"

こちらもzshのglobal alias機能を利用しています。

使用例
➜  ~ kubectl delete po nginx now
warning: Immediate deletion does not wait for confirmation that the running resource has been terminated. The resource may continue to run on the cluster indefinitely.
pod "nginx" force deleted

リソースの省略名

リソース名 省略名
pods po
deployments deploy
replicasets rs
daemonsets ds
services svc
namespaces ns
configmaps cm
serviceaccounts sa
persistentvolumeclaims pvc
persistentvolumes pv
networkpolicies netpol
ingresses ing

kubectlコマンドオプションの省略記法

オプション 省略記法
--all-namespaces -A
--output -o
--selector -l
--watch -w
--label-columns -L

3. 便利な操作

コマンド凡例の確認

kubectl run -h | grep '# ' -A2

-hオプションを利用し、コマンドの使用例を確認できます。 grepを利用し、コマンドオプションの説明文の出力を省いています。

コマンド出力結果

➜  ~ kubectl run -h | grep '# ' -A2
  # Start a nginx pod
  kubectl run nginx --image=nginx

  # Start a hazelcast pod and let the container expose port 5701
  kubectl run hazelcast --image=hazelcast/hazelcast --port=5701

  # Start a hazelcast pod and set environment variables "DNS_DOMAIN=cluster" and "POD_NAMESPACE=default" in the container
  kubectl run hazelcast --image=hazelcast/hazelcast --env="DNS_DOMAIN=cluster" --env="POD_NAMESPACE=default"

  # Start a hazelcast pod and set labels "app=hazelcast" and "env=prod" in the container
  kubectl run hazelcast --image=hazelcast/hazelcast --labels="app=hazelcast,env=prod"

  # Dry run; print the corresponding API objects without creating them
  kubectl run nginx --image=nginx --dry-run=client

  # Start a nginx pod, but overload the spec with a partial set of values parsed from JSON
  kubectl run nginx --image=nginx --overrides='{ "apiVersion": "v1", "spec": { ... } }'

  # Start a busybox pod and keep it in the foreground, don't restart it if it exits
  kubectl run -i -t busybox --image=busybox --restart=Never

  # Start the nginx pod using the default command, but use custom arguments (arg1 .. argN) for that command
  kubectl run nginx --image=nginx -- <arg1> <arg2> ... <argN>

  # Start the nginx pod using a different command and custom arguments
  kubectl run nginx --image=nginx --command -- <cmd> <arg1> ... <argN>

Podの再生成

kubectl rollout restart deploy nginx

configMap及びSecret更新後、Podに再読み込みさせたい場合に有用です。 ※configMapやSecretの更新は、Podの再生成をトリガーしないため

マニフェストのフォーマットを確認(全階層)

kubectl explain svc --recursive

コマンド出力結果

KIND:     Service
VERSION:  v1

DESCRIPTION:
     Service is a named abstraction of software service (for example, mysql)
     consisting of local port (for example 3306) that the proxy listens on, and
     the selector that determines which pods will answer requests sent through
     the proxy.

FIELDS:
   apiVersion   <string>
   kind <string>
   metadata     <Object>
      annotations       <map[string]string>
      creationTimestamp <string>
      deletionGracePeriodSeconds        <integer>
      deletionTimestamp <string>
      finalizers        <[]string>
      generateName      <string>
      generation        <integer>
      labels    <map[string]string>
      managedFields     <[]Object>
         apiVersion     <string>
         fieldsType     <string>
         fieldsV1       <map[string]>
         manager        <string>
         operation      <string>
         subresource    <string>
         time   <string>
      name      <string>
      namespace <string>
      ownerReferences   <[]Object>
         apiVersion     <string>
         blockOwnerDeletion     <boolean>
         controller     <boolean>
         kind   <string>
         name   <string>
         uid    <string>
      resourceVersion   <string>
      selfLink  <string>
      uid       <string>
   spec <Object>
      allocateLoadBalancerNodePorts     <boolean>
      clusterIP <string>
      clusterIPs        <[]string>
      externalIPs       <[]string>
      externalName      <string>
      externalTrafficPolicy     <string>
      healthCheckNodePort       <integer>
      internalTrafficPolicy     <string>
      ipFamilies        <[]string>
      ipFamilyPolicy    <string>
      loadBalancerClass <string>
      loadBalancerIP    <string>
      loadBalancerSourceRanges  <[]string>
      ports     <[]Object>
         appProtocol    <string>
         name   <string>
         nodePort       <integer>
         port   <integer>
         protocol       <string>
         targetPort     <string>
      publishNotReadyAddresses  <boolean>
      selector  <map[string]string>
      sessionAffinity   <string>
      sessionAffinityConfig     <Object>
         clientIP       <Object>
            timeoutSeconds      <integer>
      type      <string>
   status       <Object>
      conditions        <[]Object>
         lastTransitionTime     <string>
         message        <string>
         observedGeneration     <integer>
         reason <string>
         status <string>
         type   <string>
      loadBalancer      <Object>
         ingress        <[]Object>
            hostname    <string>
            ip  <string>
            ports       <[]Object>
               error    <string>
               port     <integer>
               protocol <string>

マニフェストのフォーマットを確認(特定フィールド)

kubectl explain svc.spec.ports

各フィールドの詳細な説明を確認できます。 階層ごとにドット区切りでフィールド名を指定できます。

コマンド出力結果

➜  ~ kubectl explain svc.spec.ports
KIND:     Service
VERSION:  v1

RESOURCE: ports <[]Object>

DESCRIPTION:
     The list of ports that are exposed by this service. More info:
     https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies

     ServicePort contains information on service's port.

FIELDS:
   appProtocol  <string>
     The application protocol for this port. This field follows standard
     Kubernetes label syntax. Un-prefixed names are reserved for IANA standard
     service names (as per RFC-6335 and
     https://www.iana.org/assignments/service-names). Non-standard protocols
     should use prefixed names such as mycompany.com/my-custom-protocol.

   name <string>
     The name of this port within the service. This must be a DNS_LABEL. All
     ports within a ServiceSpec must have unique names. When considering the
     endpoints for a Service, this must match the 'name' field in the
     EndpointPort. Optional if only one ServicePort is defined on this service.

   nodePort     <integer>
     The port on each node on which this service is exposed when type is
     NodePort or LoadBalancer. Usually assigned by the system. If a value is
     specified, in-range, and not in use it will be used, otherwise the
     operation will fail. If not specified, a port will be allocated if this
     Service requires one. If this field is specified when creating a Service
     which does not need it, creation will fail. This field will be wiped when
     updating a Service to no longer need it (e.g. changing type from NodePort
     to ClusterIP). More info:
     https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport

   port <integer> -required-
     The port that will be exposed by this service.

   protocol     <string>
     The IP protocol for this port. Supports "TCP", "UDP", and "SCTP". Default
     is TCP.

     Possible enum values:
     - `"SCTP"` is the SCTP protocol.
     - `"TCP"` is the TCP protocol.
     - `"UDP"` is the UDP protocol.

   targetPort   <string>
     Number or name of the port to access on the pods targeted by the service.
     Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. If
     this is a string, it will be looked up as a named port in the target Pod's
     container ports. If this is not specified, the value of the 'port' field is
     used (an identity map). This field is ignored for services with
     clusterIP=None, and should be omitted or set equal to the 'port' field.
     More info:
     https://kubernetes.io/docs/concepts/services-networking/service/#defining-a-service

リソースの省略名一覧を確認

kubectl api-resources

SHORTNAMES列で省略名を確認できます。

コマンド出力結果

➜  t_sugibe kubectl api-resources
NAME                              SHORTNAMES          APIVERSION                             NAMESPACED   KIND
bindings                                              v1                                     true         Binding
componentstatuses                 cs                  v1                                     false        ComponentStatus
configmaps                        cm                  v1                                     true         ConfigMap
endpoints                         ep                  v1                                     true         Endpoints
events                            ev                  v1                                     true         Event
limitranges                       limits              v1                                     true         LimitRange
namespaces                        ns                  v1                                     false        Namespace
nodes                             no                  v1                                     false        Node
persistentvolumeclaims            pvc                 v1                                     true         PersistentVolumeClaim
persistentvolumes                 pv                  v1                                     false        PersistentVolume
pods                              po                  v1                                     true         Pod
podtemplates                                          v1                                     true         PodTemplate
replicationcontrollers            rc                  v1                                     true         ReplicationController
resourcequotas                    quota               v1                                     true         ResourceQuota
secrets                                               v1                                     true         Secret
serviceaccounts                   sa                  v1                                     true         ServiceAccount
services                          svc                 v1                                     true         Service
mutatingwebhookconfigurations                         admissionregistration.k8s.io/v1        false        MutatingWebhookConfiguration
validatingwebhookconfigurations                       admissionregistration.k8s.io/v1        false        ValidatingWebhookConfiguration
customresourcedefinitions         crd,crds            apiextensions.k8s.io/v1                false        CustomResourceDefinition
apiservices                                           apiregistration.k8s.io/v1              false        APIService
controllerrevisions                                   apps/v1                                true         ControllerRevision
daemonsets                        ds                  apps/v1                                true         DaemonSet
deployments                       deploy              apps/v1                                true         Deployment
replicasets                       rs                  apps/v1                                true         ReplicaSet
statefulsets                      sts                 apps/v1                                true         StatefulSet
tokenreviews                                          authentication.k8s.io/v1               false        TokenReview
localsubjectaccessreviews                             authorization.k8s.io/v1                true         LocalSubjectAccessReview
selfsubjectaccessreviews                              authorization.k8s.io/v1                false        SelfSubjectAccessReview
selfsubjectrulesreviews                               authorization.k8s.io/v1                false        SelfSubjectRulesReview
subjectaccessreviews                                  authorization.k8s.io/v1                false        SubjectAccessReview
horizontalpodautoscalers          hpa                 autoscaling/v2                         true         HorizontalPodAutoscaler
cronjobs                          cj                  batch/v1                               true         CronJob
jobs                                                  batch/v1                               true         Job
certificatesigningrequests        csr                 certificates.k8s.io/v1                 false        CertificateSigningRequest
leases                                                coordination.k8s.io/v1                 true         Lease
bgpconfigurations                                     crd.projectcalico.org/v1               false        BGPConfiguration
bgppeers                                              crd.projectcalico.org/v1               false        BGPPeer
blockaffinities                                       crd.projectcalico.org/v1               false        BlockAffinity
caliconodestatuses                                    crd.projectcalico.org/v1               false        CalicoNodeStatus
clusterinformations                                   crd.projectcalico.org/v1               false        ClusterInformation
felixconfigurations                                   crd.projectcalico.org/v1               false        FelixConfiguration
globalnetworkpolicies                                 crd.projectcalico.org/v1               false        GlobalNetworkPolicy
globalnetworksets                                     crd.projectcalico.org/v1               false        GlobalNetworkSet
hostendpoints                                         crd.projectcalico.org/v1               false        HostEndpoint
ipamblocks                                            crd.projectcalico.org/v1               false        IPAMBlock
ipamconfigs                                           crd.projectcalico.org/v1               false        IPAMConfig
ipamhandles                                           crd.projectcalico.org/v1               false        IPAMHandle
ippools                                               crd.projectcalico.org/v1               false        IPPool
ipreservations                                        crd.projectcalico.org/v1               false        IPReservation
kubecontrollersconfigurations                         crd.projectcalico.org/v1               false        KubeControllersConfiguration
networkpolicies                                       crd.projectcalico.org/v1               true         NetworkPolicy
networksets                                           crd.projectcalico.org/v1               true         NetworkSet
endpointslices                                        discovery.k8s.io/v1                    true         EndpointSlice
events                            ev                  events.k8s.io/v1                       true         Event
flowschemas                                           flowcontrol.apiserver.k8s.io/v1beta3   false        FlowSchema
prioritylevelconfigurations                           flowcontrol.apiserver.k8s.io/v1beta3   false        PriorityLevelConfiguration
nodes                                                 metrics.k8s.io/v1beta1                 false        NodeMetrics
pods                                                  metrics.k8s.io/v1beta1                 true         PodMetrics
ingressclasses                                        networking.k8s.io/v1                   false        IngressClass
ingresses                         ing                 networking.k8s.io/v1                   true         Ingress
networkpolicies                   netpol              networking.k8s.io/v1                   true         NetworkPolicy
runtimeclasses                                        node.k8s.io/v1                         false        RuntimeClass
apiservers                                            operator.tigera.io/v1                  false        APIServer
imagesets                                             operator.tigera.io/v1                  false        ImageSet
installations                                         operator.tigera.io/v1                  false        Installation
tigerastatuses                                        operator.tigera.io/v1                  false        TigeraStatus
poddisruptionbudgets              pdb                 policy/v1                              true         PodDisruptionBudget
clusterrolebindings                                   rbac.authorization.k8s.io/v1           false        ClusterRoleBinding
clusterroles                                          rbac.authorization.k8s.io/v1           false        ClusterRole
rolebindings                                          rbac.authorization.k8s.io/v1           true         RoleBinding
roles                                                 rbac.authorization.k8s.io/v1           true         Role
priorityclasses                   pc                  scheduling.k8s.io/v1                   false        PriorityClass
volumesnapshotclasses             vsclass,vsclasses   snapshot.storage.k8s.io/v1             false        VolumeSnapshotClass
volumesnapshotcontents            vsc,vscs            snapshot.storage.k8s.io/v1             false        VolumeSnapshotContent
volumesnapshots                   vs                  snapshot.storage.k8s.io/v1             true         VolumeSnapshot
csidrivers                                            storage.k8s.io/v1                      false        CSIDriver
csinodes                                              storage.k8s.io/v1                      false        CSINode
csistoragecapacities                                  storage.k8s.io/v1                      true         CSIStorageCapacity
storageclasses                    sc                  storage.k8s.io/v1                      false        StorageClass
volumeattachments                                     storage.k8s.io/v1                      false        VolumeAttachment

既存Podのコンテナイメージ変更

kubectl set image deploy nginx $CONTAINER_NAMEx=$CONTAINER_IMAGE

既存リソースの編集

kubectl edit po nginx

コマンドを実行すると、指定したリソースに対応するマニフェストファイルがエディター上で開きます。 内容保存時にエディター上で行った変更がリソースに対して適用されます。 ※ただし、リソースの再作成が必要な変更の場合を除く

既存リソースの編集(リソース再作成が必須な変更を行う場合)

kubectl edit po nginx
A copy of your changes has been stored to "/tmp/kubectl-edit-3101613709.yaml"
error: At least one of apiVersion, kind and name was changed

前回同様リソースを編集できますが、内容を保存してもリソースに変更は反映されません。 その代わりに、変更内容が反映されたマニフェストファイルがtmpファイルとして生成されるので、それを用いてデプロイを行います。

既存リソースとマニフェスト間の差分表示

kubectl diff -f nginx.yaml

以下は、imageをnginxからnginx:1.0.0に変更した際の出力結果です。

コマンド出力結果

➜  ~ kubectl diff -f nginx.yaml
diff -u -N /tmp/LIVE-1836240322/apps.v1.Deployment.default.nginx /tmp/MERGED-2289542089/apps.v1.Deployment.default.nginx
--- /tmp/LIVE-1836240322/apps.v1.Deployment.default.nginx       2023-09-26 16:57:59.698027000 +0900
+++ /tmp/MERGED-2289542089/apps.v1.Deployment.default.nginx     2023-09-26 16:57:59.698027000 +0900
@@ -6,7 +6,7 @@
     kubectl.kubernetes.io/last-applied-configuration: |
       {"apiVersion":"apps/v1","kind":"Deployment","metadata":{"annotations":{},"creationTimestamp":null,"labels":{"app":"nginx"},"name":"nginx","namespace":"default"},"spec":{"replicas":1,"selector":{"matchLabels":{"app":"nginx"}},"strategy":{},"template":{"metadata":{"creationTimestamp":null,"labels":{"app":"nginx"}},"spec":{"containers":[{"image":"nginx","name":"nginx","resources":{}}]}}},"status":{}}
   creationTimestamp: "2023-09-26T07:57:36Z"
-  generation: 2
+  generation: 3
   labels:
     app: nginx
   managedFields:
@@ -15,49 +15,6 @@
     fieldsV1:
       f:metadata:
         f:annotations:
-          .: {}
-          f:kubectl.kubernetes.io/last-applied-configuration: {}
-        f:labels:
-          .: {}
-          f:app: {}
-      f:spec:
-        f:progressDeadlineSeconds: {}
-        f:replicas: {}
-        f:revisionHistoryLimit: {}
-        f:selector: {}
-        f:strategy:
-          f:rollingUpdate:
-            .: {}
-            f:maxSurge: {}
-            f:maxUnavailable: {}
-          f:type: {}
-        f:template:
-          f:metadata:
-            f:labels:
-              .: {}
-              f:app: {}
-          f:spec:
-            f:containers:
-              k:{"name":"nginx"}:
-                .: {}
-                f:imagePullPolicy: {}
-                f:name: {}
-                f:resources: {}
-                f:terminationMessagePath: {}
-                f:terminationMessagePolicy: {}
-            f:dnsPolicy: {}
-            f:restartPolicy: {}
-            f:schedulerName: {}
-            f:securityContext: {}
-            f:terminationGracePeriodSeconds: {}
-    manager: kubectl-client-side-apply
-    operation: Update
-    time: "2023-09-26T07:57:36Z"
-  - apiVersion: apps/v1
-    fieldsType: FieldsV1
-    fieldsV1:
-      f:metadata:
-        f:annotations:
           f:deployment.kubernetes.io/revision: {}
       f:status:
         f:availableReplicas: {}
@@ -91,15 +48,47 @@
   - apiVersion: apps/v1
     fieldsType: FieldsV1
     fieldsV1:
+      f:metadata:
+        f:annotations:
+          .: {}
+          f:kubectl.kubernetes.io/last-applied-configuration: {}
+        f:labels:
+          .: {}
+          f:app: {}
       f:spec:
+        f:progressDeadlineSeconds: {}
+        f:replicas: {}
+        f:revisionHistoryLimit: {}
+        f:selector: {}
+        f:strategy:
+          f:rollingUpdate:
+            .: {}
+            f:maxSurge: {}
+            f:maxUnavailable: {}
+          f:type: {}
         f:template:
+          f:metadata:
+            f:labels:
+              .: {}
+              f:app: {}
           f:spec:
             f:containers:
               k:{"name":"nginx"}:
+                .: {}
                 f:image: {}
-    manager: kubectl-set
+                f:imagePullPolicy: {}
+                f:name: {}
+                f:resources: {}
+                f:terminationMessagePath: {}
+                f:terminationMessagePolicy: {}
+            f:dnsPolicy: {}
+            f:restartPolicy: {}
+            f:schedulerName: {}
+            f:securityContext: {}
+            f:terminationGracePeriodSeconds: {}
+    manager: kubectl-client-side-apply
     operation: Update
-    time: "2023-09-26T07:57:55Z"
+    time: "2023-09-26T07:58:01Z"
   name: nginx
   namespace: default
   resourceVersion: "278923"
@@ -123,7 +112,7 @@
         app: nginx
     spec:
       containers:
-      - image: nginx:1.0.0
+      - image: nginx
         imagePullPolicy: Always
         name: nginx
         resources: {}

kubectl getの定期実行

kubectl get -w
使い方

例えば、Depoymentを作成後に全てのPodが利用可能な状態になったか確認したい場合に利用できます。

➜  ~ kubectl create deploy nginx --image nginx --replicas=5
deployment.apps/nginx created
➜  ~ kubectl get po -w
NAME                     READY   STATUS              RESTARTS   AGE
nginx-748c667d99-59gqb   0/1     ContainerCreating   0          4s[f:id:p1k42:20230926172607p:plain]
nginx-748c667d99-l4hgc   0/1     ContainerCreating   0          4s
nginx-748c667d99-tnbfb   0/1     ContainerCreating   0          4s
nginx-748c667d99-xb4dn   0/1     ContainerCreating   0          4s
nginx-748c667d99-zkbbd   0/1     ContainerCreating   0          4s
nginx-748c667d99-l4hgc   1/1     Running             0          4s
nginx-748c667d99-tnbfb   1/1     Running             0          6s
nginx-748c667d99-zkbbd   1/1     Running             0          8s
nginx-748c667d99-xb4dn   1/1     Running             0          11s
nginx-748c667d99-59gqb   1/1     Running             0          13s

おわりに

他にも有用なTipsがあればコメントで教えてください。泣いて喜びます。 よく使うリソース作成コマンド集も近々投稿予定です。

私達ACS事業部はAzure・AKSを活用した内製化のご支援をしております。ご相談等ありましたらぜひご連絡ください。

www.ap-com.co.jp

また、一緒に働いていただける仲間も募集中です!
切磋琢磨しながらスキルを向上できる、エンジニアには良い環境だと思います。ご興味を持っていただけたら嬉しく思います。

www.ap-com.co.jp

本記事の投稿者: 過部 太智
Taichi Sugibe - Credly