Skip to content

Commit d248a02

Browse files
authored
Merge pull request #1076 from camilamacedo86/1031
doc(quick-start) : improvements
2 parents ec2c14c + 29cefed commit d248a02

File tree

2 files changed

+19
-6
lines changed

2 files changed

+19
-6
lines changed

docs/book/src/quick-start.md

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -41,17 +41,20 @@ Also, you can install a master snapshot from `https://go.kubebuilder.io/dl/lates
4141

4242
## Create a Project
4343

44-
Create a directory, and then run the following command inside of it to initialize a new project:
44+
Create a directory, and then run the init command inside of it to initialize a new project. Follows an example.
4545

4646
```bash
47-
kubebuilder init --domain my.domain
47+
$ mkdir $GOPATH/src/example
48+
$ cd $GOPATH/src/example
49+
$ kubebuilder init --domain my.domain
4850
```
4951

5052
<aside class="note">
5153
<h1>Not in $GOPATH</h1>
5254

53-
If you're not in `GOPATH`, you'll need to run `go mod init <modulename>`
54-
in order to tell kubebuilder and Go the base import path of your module.
55+
If you're not in `GOPATH`, you'll need to run `go mod init <modulename>` in order to tell kubebuilder and Go the base import path of your module.
56+
57+
For a further understanding of `GOPATH` see [The GOPATH environment variable][GOPATH-golang-docs] in the [How to Write Go Code][how-to-write-go-code-golang-docs] golang page doc.
5558

5659
</aside>
5760

@@ -193,6 +196,11 @@ privileges or be logged in as admin. See [Prerequisites for using Kubernetes RBA
193196

194197
</aside>
195198

196-
Now, follow up the tutorial for you understanding better how it works and check an full example project working.
199+
## Next Step
200+
201+
Now, follow up the CronJob tutorial[cronjob-tutorial] to better understand how it works by developing a demo example project.
197202

198-
[pre-rbc-gke]:https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control#iam-rolebinding-bootstrap
203+
[pre-rbc-gke]:https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control#iam-rolebinding-bootstrap
204+
[cronjob-tutorial]: ../src/cronjob-tutorial/cronjob-tutorial.md
205+
[GOPATH-golang-docs]: https://golang.org/doc/code.html#GOPATH
206+
[how-to-write-go-code-golang-docs]: https://golang.org/doc/code.html

pkg/scaffold/v2/webhook/webhook.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,11 @@ func (a *Webhook) GetInput() (input.Input, error) {
8080
return a.Input, nil
8181
}
8282

83+
// Validate validates the values
84+
func (g *Webhook) Validate() error {
85+
return g.Resource.Validate()
86+
}
87+
8388
var (
8489
WebhookTemplate = `{{ .Boilerplate }}
8590

0 commit comments

Comments
 (0)