• Stars
    star
    4,237
  • Rank 9,695 (Top 0.2 %)
  • Language
    HTML
  • License
    Creative Commons ...
  • Created about 8 years ago
  • Updated about 1 month ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Kubernetes website and documentation repo:

The Kubernetes documentation

Netlify Status GitHub release

This repository contains the assets required to build the Kubernetes website and documentation. We're glad that you want to contribute!

Using this repository

You can run the website locally using Hugo (Extended version), or you can run it in a container runtime. We strongly recommend using the container runtime, as it gives deployment consistency with the live website.

Prerequisites

To use this repository, you need the following installed locally:

Before you start, install the dependencies. Clone the repository and navigate to the directory:

git clone https://github.com/kubernetes/website.git
cd website

The Kubernetes website uses the Docsy Hugo theme. Even if you plan to run the website in a container, we strongly recommend pulling in the submodule and other development dependencies by running the following:

Windows

# fetch submodule dependencies
git submodule update --init --recursive --depth 1

Linux / other Unix

# fetch submodule dependencies
make module-init

Running the website using a container

To build the site in a container, run the following:

# You can set $CONTAINER_ENGINE to the name of any Docker-like container tool
make container-serve

If you see errors, it probably means that the hugo container did not have enough computing resources available. To solve it, increase the amount of allowed CPU and memory usage for Docker on your machine (MacOSX and Windows).

Open up your browser to http://localhost:1313 to view the website. As you make changes to the source files, Hugo updates the website and forces a browser refresh.

Running the website locally using Hugo

Make sure to install the Hugo extended version specified by the HUGO_VERSION environment variable in the netlify.toml file.

To build and test the site locally, run:

# install dependencies
npm ci
make serve

This will start the local Hugo server on port 1313. Open up your browser to http://localhost:1313 to view the website. As you make changes to the source files, Hugo updates the website and forces a browser refresh.

Building the API reference pages

The API reference pages located in content/en/docs/reference/kubernetes-api are built from the Swagger specification, also known as OpenAPI specification, using https://github.com/kubernetes-sigs/reference-docs/tree/master/gen-resourcesdocs.

To update the reference pages for a new Kubernetes release follow these steps:

  1. Pull in the api-ref-generator submodule:

    git submodule update --init --recursive --depth 1
  2. Update the Swagger specification:

    curl 'https://raw.githubusercontent.com/kubernetes/kubernetes/master/api/openapi-spec/swagger.json' > api-ref-assets/api/swagger.json
  3. In api-ref-assets/config/, adapt the files toc.yaml and fields.yaml to reflect the changes of the new release.

  4. Next, build the pages:

    make api-reference

    You can test the results locally by making and serving the site from a container image:

    make container-image
    make container-serve

    In a web browser, go to http://localhost:1313/docs/reference/kubernetes-api/ to view the API reference.

  5. When all changes of the new contract are reflected into the configuration files toc.yaml and fields.yaml, create a Pull Request with the newly generated API reference pages.

Troubleshooting

error: failed to transform resource: TOCSS: failed to transform "scss/main.scss" (text/x-scss): this feature is not available in your current Hugo version

Hugo is shipped in two set of binaries for technical reasons. The current website runs based on the Hugo Extended version only. In the release page look for archives with extended in the name. To confirm, run hugo version and look for the word extended.

Troubleshooting macOS for too many open files

If you run make serve on macOS and receive the following error:

ERROR 2020/08/01 19:09:18 Error: listen tcp 127.0.0.1:1313: socket: too many open files
make: *** [serve] Error 1

Try checking the current limit for open files:

launchctl limit maxfiles

Then run the following commands (adapted from https://gist.github.com/tombigel/d503800a282fcadbee14b537735d202c):

#!/bin/sh

# These are the original gist links, linking to my gists now.
# curl -O https://gist.githubusercontent.com/a2ikm/761c2ab02b7b3935679e55af5d81786a/raw/ab644cb92f216c019a2f032bbf25e258b01d87f9/limit.maxfiles.plist
# curl -O https://gist.githubusercontent.com/a2ikm/761c2ab02b7b3935679e55af5d81786a/raw/ab644cb92f216c019a2f032bbf25e258b01d87f9/limit.maxproc.plist

curl -O https://gist.githubusercontent.com/tombigel/d503800a282fcadbee14b537735d202c/raw/ed73cacf82906fdde59976a0c8248cce8b44f906/limit.maxfiles.plist
curl -O https://gist.githubusercontent.com/tombigel/d503800a282fcadbee14b537735d202c/raw/ed73cacf82906fdde59976a0c8248cce8b44f906/limit.maxproc.plist

sudo mv limit.maxfiles.plist /Library/LaunchDaemons
sudo mv limit.maxproc.plist /Library/LaunchDaemons

sudo chown root:wheel /Library/LaunchDaemons/limit.maxfiles.plist
sudo chown root:wheel /Library/LaunchDaemons/limit.maxproc.plist

sudo launchctl load -w /Library/LaunchDaemons/limit.maxfiles.plist

This works for Catalina as well as Mojave macOS.

Get involved with SIG Docs

Learn more about SIG Docs Kubernetes community and meetings on the community page.

You can also reach the maintainers of this project at:

Contributing to the docs

You can click the Fork button in the upper-right area of the screen to create a copy of this repository in your GitHub account. This copy is called a fork. Make any changes you want in your fork, and when you are ready to send those changes to us, go to your fork and create a new pull request to let us know about it.

Once your pull request is created, a Kubernetes reviewer will take responsibility for providing clear, actionable feedback. As the owner of the pull request, it is your responsibility to modify your pull request to address the feedback that has been provided to you by the Kubernetes reviewer.

Also, note that you may end up having more than one Kubernetes reviewer provide you feedback or you may end up getting feedback from a Kubernetes reviewer that is different than the one initially assigned to provide you feedback.

Furthermore, in some cases, one of your reviewers might ask for a technical review from a Kubernetes tech reviewer when needed. Reviewers will do their best to provide feedback in a timely fashion but response time can vary based on circumstances.

For more information about contributing to the Kubernetes documentation, see:

New contributor ambassadors

If you need help at any point when contributing, the New Contributor Ambassadors are a good point of contact. These are SIG Docs approvers whose responsibilities include mentoring new contributors and helping them through their first few pull requests. The best place to contact the New Contributors Ambassadors would be on the Kubernetes Slack. Current New Contributors Ambassadors for SIG Docs:

Name Slack GitHub
Arsh Sharma @arsh @RinkiyaKeDad

Localization README.md's

Language Language
Chinese Korean
French Polish
German Portuguese
Hindi Russian
Indonesian Spanish
Italian Ukrainian
Japanese Vietnamese

Code of conduct

Participation in the Kubernetes community is governed by the CNCF Code of Conduct.

Thank you

Kubernetes thrives on community participation, and we appreciate your contributions to our website and our documentation!

More Repositories

1

kubernetes

Production-Grade Container Scheduling and Management
Go
105,869
star
2

minikube

Run Kubernetes locally
Go
28,262
star
3

ingress-nginx

Ingress-NGINX Controller for Kubernetes
Go
16,503
star
4

kops

Kubernetes Operations (kOps) - Production Grade k8s Installation, Upgrades and Management
Go
15,486
star
5

dashboard

General-purpose web UI for Kubernetes clusters
Go
13,699
star
6

community

Kubernetes community content
Jupyter Notebook
11,570
star
7

kompose

Convert Compose to Kubernetes
Go
9,056
star
8

client-go

Go client for Kubernetes.
Go
8,516
star
9

autoscaler

Autoscaling components for Kubernetes
Go
7,628
star
10

examples

Kubernetes application example tutorials
Shell
5,992
star
11

kube-state-metrics

Add-on agent to generate and expose cluster-level metrics.
Go
5,018
star
12

test-infra

Test infrastructure for the Kubernetes project.
Go
3,775
star
13

kubeadm

Aggregator for issues filed against kubeadm
Go
3,632
star
14

enhancements

Enhancements tracking repo for Kubernetes
Go
3,220
star
15

sample-controller

Repository for sample controller. Complements sample-apiserver
Go
2,987
star
16

node-problem-detector

This is a place for various problem detectors running on the Kubernetes nodes.
Go
2,706
star
17

kubectl

Issue tracker and mirror of kubectl code
Go
2,653
star
18

git-sync

A sidecar app which clones a git repo and keeps it in sync with the upstream.
Shell
1,994
star
19

code-generator

Generators for kube-like API types
Go
1,596
star
20

ingress-gce

Ingress controller for Google Cloud
Go
1,248
star
21

dns

Kubernetes DNS service
Go
871
star
22

perf-tests

Performance tests and benchmarks
Go
849
star
23

apimachinery

Go
774
star
24

k8s.io

Code and configuration to manage Kubernetes project infrastructure, including various *.k8s.io sites
HCL
667
star
25

apiserver

Library for writing a Kubernetes-style API server.
Go
613
star
26

api

The canonical location of the Kubernetes API definition.
Go
609
star
27

cloud-provider-openstack

Go
582
star
28

gengo

gengo library for code generation.
Go
533
star
29

sig-release

Repo for SIG release
Shell
512
star
30

sample-apiserver

Reference implementation of an apiserver for a custom Kubernetes API.
Go
496
star
31

metrics

Kubernetes metrics-related API types and clients
Go
478
star
32

release

Release infrastructure for Kubernetes and related components
Go
470
star
33

design-proposals-archive

Archive of Kubernetes Design Proposals
Makefile
442
star
34

cri-api

Container Runtime Interface (CRI) – a plugin interface which enables kubelet to use a wide variety of container runtimes.
Go
357
star
35

cloud-provider-aws

Cloud provider for AWS
Go
350
star
36

cloud-provider-alibaba-cloud

CloudProvider for Alibaba Cloud
Go
345
star
37

registry.k8s.io

This project is the repo for registry.k8s.io, the production OCI registry service for Kubernetes' container image artifacts
Go
340
star
38

utils

Non-Kubernetes-specific utility libraries which are consumed by multiple projects.
Go
306
star
39

kube-openapi

Kubernetes OpenAPI spec generation & serving
Go
289
star
40

kubelet

kubelet component configs
Go
281
star
41

sample-cli-plugin

Sample kubectl plugin
Go
278
star
42

cli-runtime

Set of helpers for creating kubectl commands and plugins.
Go
270
star
43

kube-aggregator

Aggregator for Kubernetes-style API servers: dynamic registration, discovery summarization, secure proxy
Go
242
star
44

org

Meta configuration for Kubernetes Github Org
Go
232
star
45

apiextensions-apiserver

API server for API extensions like CustomResourceDefinitions
Go
223
star
46

cloud-provider-vsphere

Kubernetes Cloud Provider for vSphere https://cloud-provider-vsphere.sigs.k8s.io
Go
221
star
47

cloud-provider

cloud-provider defines the shared interfaces which Kubernetes cloud providers implement. These interfaces allow various controllers to integrate with any cloud provider in a pluggable fashion. Also serves as an issue tracker for SIG Cloud Provider.
Go
219
star
48

kubernetes-template-project

A template for starting new projects on the github.com/kubernetes organization
176
star
49

kube-proxy

kube-proxy component configs
Go
166
star
50

committee-security-response

Kubernetes Security Process and Security Committee docs
161
star
51

kube-scheduler

kube-scheduler component configs
Go
150
star
52

sig-security

Process documentation, non-code deliverables, and miscellaneous artifacts of Kubernetes SIG Security
Python
146
star
53

component-base

Shared code for kubernetes core components
Go
102
star
54

repo-infra

Kubernetes repository infrastucture tools
Starlark
95
star
55

cloud-provider-gcp

cloud-provider-gcp contains several projects used to run Kubernetes in Google Cloud
Go
95
star
56

pod-security-admission

Kubernetes Pod Security Standards implementation - https://github.com/kubernetes/enhancements/blob/master/keps/sig-auth/2579-psp-replacement/README.md
Go
94
star
57

kube-controller-manager

kube-controller-manager component configs
Go
81
star
58

publishing-bot

Code behind the robot to publish from staging to real repositories.
Go
79
star
59

steering

The Kubernetes Steering Committee
79
star
60

controller-manager

This repo is intended to contain common public library code for kube-controller-manager, cloud-controller-manager as well as any other controller managers which people build.
Go
61
star
61

contributor-site

Code for kubernetes.dev
HTML
58
star
62

mount-utils

Package mount defines an interface to mounting filesystems.
Go
50
star
63

legacy-cloud-providers

This repository hosts the legacy in-tree cloud providers. Out-of-tree cloud providers can consume packages in this repo to support legacy implementations of their Kubernetes cloud provider.
Go
49
star
64

cluster-bootstrap

Go
32
star
65

system-validators

A set of system-oriented validators for kubeadm preflight checks.
Go
32
star
66

dynamic-resource-allocation

Go
20
star
67

kms

Kubernetes KMS implementation
Go
18
star
68

cloud-provider-sample

Sample of how to build a cloud provider repo. This will build a Kubernetes image which deploys on bare metal. It uses the fake cloud provider. It consumes the K8s/K8s build artifact and adds to it the Cloud Controller Manager and CSI Daemon Set.
18
star
69

node-api

Go
15
star
70

component-helpers

High-level helpers for Kubernetes components
Go
14
star
71

cel-admission-webhook

Go
12
star
72

csi-translation-lib

Staging repo for CSI Migration/Translation libraries
Go
12
star
73

endpointslice

Go
7
star
74

sig-testing

Home for SIG Testing discussion and documents.
5
star
75

.github

Default files for all repos in the Kubernetes GitHub org
2
star