Filters
Zo zoek je
  • Gewone woorden vinden namen, teksten en voorbeelden.
  • "twee woorden" vindt precies die zin.
  • --naam of -x vindt een optie.
  • #woord zoekt alleen in commando's.
  • @grep vindt lessen en labs die grep gebruiken.
  • Filters: cat:network · in:labs · in:notes · level:rhcsa · ch:8 · root:yes. Zet ! voor een woord om het weg te laten. OR tussen woorden betekent één ervan.
  • ↑ ↓ bewegen · Enter openen · Esc sluiten · / zoeken

istioctl

Install and check the Istio service mesh: mTLS between pods, traffic splitting for canary releases, and the Envoy proxy config.

Niveau
DevOps-tool
Groep
Containers en Kubernetes
Root nodig
Nee
Pakket
istioctl

Dit deel is nog niet vertaald. Je ziet de Engelse tekst.

Wat het doet

A service mesh adds a proxy (Envoy) next to every pod, or a node proxy in ambient mode. The mesh then gives mTLS between services, retries, timeouts and traffic splitting — without changing the apps. istioctl installs Istio, checks the config (analyze) and shows what each proxy really does (proxy-config).

The traffic rules themselves are Kubernetes objects: VirtualService, DestinationRule, Gateway, PeerAuthentication.

Zo schrijf je het

istioctl COMMAND [OPTIONS]

Belangrijkste delen

Commands

install --set profile=NAME
Install Istio (default, demo, minimal, ambient).
verify-install
Check the install.
analyze [-A]
Find problems in the mesh config.
proxy-status
Is every proxy in sync with the control plane?
proxy-config routes|clusters|listeners POD
The Envoy config of one pod.
x describe pod POD
Which rules apply to a pod.
dashboard kiali|grafana|jaeger
Open a dashboard.
upgrade / uninstall --purge
Upgrade / remove Istio.
version
Client and control plane versions.

Opties 6

Meest gebruikt

Options

-n, --namespace NS
Namespace.
-A, --all-namespaces
All namespaces (analyze).
--set KEY=VALUE
Install setting.
-f FILE
IstioOperator file.
-y, --skip-confirmation
No question.
-o json|yaml
Output format.

Voorbeelden 10

$ als gewone gebruiker# als root (of met sudo)

  1. 1Install and add the sidecar to a namespace

    istioctl install --set profile=default -y
    kubectl label namespace shop istio-injection=enabled
    kubectl rollout restart deploy -n shop
  2. 2Ambient mode (no sidecars)

    istioctl install --set profile=ambient -y
    kubectl label namespace shop istio.io/dataplane-mode=ambient
  3. 3Check the config

    istioctl analyze -A
  4. 4Are all proxies in sync?

    istioctl proxy-status
  5. 5Force mTLS in a namespace

    cat peer-auth.yaml
    apiVersion: security.istio.io/v1
    kind: PeerAuthentication
    metadata: { name: default, namespace: shop }
    spec: { mtls: { mode: STRICT } }
    kubectl apply -f peer-auth.yaml
  6. 6Canary: 90 % to v1, 10 % to v2

    cat vs.yaml
    apiVersion: networking.istio.io/v1
    kind: VirtualService
    metadata: { name: shop, namespace: shop }
    spec:
      hosts: [shop]
      http:
        - route:
            - { destination: { host: shop, subset: v1 }, weight: 90 }
            - { destination: { host: shop, subset: v2 }, weight: 10 }
    kubectl apply -f vs.yaml
  7. 7Which rules apply to this pod?

    istioctl x describe pod shop-7d9c-abcde -n shop
  8. 8The routes Envoy really uses

    istioctl proxy-config routes deploy/shop -n shop
  9. 9Open Kiali (needs the add-on)

    istioctl dashboard kiali
  10. 10Versions

    istioctl version

Let op

  • Sidecars add CPU, memory and latency to every pod; size the nodes for it.
  • STRICT mTLS breaks callers outside the mesh; start with PERMISSIVE and check.

Tips om te onthouden

  • Linkerd is a lighter mesh with the same basic ideas.

Exitcodes

0OK.
1Error.
79analyze found problems.