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>
* modified image_repositories section schema in version catalogue.
new type : type map[string]ImageRepositorySpec
old type : string.
* replaced registry attribute in Installation resource from
version-catalogue image_repositories section.
* updated old attributes from image_repositories section as per new
schema.
Closes: #590
Change-Id: I2159e23b8a63b5f48d2f4e79b56c2bc021646c77
'make manifests' attempts to generate all airshipctl API types,
but several types throw errors and the resulting CRDs can't be
properly generated. This change:
- updates the controller-gen version to pull in a bug fix for the
error 'map values must be a named type, not *ast.StarExpr'
- modifies the Templater type's Values member to be of type JSON
since controller-gen does not support map[string]interface{},
and unmarshals it separately in the templater itself
- adds 'image_repositories' to the VersionsCatalogueSpec struct
to ensure it doesn't get deleted from the schema when manifests
get regenerated
- checks in generated copies of all CRDs from airshipctl's API
types, not just catalogues, to be used for validation
Closes: #574
Change-Id: I89a12cfd307a08da9aaec9773eac01169ea43ace
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
Adds an ntp object to the NetworkCatalogue schema
and populates default ntp servers into the networking
base catalogue. Also adds replacement rules in:
* function/k8scontrol/replacements
* function/workers-capm3/replacements
Change-Id: I5dedda563c8825c283e7ba846bedb0b282459d41
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
* Generate VersionsCatalogue and NetworkCatalogue schemas using kubebuilder
* Schema for CRDs can be generated with this command
=> make manifests
Change-Id: I61695d523ee0c08739f15a47b2cf8653d925b108
Closes: #532
- Use opendev.org/airship/airshipctl/pkg/document.Selector
instead of sigs.k8s.io/kustomize/api/types.Selector
which makes selectors conversion code unnecessary
- Use document.GetSecretDataKey instead of
document.DecodeSecretData which removes code duplicates
Change-Id: Ie2c6b8d8222b7acb1b657f8d786a8c3a06b0c6fd
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
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
Change ClusterMap API object to support multiple kubeconfig sources
for a cluster. If one kubeconfig source fails, kubeconfig builder
will not fail and move on to the next one. This behaviour will allow
to support cases when ephemeral cluster is not accesible anymore or
when target cluster is not yet accessible.
For more information please read issue #460 in airshipctl github
Relates-To: #460
Related-To: #460
Change-Id: I7cd32f78cd7c4ad8814eac357424c24216f40d76
We build iso image in two steps
1) We prepare cloud-init data using a krm function
krm-functions/cloud-init which uses arishipctl capabilities
to gather necessary data from the executor document bundle.
Cloud-init data files are written into a directory mounted
to the krm function container.
2) We build iso image using image-builder. While doing this
we mount the directory with cloud-init data files and set
necessary environment variables defined in the executor
document.
Relates-To: #440
Change-Id: Id0b34822e95f494d2e2f8fb407700b7f873e7c69
Now GenericContainer input config can be referenced as another
object inside the config bundle (with phase and executor objects).
Change-Id: Iff35e0844b1e9ce4beb72d939e229410208dcb16
This also moves KRM related logic from executors package to
container package, and creates ClientV1Alpha1 interface that
would allow us to have versioned clients for generic container
executor.
Change-Id: I4b32fd8dd089b9ccea2ed64a805702e6a8705706
Sink function allows to write configurations to an external system.
Change-Id: If9c6904239a542ea4c2bef2920965b6d87feb1e6
Relates-To: #202
Relates-To: #369
This patchset includes the go code for the Executor for the Bootstrap
container/Ephemeral cluster and respective unit test code.
This executor allows to deploy a K8S cluster on a public/private cloud
provider through a dedicated Bootstrap container.
This patchset does not include the manifests for the executor to avoid
too big patchset. It will be included in a different patchset.
Change-Id: I3f9d2ba1bb65b344522e105fd26310af24e3a1b1
This introduces airshipctl integration with image-builder [0], which
replaces the existing isogen tool for ephemeral ISO generation.
The airshipctl isogen executor has been updated for building ephemeral
ISOs using the image-builder container. The ability for user-declared
filenames for cloud-init user data and network data was removed, since
the user's only interest is in supplying the relevant overrides, not in
transparent naming coordination with the image-builder container. A new
object is added to the document package to identify the document kind,
label, and key to retrieve data from since this is pattern we will
reuse elsewhere.
Progress flag removed as requsted. Progress is reported directly by the
image-builder container.
Isogen debug flag removed in favor of using log.DebugEnabled()
[0] https://review.opendev.org/#/c/730777/
Depends-On: https://review.opendev.org/c/airship/images/+/730777/
Change-Id: I545004feaf2116f8ffb29faf6f7f7f5fcfe24fff
* Images added to clusterctl object like Providers
So that repository and tag for one or all of the cert-manager
components can be overriden using patch/replacement
clusterctl Documentation for Image Override:
https://cluster-api.sigs.k8s.io/clusterctl/configuration.html#image-overrides
Change-Id: Id9de8d1967e49aeb3293f6802e51d66d598333ae
Closes: #350
This commit will add clusterapi name and namespaces with a given cluster
to a clustermap.
Refer code from this PS: https://review.opendev.org/#/c/759805/
Change-Id: I1937efa0bbf0b5b175d18777fdf4ba837d1d7344
Relates-To: #376
Closes: #376
This commit extends cluster map interface to be able to specify
a custom kubeconfig context per cluster in ClusterMap
Related-To: #380
Related-To: #375
Closes: #380
Change-Id: I9a8a26e3a3666e069c243e871f89ae9222228f17
Adding BootConfiguration structure in preparation for the implementation
of Bootstrap Container / Ephemeral Cluster through "phase/executor".
Change-Id: I0239e9c975784703dd6abacbb17b5e15744f3924