https://github.com/realkinetic/exec-model-example
An example on how to perform exec from one pod to another
https://github.com/realkinetic/exec-model-example
Last synced: about 1 year ago
JSON representation
An example on how to perform exec from one pod to another
- Host: GitHub
- URL: https://github.com/realkinetic/exec-model-example
- Owner: RealKinetic
- Created: 2019-03-13T13:24:59.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2022-12-08T04:52:04.000Z (over 3 years ago)
- Last Synced: 2024-03-27T01:04:12.139Z (over 2 years ago)
- Language: Python
- Size: 11.7 KB
- Stars: 0
- Watchers: 1
- Forks: 1
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Exec model example for Kubernetes
=================================
This repo provides a demonstration of an operator pod execing into a list of
workload pods all running in the same namespace.
The ``/runme.sh`` is called in non-interactive mode in the workload pod from
the operator pod using the kubernetes api.
Running the demo
----------------
Install/run [minikube](https://kubernetes.io/docs/tasks/tools/install-minikube/).
I am using kubernetes v1.13.2.
Install [skaffold](https://skaffold.dev/). I am using version v0.24.0.
In the root folder of this repo, run ``skaffold dev``.
After the containers are built locally, you should see output similar to the following:
```bash
[operator-74f58497f8-84wqr exec-operator] starting loop ..
[operator-74f58497f8-84wqr exec-operator] Execing into workload-9bc876ddf-ws6c5 ..
[operator-74f58497f8-84wqr exec-operator] workload-9bc876ddf-ws6c5: like a baws!
[operator-74f58497f8-84wqr exec-operator]
[operator-74f58497f8-84wqr exec-operator] finished loop.
```