terrakube
terrakube copied to clipboard
Ephemeral Job Agent
Feature description 💡
Right now Terrakube can have multiple executor "agents" to execute the jobs from different organizations as explain in this link and in this pull request #770 and #772
It could be a good idea to have a feature that allows to create an "Ephemeral Agent" that is created/deleted when running an specific job like instead of having a long running "executor" component running all the time
Anything else?
No response
The following could help with the implementation
Gaia code did something similar, maybe we could reuse it with Kubernetes and Docker.
https://github.com/gaia-app/runner/blob/0606e2a37169f7b9861a51c0b967908df7dccd8f/src/main/java/io/gaia_app/runner/k8s/K8SExecutor.java#L43
https://github.com/gaia-app/runner/blob/0606e2a37169f7b9861a51c0b967908df7dccd8f/src/main/java/io/gaia_app/runner/docker/DockerExecutor.java#L42
This feature can be tested using the following in the helm chart:
api:
image: "azbuilder/api-server"
version: "2.22.0-beta.5"
serviceAccountName: "terrakube-api-service-account"
env:
- name: ExecutorEphemeralNamespace
value: terrakube
- name: ExecutorEphemeralImage
value: azbuilder/executor:2.22.0-beta.5
- name: ExecutorEphemeralSecret
value: terrakube-executor-secrets
More information can be found here:
https://github.com/AzBuilder/terrakube/pull/1044
The documentation can be found here:
https://docs.terrakube.io/getting-started/deployment/ephemeral-agents