Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This provides support for clusterctl in two ways.
First, it properly structures it so you can run
clusterctl --config=...
to initialize the Packet provider. It did work before, but there were elements missing. This completes it so that it works. As part of it, it needed to change some of how the templates are generated to./out/
.Second, it adds support for the cluster template in the right directories in
./out/
. This means thatgenerate-example.sh
is no longer relevant, although it uses the same source template. This now is pushed into the correct./out/
directories, whereclusterctl
can consume them.Since
clusterctl config cluster
does not (yet) support defaults - every env var must be set for it to work - this repurposesgenerate-example.sh
togenerate-cluster.sh
, which wrapsclusterctl
but sets defaults for env vars that should support them (as it did before when it wasgenerate-example.sh
). Also moved that to./scripts/
to keep it clean and consistent.Other things had to be improved to make it work, for example adding the correct
Secret
to run the manager as part ofmake release
(it isn't needed inmanagerless
, since we run it locally).All of the docs relating to it have been updated as well, as have Makefile targets.
There are a few things that still do not work or require fixing once this PR is in, but should be handled as separate steps.
PACKET_API_KEY
as part of its template, so that the CCM deployment will work correctly. Cluster templates are not supposed to have secrets. Even though we had it in v1alpha1, and this is a carryover, this requires us to clean it up. We need to find a way to get the secret across from the initializer in the management cluster. I have some ideas; we can follow through later.clusterctl --config=
command - both in the README and inmake cluster
- does not work because it references the URL https://github.com/packethost/cluster-api-provider-packet/releases/latest/`, but we haven't actually released the config file there yet. That will continue to be the case until we cut a release.