kubernetes-sigs / cluster-api-provider-ibmcloud

Cluster API Provider for IBM Cloud
https://cluster-api-ibmcloud.sigs.k8s.io
Apache License 2.0
63 stars 77 forks source link

Enhance linting to cover yaml files #1497

Open Prajyot-Parab opened 10 months ago

Prajyot-Parab commented 10 months ago

/kind bug /area provider/ibmcloud

What steps did you take and what happened:

What did you expect to happen:

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

Environment:

Prajyot-Parab commented 10 months ago

/good-first-issue

k8s-ci-robot commented 10 months ago

@Prajyot-Parab: This request has been marked as suitable for new contributors.

Guidelines

Please ensure that the issue body includes answers to the following questions:

For more details on the requirements of such an issue, please see here and ensure that they are met.

If this request no longer meets these requirements, the label can be removed by commenting with the /remove-good-first-issue command.

In response to [this](https://github.com/kubernetes-sigs/cluster-api-provider-ibmcloud/issues/1497): >/good-first-issue Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.
yuanning6 commented 9 months ago

/assign @yuanning6

I'd love to help fix this issue! Can I get some guide about where to start?

Prajyot-Parab commented 9 months ago

@yuanning6 You can start by checking the other linters we have - https://github.com/kubernetes-sigs/cluster-api-provider-ibmcloud/blob/main/.golangci.yml

can run make lint target to see the behavior

we want to do same thing for yaml files to avoid issues such as https://github.com/kubernetes-sigs/cluster-api-provider-ibmcloud/commit/7cd7fcc1c0448df9caae393fa63720a874b36c85

yuanning6 commented 9 months ago

@Prajyot-Parab Thank you so much for your guidance!

I found yamllint is a popular tool to lint yaml files, can I start with this? And should I make the lint rules very strict or kind of loose?

Prajyot-Parab commented 9 months ago

@Prajyot-Parab Thank you so much for your guidance!

I found yamllint is a popular tool to lint yaml files, can I start with this? And should I make the lint rules very strict or kind of loose?

Yes you can start with whatever is the relevant tool, lets start with loose rules and we will make them stricter going ahead as and when required.

yuanning6 commented 9 months ago

@Prajyot-Parab Sure! I did some implementations and made a PR https://github.com/kubernetes-sigs/cluster-api-provider-ibmcloud/pull/1521, it's just for you to have an overview and see if I'm on the right direction. Please let me know any changes I should make!

Prajyot-Parab commented 9 months ago

@Prajyot-Parab Sure! I did some implementations and made a PR #1521, it's just for you to have an overview and see if I'm on the right direction. Please let me know any changes I should make!

I will take a look at this today, thanks!

yuanning6 commented 9 months ago

@Prajyot-Parab Sure! I did some implementations and made a PR #1521, it's just for you to have an overview and see if I'm on the right direction. Please let me know any changes I should make!

I will take a look at this today, thanks!

Thank you! :))