d588c73e38
The wrapper is called ApplyAdapter and is a struct, that has Apply(..) method and some setters that allow to control kubectl apply behaviour Addapter is expected to be used through Apply(..) function, which takes slice of document.Document interface objects, writes them out to temporary file system, from where they are picked up by kubectl Apply module, and delivered to kubernetes cluster. The decision to use temporary file system is based on the fact, that in current state kubectl project currently only works with actual files, and ignores io.Streams object, that is part of ApplyOptions struct, so it is currently the only way to use it. Change-Id: Idc5d79794149c00198f420d76cf9aa3b5264946e
23 lines
414 B
YAML
23 lines
414 B
YAML
apiVersion: v1
|
|
kind: ReplicationController
|
|
metadata:
|
|
name: test-rc
|
|
namespace: test
|
|
annotations:
|
|
airshipit.org/initinfra: "workflow"
|
|
labels:
|
|
name: test-rc
|
|
airshipit.org/initinfra: "workflow"
|
|
spec:
|
|
replicas: 1
|
|
template:
|
|
metadata:
|
|
labels:
|
|
name: test-rc
|
|
spec:
|
|
containers:
|
|
- name: test-rc
|
|
image: nginx
|
|
ports:
|
|
- containerPort: 80
|