Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Flatcar Container Linux template #1729

Closed
wants to merge 5 commits into from
Closed

Add Flatcar Container Linux template #1729

wants to merge 5 commits into from

Conversation

jepio
Copy link
Contributor

@jepio jepio commented Sep 24, 2021

What type of PR is this?
/kind other

What this PR does / why we need it:

This PR adds a cluster template for Flatcar Container Linux based clusters.

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Related to #629

Special notes for your reviewer:
The Flatcar cluster template works with images built using this image-builder PR kubernetes-sigs/image-builder#701 and this cluster-api PR kubernetes-sigs/cluster-api#4172.

Please confirm that if this PR changes any image versions, then that's the sole change this PR makes.

No image versions are changed.

TODOs:

  • squashed commits <- single commit
  • includes documentation
  • adds unit tests

Release note:

Flatcar Container Linux is now supported as a cluster flavor. Try `clusterctl generate cluster my-cluster --flavor flatcar`.

@k8s-ci-robot
Copy link
Contributor

@jepio: The label(s) kind/other cannot be applied, because the repository doesn't have them.

In response to this:

What type of PR is this?
/kind other

What this PR does / why we need it:

This PR adds a cluster template for Flatcar Container Linux based clusters.

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Related to #629

Special notes for your reviewer:
The Flatcar cluster template works with images built using this image-builder PR kubernetes-sigs/image-builder#701 and this cluster-api PR kubernetes-sigs/cluster-api#4172.

Please confirm that if this PR changes any image versions, then that's the sole change this PR makes.

TODOs:

  • squashed commits
  • includes documentation
  • adds unit tests

Release note:

Flatcar Container Linux is now supported as a cluster flavor. Try `clusterctl generate cluster my-cluster --flavor flatcar`.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot added the release-note Denotes a PR that will be considered when it comes time to generate release notes. label Sep 24, 2021
@k8s-ci-robot
Copy link
Contributor

Welcome @jepio!

It looks like this is your first PR to kubernetes-sigs/cluster-api-provider-azure 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.

You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.

You can also check if kubernetes-sigs/cluster-api-provider-azure has its own contribution guidelines.

You may want to refer to our testing guide if you run into trouble with your tests not passing.

If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!

Thank you, and welcome to Kubernetes. 😃

@k8s-ci-robot k8s-ci-robot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Sep 24, 2021
@k8s-ci-robot
Copy link
Contributor

Hi @jepio. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
To complete the pull request process, please assign cecilerobertmichon after the PR has been reviewed.
You can assign the PR to them by writing /assign @cecilerobertmichon in a comment when ready.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Sep 24, 2021
@k8s-ci-robot k8s-ci-robot added the area/provider/azure Issues or PRs related to azure provider label Sep 24, 2021
@k8s-ci-robot k8s-ci-robot added sig/cluster-lifecycle Categorizes an issue or PR as relevant to SIG Cluster Lifecycle. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Sep 24, 2021
Copy link
Member

@invidian invidian left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just nits, overall looks good!

templates/flavors/flatcar/machine-deployment.yaml Outdated Show resolved Hide resolved
templates/flavors/flatcar/machine-deployment.yaml Outdated Show resolved Hide resolved
@CecileRobertMichon
Copy link
Contributor

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Sep 27, 2021
@CecileRobertMichon
Copy link
Contributor

Does this require kubernetes-sigs/cluster-api#4172 to merge first?

@invidian
Copy link
Member

invidian commented Sep 28, 2021

Does this require kubernetes-sigs/cluster-api#4172 to merge first?

For functioning correctly, yes, as it's using ignition API field.

@CecileRobertMichon
Copy link
Contributor

/hold

until kubernetes-sigs/cluster-api#4172 is released

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Sep 28, 2021
@invidian
Copy link
Member

invidian commented Dec 9, 2021

CABPK PR kubernetes-sigs/cluster-api#4172 has been merged and will be part of v1.1 release, so we're getting closer getting this as well 🎉

@jepio
Copy link
Contributor Author

jepio commented Dec 10, 2021

Updated the apiversion from alpha4 to beta1, and rebased. I also tested that the template continues to work with the ignition support merged to CAPI and it does 👍

@invidian
Copy link
Member

I wonder, CAPI v1.1 RC release should be happening soon. I wonder if we can update CAPA main manifests to use it, so this PR could be merged.

@CecileRobertMichon
Copy link
Contributor

I wonder, CAPI v1.1 RC release should be happening soon. I wonder if we can update CAPA main manifests to use it, so this PR could be merged.

Do you mean CAPZ? We are about to release CAPZ v1.1 so I don't want to merge this until CAPI release happens (in January) so we don't end up releasing a flavor that doesn't work.

@invidian
Copy link
Member

I was thinking about updating

- name: v1.0.2
value: https://github.com/kubernetes-sigs/cluster-api/releases/download/v1.0.2/bootstrap-components.yaml
to CAPBK v1.1 rc1 release as an intermediate step before CAPBK v1.1 gets released, so we could merge this PR then.

@CecileRobertMichon
Copy link
Contributor

#1951 just merged which means this should now work

how do we test this template to make sure it doesn't regress?

@CecileRobertMichon
Copy link
Contributor

@invidian would it be easier/better to extract the community gallery support to a separate PR? If so, feel free to do so.

@invidian
Copy link
Member

invidian commented May 2, 2022

@invidian would it be easier/better to extract the community gallery support to a separate PR? If so, feel free to do so.

Here the community gallery has e2e tests with it, but on the other hand this PR may still take a bit before merging, as we need to do final cleanups with the used images. Will open separate PR.

@invidian
Copy link
Member

invidian commented May 2, 2022

Opened #2277 then.

@invidian
Copy link
Member

invidian commented May 9, 2022

/retest

pull-cluster-api-provider-azure-e2e and pull-cluster-api-provider-azure-ci-entrypoint seems like a flake, pull-cluster-api-provider-azure-apidiff is expected to be failing as I indeed made an incompatible change on Go level to the type.

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 4, 2022
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 16, 2022
@invidian
Copy link
Member

I will be working on flatcar/Flatcar#734 to get the community gallery out with some images we can use here. I think that's the last requirement missing for this PR 😅

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 21, 2022
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jul 5, 2022
@invidian
Copy link
Member

invidian commented Jul 5, 2022

/retest

Flatcar test has failed as I forgot to replicate new image to all regions used by CI. Should be fixed now.

@invidian
Copy link
Member

invidian commented Jul 5, 2022

/retest

Flatcar tests are passing again, but let's try making it green.

jepio and others added 4 commits July 12, 2022 20:42
This template allows deploying workload clusters based on Flatcar Container
Linux image-builder images. The adjustments compared to
cluster-template.yaml are:

 * ignition does not support using jinja templating to inject hostname
   into kubeadm.yaml so we need to use a preKubeadmCommand. We also need
   a systemd drop-in to ensure proper service ordering when fetching the
   hostname (after oem-cloudinit.service)

  * MachineTemplate needs to include a sharedGallery based image with
    plan information. The parameters in the template are the values used
    by image-builder when running:

      make -C images/capi FLATCAR_VERSION=2905.2.3 GALLERY_NAME=ClusterAPI build-azure-sig-flatcar

    The version field can be 'latest' or a fixed version.

  * drop 'tableType: gpt' in partition spec as Flatcar doesn't support
    anything else

  * drop 'ephemeral0.1' disk entry as that is an internal cloud-init
    alias. Temporary storage is automatically configured on Flatcar.

  * mounts reference labels specified in 'fileSystems' section, and
    don't use fstab syntax

Based-on-work-by: Mateusz Gozdek <[email protected]>
Signed-off-by: Jeremi Piotrowski <[email protected]>
@invidian
Copy link
Member

/test pull-cluster-api-provider-azure-e2e-optional

Trying out using gen 2 images but I hit some issues with wrong SKU and missing replication region for an image. Hopefully it will pass now.

Signed-off-by: Mateusz Gozdek <[email protected]>
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue or PR as fresh with /remove-lifecycle stale
  • Mark this issue or PR as rotten with /lifecycle rotten
  • Close this issue or PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Oct 11, 2022
@invidian
Copy link
Member

/remove-lifecycle stale

@k8s-ci-robot k8s-ci-robot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Oct 11, 2022
@CecileRobertMichon
Copy link
Contributor

/close

Doing some PR queue cleanup 🧹, please feel free to reopen when this is ready for review

@k8s-ci-robot
Copy link
Contributor

@CecileRobertMichon: Closed this PR.

In response to this:

/close

Doing some PR queue cleanup 🧹, please feel free to reopen when this is ready for review

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@invidian invidian deleted the jepio/cluster-template-flatcar branch January 23, 2023 22:24
@invidian
Copy link
Member

#2890 is now merged :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/provider/azure Issues or PRs related to azure provider cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. release-note Denotes a PR that will be considered when it comes time to generate release notes. sig/cluster-lifecycle Categorizes an issue or PR as relevant to SIG Cluster Lifecycle. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants