Skip to content

Commit 4b1a28d

Browse files
authored
Merge pull request #2703 from robscott/devguide-cleanup
Cleaning up Dev Guide, moving Docs Style Guide
2 parents 10e5f19 + b9422d3 commit 4b1a28d

File tree

3 files changed

+55
-77
lines changed

3 files changed

+55
-77
lines changed

mkdocs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,6 @@ nav:
9595
- API Design: guides/api-design.md
9696
- CRD Management: guides/crd-management.md
9797
- Implementer's Guide: guides/implementers.md
98-
- Documentation Style Guide: guides/documentation.md
9998
- Reference:
10099
- API Types:
101100
- Gateway: api-types/gateway.md
@@ -151,5 +150,6 @@ nav:
151150
- Contributing:
152151
- How to Get Involved: contributing/index.md
153152
- Developer Guide: contributing/devguide.md
153+
- Documentation Style Guide: contributing/style-guide.md
154154
- Enhancement Requests: contributing/enhancement-requests.md
155155
- Contributor Ladder: contributing/contributor-ladder.md

site-src/contributing/devguide.md

Lines changed: 54 additions & 76 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,8 @@
1-
<!--
2-
Copyright 2019 The Kubernetes Authors.
3-
4-
Licensed under the Apache License, Version 2.0 (the "License");
5-
you may not use this file except in compliance with the License.
6-
You may obtain a copy of the License at
7-
8-
http://www.apache.org/licenses/LICENSE-2.0
9-
10-
Unless required by applicable law or agreed to in writing, software
11-
distributed under the License is distributed on an "AS IS" BASIS,
12-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13-
See the License for the specific language governing permissions and
14-
limitations under the License.
15-
-->
16-
17-
## Developing Gateway API
18-
19-
You must have a working [Go environment] and then clone the repo:
20-
21-
```
22-
mkdir -p $GOPATH/src/sigs.k8s.io
23-
cd $GOPATH/src/sigs.k8s.io
24-
git clone https://github.com/kubernetes-sigs/gateway-api
25-
cd gateway-api
26-
```
27-
28-
This project works with Go modules; you can chose to setup your environment
29-
outside $GOPATH as well.
30-
31-
# Building, testing and deploying
32-
33-
You will need to have Docker installed to perform the steps below.
1+
# Dev Guide
342

353
## Project management
364

37-
We are using the Github issues and project dashboard to manage the list of TODOs
5+
We are using the GitHub issues and project dashboard to manage the list of TODOs
386
for this project:
397

408
* [Open issues][gh-issues]
@@ -63,46 +31,58 @@ command in PR and issue comments][issue-cmds]. For example,
6331
[prio-labels]:https://github.com/kubernetes-sigs/gateway-api/labels?q=priority
6432
[issue-cmds]:https://prow.k8s.io/command-help?repo=kubernetes-sigs%2Fgateway-api
6533

66-
## Building the code
34+
## Prerequisites
6735

68-
The project uses `make` to drive the build.
69-
`make` will run code generators, and run static analysis against the code and
70-
generate Kubernetes CRDs.
71-
You can kick off an overall build from the top-level makefile:
36+
Before you start developing with Gateway API, we'd recommend having the
37+
following prerequisites installed:
7238

73-
```shell
74-
make
75-
```
39+
* [Go](https://golang.org/doc/install)
40+
* [Kubectl](https://kubernetes.io/docs/tasks/tools/#kubectl)
41+
* [Kind](https://kubernetes.io/docs/tasks/tools/#kind)
7642

77-
## Adding Experimental Fields
43+
Note that Kind and many of our build tasks also have a dependency on Docker or
44+
Podman.
7845

79-
Starting with v0.5.0, all additions to the API must start in the experimental
80-
release channel. Experimental fields must be marked with the
81-
`<gateway:experimental>` annotation in Go type definitions. Gateway API CRD
82-
generation will only include these fields in the experimental set of CRDs.
46+
### Building, testing and deploying
8347

84-
If experimental fields are removed or renamed, the original field name should be
85-
removed from the go struct, with a tombstone comment
86-
([example](https://github.com/kubernetes/kubernetes/blob/707b8b6efd1691b84095c9f995f2c259244e276c/staging/src/k8s.io/api/core/v1/types.go#L4444-L4445))
87-
ensuring the field name will not be reused.
48+
Clone the repo:
49+
50+
```
51+
mkdir -p $GOPATH/src/sigs.k8s.io
52+
cd $GOPATH/src/sigs.k8s.io
53+
git clone https://github.com/kubernetes-sigs/gateway-api
54+
cd gateway-api
55+
```
56+
57+
This project works with Go modules; you can chose to setup your environment
58+
outside $GOPATH as well.
8859

89-
## Install CRDs
60+
### Building the code
9061

91-
To install gateway-api CRDs into a Kubernetes cluster:
62+
The project uses `make` to drive the build. `make` will run code generators, and
63+
run static analysis against the code and generate Kubernetes CRDs. You can kick
64+
off an overall build from the top-level makefile:
9265

9366
```shell
94-
make install
67+
make generate
9568
```
9669

97-
To uninstall CRDs and associated resources:
70+
### Adding Experimental Fields
9871

99-
```shell
100-
make uninstall
101-
```
72+
All additions to the API must start in the Experimental release channel.
73+
Experimental fields must be marked with the `<gateway:experimental>` annotation
74+
in Go type definitions. Gateway API CRD generation will only include these
75+
fields in the experimental set of CRDs.
76+
77+
If experimental fields are removed or renamed, the original field name should be
78+
removed from the go struct, with a tombstone comment
79+
([example](https://github.com/kubernetes/kubernetes/blob/707b8b6efd1691b84095c9f995f2c259244e276c/staging/src/k8s.io/api/core/v1/types.go#L4444-L4445))
80+
ensuring the field name will not be reused.
10281

103-
## Submitting a Pull Request
82+
### Submitting a Pull Request
10483

105-
Gateway API follows a similar pull request process as [Kubernetes].
84+
Gateway API follows a similar pull request process as
85+
[Kubernetes](https://github.com/kubernetes/community/blob/master/contributors/guide/pull-requests.md).
10686
Merging a pull request requires the following steps to be completed before the
10787
pull request will be merged automatically.
10888

@@ -123,20 +103,22 @@ make verify
123103

124104
[prow-setup]: https://github.com/kubernetes/test-infra/tree/master/config/jobs/kubernetes-sigs/gateway-api
125105

126-
## Documentation
106+
### Documentation
127107

128-
The site documentation is written in Markdown and compiled with [mkdocs]. Each PR
129-
will automatically include a [Netlify] deploy preview. When new code merges, it will
130-
automatically be deployed with Netlify to [gateway-api.sigs.k8s.io]. If you want to manually
131-
preview docs changes locally, you can install mkdocs and run:
108+
The site documentation is written in Markdown and compiled with
109+
[mkdocs](https://www.mkdocs.org/). Each PR will automatically include a
110+
[Netlify](https://netlify.com/) deploy preview. When new code merges, it will
111+
automatically be deployed with Netlify to
112+
[gateway-api.sigs.k8s.io](https://gateway-api.sigs.k8s.io). If you want to
113+
manually preview docs changes locally, you can install mkdocs and run:
132114

133115
```shell
134116
make docs
135117
```
136118

137-
To make it easier to use the right version of [mkdocs], there is a `.venv`
138-
target to create a Python virtualenv that includes [mkdocs]. To use the
139-
[mkdocs] live preview server while you edit, you can run [mkdocs] from
119+
To make it easier to use the right version of mkdocs, there is a `.venv`
120+
target to create a Python virtualenv that includes mkdocs. To use the
121+
mkdocs live preview server while you edit, you can run mkdocs from
140122
the virtualenv:
141123

142124
```shell
@@ -149,14 +131,10 @@ INFO - Building documentation...
149131
...
150132
```
151133

152-
[mkdocs]: https://www.mkdocs.org/
153-
[Netlify]: https://netlify.com/
154-
[gateway-api.sigs.k8s.io]: https://gateway-api.sigs.k8s.io
155-
[Go environment]: https://golang.org/doc/install
156-
[Kubernetes]: https://github.com/kubernetes/community/blob/master/contributors/guide/pull-requests.md
134+
For more information on how documentation should be written, refer to our
135+
[Documentation Style Guide](/contributing/style-guide).
157136

158137
## Conformance Tests
159138

160-
To develop or run conformance tests, follow the [Conformance Test Guide].
161-
162-
[Conformance Test Guide]: /concepts/conformance/#running-tests
139+
To develop or run conformance tests, refer to the [Conformance Test
140+
Documentation](/concepts/conformance/#running-tests).
File renamed without changes.

0 commit comments

Comments
 (0)