From 3840971aa529696d092ac78763982c29e7bd9fb5 Mon Sep 17 00:00:00 2001 From: Drew Skwiers-Koballa Date: Fri, 13 Nov 2026 10:11:39 -0800 Subject: [PATCH] swaps temporal cli for tctl --- compose/docker-compose-multirole.yaml | 7 ------- compose/docker-compose-tls.yml | 2 -- tls/tls-full/README.md | 15 ++++++++++----- tls/tls-full/docker-compose.yml | 26 -------------------------- 4 files changed, 10 insertions(+), 40 deletions(-) diff --git a/compose/docker-compose-multirole.yaml b/compose/docker-compose-multirole.yaml index b7a39f3..60585aa 100644 --- a/compose/docker-compose-multirole.yaml +++ b/compose/docker-compose-multirole.yaml @@ -113,7 +113,6 @@ services: - ENABLE_ES=true - ES_SEEDS=elasticsearch - ES_VERSION=v7 - - TEMPORAL_CLI_ADDRESS=temporal-nginx:7233 - TEMPORAL_ADDRESS=temporal-nginx:7233 image: temporalio/server:${TEMPORAL_VERSION} ports: @@ -146,7 +145,6 @@ services: - ENABLE_ES=true - ES_SEEDS=elasticsearch - ES_VERSION=v7 - - TEMPORAL_CLI_ADDRESS=temporal-nginx:7233 - TEMPORAL_ADDRESS=temporal-nginx:7233 image: temporalio/server:${TEMPORAL_VERSION} ports: @@ -180,7 +178,6 @@ services: - ENABLE_ES=true - ES_SEEDS=elasticsearch - ES_VERSION=v7 - - TEMPORAL_CLI_ADDRESS=temporal-nginx:7233 - TEMPORAL_ADDRESS=temporal-nginx:7233 image: temporalio/server:${TEMPORAL_VERSION} ports: @@ -217,7 +214,6 @@ services: - ENABLE_ES=true - ES_SEEDS=elasticsearch - ES_VERSION=v7 - - TEMPORAL_CLI_ADDRESS=temporal-nginx:7233 - TEMPORAL_ADDRESS=temporal-nginx:7233 image: temporalio/server:${TEMPORAL_VERSION} ports: @@ -249,7 +245,6 @@ services: - PROMETHEUS_ENDPOINT=0.0.0.0:8003 # set to nginx - PUBLIC_FRONTEND_ADDRESS=temporal-nginx:7233 - - TEMPORAL_CLI_ADDRESS=temporal-nginx:7233 - TEMPORAL_ADDRESS=temporal-nginx:7233 - ENABLE_ES=true - ES_SEEDS=elasticsearch @@ -289,7 +284,6 @@ services: depends_on: - temporal-nginx environment: - - TEMPORAL_CLI_ADDRESS=temporal-nginx:7233 - TEMPORAL_ADDRESS=temporal-nginx:7233 image: temporalio/admin-tools:${TEMPORAL_ADMINTOOLS_VERSION} stdin_open: true @@ -303,7 +297,6 @@ services: - temporal-nginx environment: - TEMPORAL_CORS_ORIGINS=http://localhost:3000 - - TEMPORAL_CLI_ADDRESS=temporal-nginx:7233 - TEMPORAL_ADDRESS=temporal-nginx:7233 image: temporalio/ui:${TEMPORAL_UI_VERSION} ports: diff --git a/compose/docker-compose-tls.yml b/compose/docker-compose-tls.yml index 989c983..ee25867 100644 --- a/compose/docker-compose-tls.yml +++ b/compose/docker-compose-tls.yml @@ -127,7 +127,6 @@ services: - ES_USER=elastic - ES_PWD=elastic - TEMPORAL_ADDRESS=temporal:7233 - - TEMPORAL_CLI_ADDRESS=temporal:7233 networks: - temporal-network ports: @@ -166,7 +165,6 @@ services: condition: service_healthy environment: - TEMPORAL_ADDRESS=temporal:7233 - - TEMPORAL_CLI_ADDRESS=temporal:7233 build: context: . dockerfile: tls/Dockerfile.admin-tools-tls diff --git a/tls/tls-full/README.md b/tls/tls-full/README.md index 0e3af57..02d42c4 100644 --- a/tls/tls-full/README.md +++ b/tls/tls-full/README.md @@ -38,16 +38,21 @@ cluster-internode | | | ./start-temporal.sh ``` -3. You can use docker to enter the cli containers and use `tctl` like this (in another terminal): +3. You can use docker to enter the CLI containers and use the Temporal CLI (`temporal`) like this (in another terminal): ```bash -docker exec -it tls-full-temporal-cli-admin-1 bash -docker exec -it tls-full-temporal-cli-development-1 bash -docker exec -it tls-full-temporal-cli-accounting-1 bash +docker exec -it tls-full-temporal-cli-admin-1 sh +docker exec -it tls-full-temporal-cli-development-1 sh +docker exec -it tls-full-temporal-cli-accounting-1 sh ``` Environment variables are set up to provide the `development` and `accounting` containers with access to namespaces with the respective names. -(You'll have to create them first with `tctl namespace register`.) +Create the namespaces first using the admin container: + +```bash +docker exec tls-full-temporal-cli-admin-1 temporal operator namespace create --namespace development +docker exec tls-full-temporal-cli-admin-1 temporal operator namespace create --namespace accounting +``` 4. But you might notice that all three containers actually have identical (full admin-level) permissions! That's because there's no ClaimMapper or Authorizer actually examining the client certs to determine permissions. diff --git a/tls/tls-full/docker-compose.yml b/tls/tls-full/docker-compose.yml index 9bf2168..77aae78 100644 --- a/tls/tls-full/docker-compose.yml +++ b/tls/tls-full/docker-compose.yml @@ -15,12 +15,6 @@ services: - "TEMPORAL_SERVICES=frontend:matching:history:worker:internal-frontend" - "CASSANDRA_SEEDS=cassandra" - "DYNAMIC_CONFIG_FILE_PATH=config/dynamicconfig/development.yaml" - - "TEMPORAL_CLI_ADDRESS=temporal:7233" # used by tctl. Will be deprecated - - "TEMPORAL_CLI_TLS_CA=${TEMPORAL_TLS_CERTS_DIR}/cluster/ca/server-intermediate-ca.pem" - - "TEMPORAL_CLI_TLS_CERT=${TEMPORAL_TLS_CERTS_DIR}/cluster/internode/cluster-internode.pem" - - "TEMPORAL_CLI_TLS_KEY=${TEMPORAL_TLS_CERTS_DIR}/cluster/internode/cluster-internode.key" - - "TEMPORAL_CLI_TLS_ENABLE_HOST_VERIFICATION=true" - - "TEMPORAL_CLI_TLS_SERVER_NAME=internode.cluster-x.contoso.com" - "TEMPORAL_ADDRESS=temporal:7233" # used by Temporal CLI - "TEMPORAL_TLS_CA=${TEMPORAL_TLS_CERTS_DIR}/cluster/ca/server-intermediate-ca.pem" - "TEMPORAL_TLS_CERT=${TEMPORAL_TLS_CERTS_DIR}/cluster/internode/cluster-internode.pem" @@ -51,12 +45,6 @@ services: volumes: - ${TEMPORAL_LOCAL_CERT_DIR}:${TEMPORAL_TLS_CERTS_DIR} environment: - - "TEMPORAL_CLI_ADDRESS=temporal:7233" # used by tctl. Will be deprecated - - "TEMPORAL_CLI_TLS_CA=${TEMPORAL_TLS_CERTS_DIR}/cluster/ca/server-intermediate-ca.pem" - - "TEMPORAL_CLI_TLS_CERT=${TEMPORAL_TLS_CERTS_DIR}/cluster/internode/cluster-internode.pem" - - "TEMPORAL_CLI_TLS_KEY=${TEMPORAL_TLS_CERTS_DIR}/cluster/internode/cluster-internode.key" - - "TEMPORAL_CLI_TLS_ENABLE_HOST_VERIFICATION=true" - - "TEMPORAL_CLI_TLS_SERVER_NAME=internode.cluster-x.contoso.com" - "TEMPORAL_ADDRESS=temporal:7233" # used by Temporal CLI - "TEMPORAL_TLS_CA=${TEMPORAL_TLS_CERTS_DIR}/cluster/ca/server-intermediate-ca.pem" - "TEMPORAL_TLS_CERT=${TEMPORAL_TLS_CERTS_DIR}/cluster/internode/cluster-internode.pem" @@ -73,13 +61,6 @@ services: - "${TEMPORAL_LOCAL_CERT_DIR}/client/accounting:${TEMPORAL_TLS_CERTS_DIR}/client/accounting" - "${TEMPORAL_LOCAL_CERT_DIR}/cluster/ca/server-intermediate-ca.pem:${TEMPORAL_TLS_CERTS_DIR}/cluster/ca/server-intermediate-ca.pem" environment: - - "TEMPORAL_CLI_ADDRESS=temporal:7233" # used by tctl. Will be deprecated - - "TEMPORAL_CLI_TLS_CA=${TEMPORAL_TLS_CERTS_DIR}/cluster/ca/server-intermediate-ca.pem" - - "TEMPORAL_CLI_TLS_CERT=${TEMPORAL_TLS_CERTS_DIR}/client/accounting/client-accounting-namespace-chain.pem" - - "TEMPORAL_CLI_TLS_KEY=${TEMPORAL_TLS_CERTS_DIR}/client/accounting/client-accounting-namespace.key" - - "TEMPORAL_CLI_TLS_ENABLE_HOST_VERIFICATION=true" - - "TEMPORAL_CLI_TLS_SERVER_NAME=accounting.cluster-x.contoso.com" - - "TEMPORAL_CLI_NAMESPACE=accounting" - "TEMPORAL_ADDRESS=temporal:7233" # used by Temporal CLI - "TEMPORAL_TLS_CA=${TEMPORAL_TLS_CERTS_DIR}/cluster/ca/server-intermediate-ca.pem" - "TEMPORAL_TLS_CERT=${TEMPORAL_TLS_CERTS_DIR}/client/accounting/client-accounting-namespace-chain.pem" @@ -97,13 +78,6 @@ services: - "${TEMPORAL_LOCAL_CERT_DIR}/client/development:${TEMPORAL_TLS_CERTS_DIR}/client/development" - "${TEMPORAL_LOCAL_CERT_DIR}/cluster/ca/server-intermediate-ca.pem:${TEMPORAL_TLS_CERTS_DIR}/cluster/ca/server-intermediate-ca.pem" environment: - - "TEMPORAL_CLI_ADDRESS=temporal:7233" # used by tctl. Will be deprecated - - "TEMPORAL_CLI_TLS_CA=${TEMPORAL_TLS_CERTS_DIR}/cluster/ca/server-intermediate-ca.pem" - - "TEMPORAL_CLI_TLS_CERT=${TEMPORAL_TLS_CERTS_DIR}/client/development/client-development-namespace-chain.pem" - - "TEMPORAL_CLI_TLS_KEY=${TEMPORAL_TLS_CERTS_DIR}/client/development/client-development-namespace.key" - - "TEMPORAL_CLI_TLS_ENABLE_HOST_VERIFICATION=true" - - "TEMPORAL_CLI_TLS_SERVER_NAME=development.cluster-x.contoso.com" - - "TEMPORAL_CLI_NAMESPACE=development" - "TEMPORAL_ADDRESS=temporal:7233" # used by Temporal CLI - "TEMPORAL_TLS_CA=${TEMPORAL_TLS_CERTS_DIR}/cluster/ca/server-intermediate-ca.pem" - "TEMPORAL_TLS_CERT=${TEMPORAL_TLS_CERTS_DIR}/client/development/client-development-namespace-chain.pem"