Skip to content

Conversation

@davdhacs
Copy link
Contributor

When we close or merge a PR to infra, should we automatically delete the PR dev cluster and any created child clusters?

@davdhacs davdhacs requested a review from a team as a code owner March 24, 2025 18:18
@davdhacs
Copy link
Contributor Author

to test this, I'll wait for the PR dev cluster to be created and then create some failed and good child clusters and then close the pr (I think that will trigger this workflow). If it works, I can re-open the PR.

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 24, 2025

  A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.
  
  CI will attempt to deploy `quay.io/rhacs-eng/infra-server:0.11.7-18-g89955d8523` to it.
  
  :electric_plug: You can **connect** to this cluster with:
  ```
  gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev
  ```
  
  :hammer_and_wrench: And pull **infractl** from the deployed dev infra-server with:
  ```
  nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
  make pull-infractl-from-dev-server
  ```
  
  :bike: You can then **use** the dev infra instance e.g.:
  ```
  bin/infractl -k -e localhost:8443 whoami
  ```
  
  :warning: ***Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted.*** :warning:
  
  ### Further Development
  
  :coffee: If you make changes, you can commit and push and CI will take care of updating the development cluster.
  
  :rocket: If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:
  
  ```
  make helm-deploy
  ```
  
  ### Logs
  
  Logs for the development infra depending on your @redhat.com authuser:
  - [authuser=0](https://console.cloud.google.com/logs/query;query=resource.labels.cluster_name%3D%22infra-pr-1537%22%0Aresource.labels.container_name%3D%22infra-server%22?project=acs-team-temp-dev&authuser=0)
  - [authuser=1](https://console.cloud.google.com/logs/query;query=resource.labels.cluster_name%3D%22infra-pr-1537%22%0Aresource.labels.container_name%3D%22infra-server%22?project=acs-team-temp-dev&authuser=1)
  - [authuser=2](https://console.cloud.google.com/logs/query;query=resource.labels.cluster_name%3D%22infra-pr-1537%22%0Aresource.labels.container_name%3D%22infra-server%22?project=acs-team-temp-dev&authuser=2)
  
  Or:
  ```
  kubectl -n infra logs -l app=infra-server --tail=1 -f
  ```

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 24, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.7-20-gd475831186 to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

to be removed in #1524
@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 24, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.7-21-gc2b543a68d to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 25, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.7-25-g909ecc019c to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

@davdhacs
Copy link
Contributor Author

to test this, I'll wait for the PR dev cluster to be created and then create some failed and good child clusters and then close the pr (I think that will trigger this workflow). If it works, I can re-open the PR.

on second thought, this will not trigger on the close action because it is not in master yet. I'll have to test it by changing to an active pr trigger

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 25, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.7-28-g52f1a9b13c to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 25, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.7-29-gec144c76ea to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 25, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.7-30-g3718739cf2 to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 25, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.7-31-gaab4074633 to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 25, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.7-32-g9f123186da to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 25, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.7-33-gccc1e6e197 to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 25, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.7-34-g947b1f52c7 to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

@rhacs-bot
Copy link
Contributor

Deployment to development cluster completed.

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 25, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.9-37-gc71913d3bf to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

@davdhacs
Copy link
Contributor Author

This works, but maybe it is better to just leave it as-is and allow the dev clusters to clean up child clusters as they expire and itself expire in the prod Infra.

Removing the roxci test container layer and switching to standard gh comment instead of using the hub-comment could be nice improvements however.

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 26, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.9-38-g8af088be39 to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

@rhacs-bot
Copy link
Contributor

Deployment to development cluster completed.

@rhacs-bot
Copy link
Contributor

rhacs-bot commented Mar 27, 2025

A single node development cluster (infra-pr-1537) was allocated in production infra for this PR.

CI will attempt to deploy quay.io/rhacs-eng/infra-server:0.11.9-39-g322fcf8ba5 to it.

🔌 You can connect to this cluster with:

gcloud container clusters get-credentials infra-pr-1537 --zone us-central1-a --project acs-team-temp-dev

🛠️ And pull infractl from the deployed dev infra-server with:

nohup kubectl -n infra port-forward svc/infra-server-service 8443:8443 &
make pull-infractl-from-dev-server

🚲 You can then use the dev infra instance e.g.:

bin/infractl -k -e localhost:8443 whoami

⚠️ Any clusters that you start using your dev infra instance should have a lifespan shorter then the development cluster instance. Otherwise they will not be destroyed when the dev infra instance ceases to exist when the development cluster is deleted. ⚠️

Further Development

☕ If you make changes, you can commit and push and CI will take care of updating the development cluster.

🚀 If you only modify configuration (chart/infra-server/configuration) or templates (chart/infra-server/{static,templates}), you can get a faster update with:

make helm-deploy

Logs

Logs for the development infra depending on your @redhat.com authuser:

Or:

kubectl -n infra logs -l app=infra-server --tail=1 -f

@rhacs-bot
Copy link
Contributor

Deployment to development cluster completed.

@rhacs-bot
Copy link
Contributor

Development cluster deleted.

@davdhacs davdhacs closed this Mar 27, 2025
@rhacs-bot
Copy link
Contributor

Development cluster deleted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants