Skip to content

teardown all leaves operator behind #72

Description

@porridge

Is this by design?

[stackrox]$ roxie deploy central
00:00 Using kubeconfig /home/mowsiany/go/src/github.com/stackrox/stackrox/kubeconfig-kind.txt
00:00 Running with a controlling terminal.
00:00 🚀 ACS Deployer initialized
00:00 roxctl version: 4.9.1
00:00 00:00 ┌────────────────────────────────────────────────────────────┐
00:00 │ Deployment Configuration │
00:00 ├────────────────────────────────────────────────────────────┤
00:00 │ Component: Central │
00:00 │ Cluster Type: Kind │
00:00 │ Main Tag: │
00:00 │ Kubernetes Context: kind-kind │
00:00 │ Deployment Method: Operator │
00:00 │ Exposure: loadbalancer │
00:00 └────────────────────────────────────────────────────────────┘
00:00 00:00 Looking up main image tag
00:01 Using stackrox repository tag: 4.11.x-352-gc901cd9fd5
00:01 Detected kind cluster: using --resources=small --exposure=none with port-forwarding
00:01 Preparing and verifying Docker credentials...
00:01 REGISTRY_USERNAME/REGISTRY_PASSWORD unset. Trying to obtain Docker credentials from config file: /home/mowsiany/.docker/config.json
00:02 Successfully verified credentials for quay.io (repository: rhacs-eng/main)
00:02 Docker credentials verified successfully
00:02 Initiating deployment of Central
00:02 Deploying Central to namespace acs-central
00:02 Existing Central deployment found, tearing down...
00:02 🗑️ Tearing down acs-central
00:02 ⏳ Waiting for Central resources to be fully deleted...
00:02 Deleting Central resources
00:02 ✓ Central resources in namespace acs-central have been deleted
00:02 🚀 Deploying Central via Operator...
00:02 Operator version mismatch detected:
00:02 Current: 4.11.0-438-g8673b4bdac
00:02 Desired: 4.11.0-352-gc901cd9fd5
00:02 🔄 Operator version mismatch, redeploying...
00:02 🧹 Tearing down operator deployed without OLM...
00:13 ⋯ Still waiting for namespace deletion... (10s elapsed)
00:15 Namespace rhacs-operator-system has been deleted
00:15 ✓ Non-OLM operator resources removed
00:15 Operator tag: 4.11.0-352-gc901cd9fd5
00:15 Created temporary directory: /tmp/nix-shell.OAKtwZ/nix-shell.bWk6oH/stackrox-operator-bundle-1703022866
00:15 Using podman to extract bundle
00:15 Pulling operator bundle image...
00:19 ✓ Bundle extracted to: /tmp/nix-shell.OAKtwZ/nix-shell.bWk6oH/stackrox-operator-bundle-1703022866
00:19 Bundle image: quay.io/rhacs-eng/stackrox-operator-bundle:v4.11.0-352-gc901cd9fd5
00:19 Applying 3 CRD(s) to cluster
00:19 ✓ Successfully applied CRD config.stackrox.io_securitypolicies.yaml
00:19 ✓ Successfully applied CRD platform.stackrox.io_centrals.yaml
00:19 ✓ Successfully applied CRD platform.stackrox.io_securedclusters.yaml
00:19 🔍 Parsing ClusterServiceVersion deployment specification
00:19 📋 Operator deployment plan:
00:19 • Namespace: rhacs-operator-system
00:19 • ServiceAccount: rhacs-operator-controller-manager
00:20 ⏳ Waiting for operator deployment to become ready...
00:40 ✓ Operator deployment is ready (1 replicas)
00:40 🎉 Operator deployment completed successfully!
00:40 Cleaned up operator bundle directory: /tmp/nix-shell.OAKtwZ/nix-shell.bWk6oH/stackrox-operator-bundle-1703022866
00:40 Preparing namespace acs-central
00:41 ✓ Admin password secret created
00:41 Using Central resource profile: small
00:41 Applying Central custom resource
00:41 ✓ Central Custom Resource applied
00:41 ⏳ Waiting for Central to become ready...
00:50 → Deployment 'central' created (/1 replicas ready)
00:50 → Deployment 'central-db' created (/1 replicas ready)
00:50 → Deployment 'config-controller' created (/1 replicas ready)
00:50 → Deployment 'scanner-v4-db' created (/1 replicas ready)
00:50 → Deployment 'scanner-v4-indexer' created (/1 replicas ready)
00:50 → Deployment 'scanner-v4-matcher' created (/1 replicas ready)
00:50 • Pod 'central-58cbc687d5-jmtmf' starting...
00:50 • Pod 'central-db-699cd4d4d9-l54lh' starting...
00:50 • Pod 'config-controller-744b947db5-v85dv' starting...
00:50 • Pod 'scanner-v4-db-5685fc9f76-28672' starting...
00:50 • Pod 'scanner-v4-indexer-bcd9b48c4-h47fd' starting...
00:50 • Pod 'scanner-v4-matcher-7754c7fc7c-w46vg' starting...
01:09 • Pod 'scanner-v4-indexer-bcd9b48c4-h47fd' running (not ready yet)
02:15 • Pod 'config-controller-744b947db5-v85dv' running (not ready yet)
02:18 • Pod 'central-58cbc687d5-jmtmf' running (not ready yet)
02:18 • Pod 'scanner-v4-matcher-7754c7fc7c-w46vg' running (not ready yet)
02:43 ⋯ Deployment 'scanner-v4-db' progressing (1/1 replicas ready)
02:43 • Pod 'scanner-v4-db-5685fc9f76-28672' is ready
02:59 ✓ Deployment 'scanner-v4-db' is available (1/1 replicas)
03:02 ⋯ Deployment 'scanner-v4-matcher' progressing (1/1 replicas ready)
03:02 • Pod 'scanner-v4-matcher-7754c7fc7c-w46vg' is ready
03:05 ⋯ Deployment 'central-db' progressing (1/1 replicas ready)
03:05 • Pod 'central-db-699cd4d4d9-l54lh' is ready
03:14 ✓ Deployment 'scanner-v4-matcher' is available (1/1 replicas)
03:18 ✓ Deployment 'central-db' is available (1/1 replicas)
03:21 ⋯ Deployment 'central' progressing (1/1 replicas ready)
03:21 • Pod 'central-58cbc687d5-jmtmf' is ready
03:21 ✓ Central is ready (1 replicas)
03:21 ✓ Port-forward active at https://127.0.0.1:8443
03:21 Fetching Central CA certificate...
03:21 ✓ CA certificate saved to: /tmp/roxie-ca-cert.pem
03:21 ✓ Central is ready at: 127.0.0.1:8443
03:21 ✓ Admin password: KhUBJIrZYz7jLtSI9RjX
03:21 🎉 Deployment complete!
03:21 ⏳ Waiting for Central to be ready at 127.0.0.1:8443 (timeout: 5m0s)
03:21 ✓ Central is ready and responding!
03:21 Spawning sub-shell: /bin/bash
[roxie] Entering a subshell with ACS environment variables set.
[roxie]
[roxie] Environment is set up for talking to ACS Central. Examples:
[roxie]
[roxie] * roxctl central whoami
[roxie] * roxcurl /v1/clusters
[roxie]
[roxie] Note: Installing haproxy enables automatic HTTP access to Central at http://localhost:8080
[stackrox]$ exit
[roxie] Exited subshell. You are now back in your original shell.
[stackrox]$ roxie teardown central operator
Error: accepts at most 1 arg(s), received 2
[stackrox]$ roxie teardown all
00:00 Using kubeconfig /home/mowsiany/go/src/github.com/stackrox/stackrox/kubeconfig-kind.txt
00:00 Tearing down all
00:00 🚀 ACS Deployer initialized
00:00 roxctl version: 4.9.1
00:00 Starting teardown of all
00:00 🗑️ Tearing down acs-sensor
00:00 Namespace acs-sensor doesn't exist, skipping
00:00 🗑️ Tearing down acs-central
00:00 ⏳ Waiting for Central resources to be fully deleted...
00:00 Deleting Central resources
00:07 ✓ Central resources in namespace acs-central have been deleted
00:07 🎉 Teardown complete!
[stackrox]$ oc get ns
NAME STATUS AGE
acs-central Active 20h
default Active 20d
kube-node-lease Active 20d
kube-public Active 20d
kube-system Active 20d
local-path-storage Active 20d
rhacs-operator-system Active 19h
[stackrox]$ oc get pods -n rhacs-operator-system NAME READY STATUS RESTARTS AGE
rhacs-operator-controller-manager-5645d4977f-qmmnd 1/1 Running 0 20h
[stackrox]$ 

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions