Cluster-api-provider-azure: Add managed disk options to data disks

Created on 25 Sep 2020  路  15Comments  路  Source: kubernetes-sigs/cluster-api-provider-azure

/kind feature

Describe the solution you'd like
[A clear and concise description of what you want to happen.]

Support optionally specifying ManagedDisk storage type for data disks https://github.com/kubernetes-sigs/cluster-api-provider-azure/blob/master/api/v1alpha3/types.go#L330:6, reusing the same type as OSDisks https://github.com/kubernetes-sigs/cluster-api-provider-azure/blob/master/api/v1alpha3/types.go#L323.

This is a good end-to-end feature for anyone looking to get familiar with CAPZ, and I'm happy to provide further guidance for anyone who wants to pick it up.

The solution should include:

  • API changes
  • Update to the VM and VMSS services to set the options when creating the VM/VMSS
  • Webhook validation
  • Unit tests
  • Template changes and/or documentation updates (data-disks.md)

Don't know where to start? Search "StorageAccountType" in the codebase to see how it's currently implemented for OS Disks.

/help
/good-first-issue

Anything else you would like to add:
[Miscellaneous information that will assist in solving the issue.]

Environment:

  • cluster-api-provider-azure version:
  • Kubernetes version: (use kubectl version):
  • OS (e.g. from /etc/os-release):
kinfeature

Most helpful comment

Hi @CecileRobertMichon, I am interested in picking up this task. Thanks

All 15 comments

Hi @CecileRobertMichon, I am interested in picking up this task. Thanks

cool, go for it @gdhuper let us know if you have any question

/assign @gdhuper
/remove-help

@gdhuper let me know if you need any help getting started

@gdhuper let me know if you need any help getting started

Thanks @CecileRobertMichon. Random question: Do you know how to update clusterctl's version?

I usually follow the instructions at https://cluster-api.sigs.k8s.io/user/quick-start.html#install-clusterctl to install the latest version and overwrite my installed binary.

Also for dev purposes I highly recommend using Tilt https://github.com/kubernetes-sigs/cluster-api-provider-azure/blob/master/docs/development.md#tilt-for-dev-in-capz instead of clusterctl, it works really well and does hot reload

Also for dev purposes I highly recommend using Tilt https://github.com/kubernetes-sigs/cluster-api-provider-azure/blob/master/docs/development.md#tilt-for-dev-in-capz instead of clusterctl, it works really well and does hot reload

Got it. Thanks

When I try to run clusterctl init --infrastructure a azure or any clusterctl command, I get this error:

Error: unable to verify clusterctl version: unable to write version state file: open /Users/user/.cluster-api/version.yaml: no such file or directory

I followed the installation process couple of times and still get the same error.
OS: Mac OSX

Any suggestions on how to fix this?

@wfernandes pointed out this should have been fixed in newer versions of clusterctl, what version did you install? Try getting the latest, which is 0.3.10

For context and reference, this is the issue https://github.com/kubernetes-sigs/cluster-api/pull/3575

related comment from another PR: https://github.com/kubernetes-sigs/cluster-api-provider-azure/pull/980#discussion_r504662604

"folks probably don't know what are valid strings for the StorageAccountType. Perhaps, it would be good to provide an enum for the StorageAccountType, or provide examples in the comment for the field."

@gdhuper are you still working on this?

@gdhuper are you still working on this?

@CecileRobertMichon Apologies for inactivity on this. I have most of it done but I couldn't get it to completion since I got occupied with my work. If this issue is high priority, feel free to unassign. Otherwise I will be happy to complete this in the next two weeks or so.

@gdhuper let me know if you need any help here. Feel free to open a work in progress PR if you'd like initial feedback.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

voor picture voor  路  6Comments

CecileRobertMichon picture CecileRobertMichon  路  5Comments

zawachte-msft picture zawachte-msft  路  3Comments

alexeldeib picture alexeldeib  路  9Comments

CecileRobertMichon picture CecileRobertMichon  路  7Comments