This patch allows to wait for certain state when applying
particular resources.
Change-Id: I064cb49c8971f1edee870bc6c3c3dd1e428c73f0
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Closes: #624
Currently, there is no way to specify poll interval for
kubernetes-apply phases, however such possibility exists
in cli-utils API and could be helpful for tuning apply
process.
Change-Id: I605767d589920d0f1e10343afd9672c8d615a46a
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Currently zero timeout won't be applied if specified via CLI
options of commands plan run and plan run. This patch fixes it.
Change-Id: Icad06ae8c71d78dc81821e2c5b0adb486d547fda
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Relates-To: #566
Closes: #566
This PS replaces cluster-api implementation with our own since
it allows to configure timeout.
Change-Id: I5cbba24dd7c6a279fcd2325e904ac7d18348eabf
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Relates-To: #548
Closes: #548
* validation config is now part of airshipctl api
* additional CRD locations can be only kustomize entrypoints
* changed mechanism to call document-validation executor to allow
to pass validation config from phase or plan
* kubeval version pinned to the latest 0.16.1
* default k8s version to validate against uplifted to 1.18.6
* default URL with k8s schemas changed to more updated and reliable
Change-Id: Ifb24be224d5f0860d323a671b94e28a86debc65b
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Closes: #563
* Define GVK for metadata.yaml
* Added supoorting type and registered the kind 'AirshipMetadata' to
runtime scheme
* Used document object to read metadata instead of reading it as config
Relates-To: #530
Change-Id: I748cd0921ba7bb04ca6fb2999294776e6803ed3e
Removed the namespace condition check from the validation of 'Move'.
This is to allow validation of docker and cloud provider test site
manifests that do not use namespace.
Relates-To: #503
Change-Id: I39544ba9c9c13ff5a6519b7afd8844629e60087e
This patchset introduces new field to Phase.Config API object
SiteWideKubeconfig - if set to true, the phase will have access
to all kubeconfigs for each cluster defined in ClusterMap.
By default only kubeconfig of the cluster specified in
Phase.Metadata.ClusterName will be available to the phase executor.
This approach will speed up the deployment process because arishipctl
will not have to look for multiple kubeconfigs when running each phase
Closes: #547
Change-Id: Ic92027ba88d3ce8cb769c254968530037540b8fd
This patch will allow us to bypass unnecassary logic in generic
container executor (e.g. mounting kubeconfig).
Change-Id: I526940e8f01c66f7609355a4ef750b38f1d9a323
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
This will fix a bug, when go routine wasn't finished when program has
exited. Results of the bug was that not all defered statemnets were
executed, which lead to temp kubeconfig not being cleaned up
Relates-To: #541
Closes: #541
Change-Id: If314886d9bed04b2c0f8a5006bc058395f4fdf7a
Added yaml output flag to show plan list in yaml format
Relates-To: #394
Co-authored By: Niharika Bhavaraju<niha.twinkle@gmail.com>
Change-Id: I8bed077573eb79783cfc77e4ebf82c819f41d125
This patch introduces ability to validate phases using kubeval.
Appropriate functionality was embedded into phase/plan validate
command.
Change-Id: I1e1ccae2b7e4948bdc97a199c96c07a3eb7292b2
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Relates-To: #503
Closes: #2
Closes: #19
Phase helper provides plenty of useful methods for
a phase client. But these methods are not used by
phase executor initializers except for getting some
configuration values. So, it is better to provide
initializers with necessary values instead of passing
them the phase helper.
Change-Id: I8c596455e30444570a86efad73d792af0ca83a33
Relates-To: #464
Relates-To: #465
The aim of this PS to fix current issue we have when we have
new plan created with description width more than 40 char.
Added condition if width is more than specified in command
so the command execution will not break and just crop
exceeding description length.
Eg: e351b2bc43/pkg/print/table/columndefs.go (L71)
Change-Id: Icc353ec688b2fbb563add39f8d38004008093895
Currently it returns NotImplemented error, and that's not
correct behavior. Since this kind of executor has the bundle
inside, it should be properly rendered.
Change-Id: I4c4e417b064236130b4349560fa3eb2615a0f824
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
AirshipConfig and BundleName fields are not used within Executors,
so they should be removed.
Change-Id: I23c54b854938ae554e888102a41c7ec215b85c27
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
This patch implements CLI command to invoke plan validation.
Appropriate functionality was already added to pkg previously.
Change-Id: I038b49c8de0af65f38b62950b27b31d95a6301a9
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Relates-To: #19
Relates-To: #497
Closes: #497
Since document.NewBundleByPath() is pretty resource and time
consuming call (because it invokes kustomize under the hood),
we should avoid unnecessary calls of this function. There are
lots of the same constructor calls of new bundle from phase
bundle root path, mostly in helper, which slows airshipctl
and makes no sense. This patch fixes this problem by storing
phase root bundle variable in helper, which creates only once
during airshipctl execution.
Change-Id: I6b59d440f7ab7a68dc613091dafcc9e82df10eb7
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Closes: #488
Since this field is no longer actually used, there is need to
remove it completely.
Change-Id: I9f7002f8def31d1660919bd0128707e43a57ad71
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
This patch allow to specify relative and home (~/) path for container
mounts.src field. In case if specified path is not absolute, it will be
created by following pattern: 'targetPath+mounts.src'; in case if path
contains ~/ - it will be properly expanded (it will allow us to mount
~/.airship working directory).
Change-Id: I878094371a2bc4e48216b1d076e466e3d29a86f6
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Relates-To: #484
Closes: #484
* Phase list command lists phases of current documentset/plan in
table or yaml format.
airshipctl phase list
airshipctl phase list --plan planName
airshipctl phase list --plan planName -o yaml
airshipctl phase list --plan planName -o table(default format)
Relates-To: #358
Co-Authored-By: Niharika Bhavaraju <niha.twinkle@gmail.com>
Change-Id: I37add2fc9dca2433de525bac8c2cc9e56fe39621