README

kops logo

kops - Kubernetes Operations

Build Status Go Report Card GoDoc Widget

The easiest way to get a production grade Kubernetes cluster up and running.

What is kops?

We like to think of it as kubectl for clusters.

kops helps you create, destroy, upgrade and maintain production-grade, highly available, Kubernetes clusters from the command line. AWS (Amazon Web Services) is currently officially supported, with GCE and OpenStack in beta support, and VMware vSphere in alpha, and other platforms planned.

Can I see it in action?

Launching a Kubernetes cluster hosted on AWS, GCE, DigitalOcean or OpenStack

To replicate the above demo, check out our tutorial for launching a Kubernetes cluster hosted on AWS.

To install a Kubernetes cluster on GCE please follow this guide.

To install a Kubernetes cluster on DigitalOcean, follow this guide.

To install a Kubernetes cluster on OpenStack, follow this guide.

For anything beyond experimental clusters it is highly encouraged to version control the cluster manifest files and run kops in a CI environment.

Features

  • Automates the provisioning of Kubernetes clusters in AWS and GCE
  • Deploys Highly Available (HA) Kubernetes Masters
  • Built on a state-sync model for dry-runs and automatic idempotency
  • Ability to generate Terraform
  • Supports custom Kubernetes add-ons
  • Command line autocompletion
  • YAML Manifest Based API Configuration
  • Templating and dry-run modes for creating Manifests
  • Choose from eight different CNI Networking providers out-of-the-box
  • Supports upgrading from kube-up
  • Capability to add containers, as hooks, and files to nodes via a cluster manifest

Documentation

Documentation is in the /docs directory, and the index is here.

Kubernetes Release Compatibility

Kubernetes Version Support

kops is intended to be backward compatible. It is always recommended to use the latest version of kops with whatever version of Kubernetes you are using. We suggest kops users run one of the 3 minor versions Kubernetes is supporting however we do our best to support previous releases for a period of time.

One exception, in regard to compatibility, kops supports the equivalent Kubernetes minor release number. A minor version is the second digit in the release number. kops version 1.13.0 has a minor version of 13. The numbering follows the semantic versioning specification, MAJOR.MINOR.PATCH.

For example, kops 1.12.0 does not support Kubernetes 1.13.0, but kops 1.13.0 supports Kubernetes 1.12.2 and previous Kubernetes versions. Only when the kops minor version matches the Kubernetes minor version does kops officially support the Kubernetes release. kops does not stop a user from installing mismatching versions of K8s, but Kubernetes releases always require kops to install specific versions of components like docker, that tested against the particular Kubernetes version.

Compatibility Matrix
kops version k8s 1.9.x k8s 1.10.x k8s 1.11.x k8s 1.12.x k8s 1.13.x k8s 1.14.x
1.14.x - Beta
1.13.x
1.12.x
1.11.x
1.10.x
1.9.x

Use the latest version of kops for all releases of Kubernetes, with the caveat that higher versions of Kubernetes are not officially supported by kops. Releases who are crossed out should work but we suggest should be upgraded soon.

kops Release Schedule

This project does not follow the Kubernetes release schedule. kops aims to provide a reliable installation experience for kubernetes, and typically releases about a month after the corresponding Kubernetes release. This time allows for the Kubernetes project to resolve any issues introduced by the new version and ensures that we can support the latest features. kops will release alpha and beta pre-releases for people that are eager to try the latest Kubernetes release. Please only use pre-GA kops releases in environments that can tolerate the quirks of new releases, and please do report any issues encountered.

Installing

Prerequisite

kubectl is required, see here.

OSX From Homebrew
brew update && brew install kops

The kops binary is also available via our releases.

Linux
curl -LO https://github.com/kubernetes/kops/releases/download/$(curl -s https://api.github.com/repos/kubernetes/kops/releases/latest | grep tag_name | cut -d '"' -f 4)/kops-linux-amd64
chmod +x kops-linux-amd64
sudo mv kops-linux-amd64 /usr/local/bin/kops
Windows
  1. Get kops-windows-amd64 from our releases.
  2. Rename kops-windows-amd64 to kops.exe and store it in a preferred path.
  3. Make sure the path you chose is added to your Path environment variable.

Release History

See the releases for more information on changes between releases.

Getting Involved and Contributing

Are you interested in contributing to kops? We, the maintainers and community, would love your suggestions, contributions, and help! We have a quick-start guide on adding a feature. Also, the maintainers can be contacted at any time to learn more about how to get involved.

In the interest of getting more newer folks involved with kops, we are starting to tag issues with good-starter-issue. These are typically issues that have smaller scope but are good ways to start to get acquainted with the codebase.

We also encourage ALL active community participants to act as if they are maintainers, even if you don't have "official" write permissions. This is a community effort, we are here to serve the Kubernetes community. If you have an active interest and you want to get involved, you have real power! Don't assume that the only people who can get things done around here are the "maintainers".

We also would love to add more "official" maintainers, so show us what you can do!

What this means:

Issues

  • Help read and triage issues, assist when possible.
  • Point out issues that are duplicates, out of date, etc.
    • Even if you don't have tagging permissions, make a note and tag maintainers (/close,/dupe #127).

Pull Requests

  • Read and review the code. Leave comments, questions, and critiques (/lgtm ).
  • Download, compile, and run the code and make sure the tests pass (make test).
    • Also verify that the new feature seems sane, follows best architectural patterns, and includes tests.

This repository uses the Kubernetes bots. See a full list of the commands here.

Office Hours

Kops maintainers set aside one hour every other week for public office hours. This time is used to gather with community members interested in kops. This session is open to both developers and users.

Office hours are hosted on a zoom video chat on Fridays at 12 noon (Eastern Time)/9 am (Pacific Time) during weeks with odd "numbers". To check this weeks' number, run: date +%V. If the response is odd, join us on Friday for office hours!

Office Hours Topics

We do maintain an agenda and stick to it as much as possible. If you want to hold the floor, put your item in this doc. Bullet/note form is fine. Even if your topic gets in late, we do our best to cover it.

Our office hours call is recorded, but the tone tends to be casual. First-timers are always welcome. Typical areas of discussion can include:

  • Contributors with a feature proposal seeking feedback, assistance, etc
  • Members planning for what we want to get done for the next release
  • Strategizing for larger initiatives, such as those that involve more than one sig or potentially more moving pieces
  • Help wanted requests
  • Demonstrations of cool stuff. PoCs. Fresh ideas. Show us how you use kops to go beyond the norm- help us define the future!

Office hours are designed for ALL of those contributing to kops or the community. Contributions are not limited to those who commit source code. There are so many important ways to be involved-

  • helping in the slack channels
  • triaging/writing issues
  • thinking about the topics raised at office hours and forming and advocating for your good ideas forming opinions
  • testing pre-(and official) releases

Although not exhaustive, the above activities are extremely important to our continued success and are all worth contributions. If you want to talk about kops and you have doubt, just come.

Other Ways to Communicate with the Contributors

Please check in with us in the #kops-users or #kops-dev channel. Often-times, a well crafted question or potential bug report in slack will catch the attention of the right folks and help quickly get the ship righted.

GitHub Issues

Bugs

If you think you have found a bug please follow the instructions below.

  • Please spend a small amount of time giving due diligence to the issue tracker. Your issue might be a duplicate.
  • Set -v 10 command line option and save the log output. Please paste this into your issue.
  • Note the version of kops you are running (from kops version), and the command line options you are using.
  • Open a new issue.
  • Remember users might be searching for your issue in the future, so please give it a meaningful title to helps others.
  • Feel free to reach out to the kops community on kubernetes slack.
Features

We also use the issue tracker to track features. If you have an idea for a feature, or think you can help kops become even more awesome follow the steps below.

  • Open a new issue.
  • Remember users might be searching for your issue in the future, so please give it a meaningful title to helps others.
  • Clearly define the use case, using concrete examples. EG: I type this and kops does that.
  • Some of our larger features will require some design. If you would like to include a technical design for your feature please include it in the issue.
  • After the new feature is well understood, and the design agreed upon we can start coding the feature. We would love for you to code it. So please open up a WIP (work in progress) pull request, and happy coding.
Expand ▾ Collapse ▴

Documentation

Overview

Package kops is the parent package for the kops kubernetes-ops tool..

Index

Constants

const (
	KOPS_RELEASE_VERSION = "1.15.0-beta.1"
	KOPS_CI_VERSION      = "1.15.0-beta.2"
)

These constants are parsed by build tooling - be careful about changing the formats


Variables

var GitVersion = ""

GitVersion should be replaced by the makefile


var Version = KOPS_RELEASE_VERSION

Version can be replaced by build tooling


Functions

func DefaultProtokubeImageName

func DefaultProtokubeImageName() string

DefaultProtokubeImageName is the name of the protokube image, as we would pass to "docker run"

Types

This section is empty.

Source Files

Directories

Path Synopsis
channels/cmd/channels
channels/pkg/api
channels/pkg/channels
channels/pkg/cmd
cloudmock/aws/mockautoscaling
cloudmock/aws/mockec2
cloudmock/aws/mockelb
cloudmock/aws/mockelbv2
cloudmock/aws/mockiam
cloudmock/aws/mockroute53
cmd/kops
cmd/kops/util
cmd/nodeup
dns-controller/cmd/dns-controller
dns-controller/pkg/dns
dns-controller/pkg/util
dns-controller/pkg/watchers
dnsprovider/pkg/dnsprovider dnsprovider supplies interfaces for dns service providers (e.g.
dnsprovider/pkg/dnsprovider/providers/aws/route53 route53 is the implementation of pkg/dnsprovider interface for AWS Route53
dnsprovider/pkg/dnsprovider/providers/aws/route53/stubs internal implements a stub for the AWS Route53 API, used primarily for unit testing purposes
dnsprovider/pkg/dnsprovider/providers/coredns Package coredns is the implementation of pkg/dnsprovider interface for CoreDNS
dnsprovider/pkg/dnsprovider/providers/coredns/stubs Package stubs implements a stub for the EtcdKeysAPI, used primarily for unit testing purposes
dnsprovider/pkg/dnsprovider/providers/google/clouddns clouddns is the implementation of pkg/dnsprovider interface for Google Cloud DNS
dnsprovider/pkg/dnsprovider/providers/google/clouddns/internal
dnsprovider/pkg/dnsprovider/providers/google/clouddns/internal/interfaces
dnsprovider/pkg/dnsprovider/providers/google/clouddns/internal/stubs
dnsprovider/pkg/dnsprovider/providers/openstack/designate
dnsprovider/pkg/dnsprovider/rrstype
dnsprovider/pkg/dnsprovider/tests
examples/kops-api-example
hack/machine_types
kube-discovery/cmd/kube-discovery
node-authorizer/cmd/node-authorizer
node-authorizer/pkg/authorizers/alwaysallow
node-authorizer/pkg/authorizers/aws
node-authorizer/pkg/client
node-authorizer/pkg/server
node-authorizer/pkg/utils
nodeup/pkg/bootstrap
nodeup/pkg/distros
nodeup/pkg/model
nodeup/pkg/model/resources
pkg/acls
pkg/acls/gce
pkg/acls/s3
pkg/apis/kops +groupName=kops.k8s.io
pkg/apis/kops/install Package install installs the kops API group, making it available as an option to all of the API encoding/decoding machinery.
pkg/apis/kops/model
pkg/apis/kops/registry
pkg/apis/kops/util
pkg/apis/kops/v1alpha1 +groupName=kops.k8s.io
pkg/apis/kops/v1alpha2 +groupName=kops.k8s.io
pkg/apis/kops/validation
pkg/apis/nodeup
pkg/assets
pkg/backoff
pkg/bundle
pkg/client/clientset_generated/clientset This package has the automatically generated clientset.
pkg/client/clientset_generated/clientset/fake This package has the automatically generated fake clientset.
pkg/client/clientset_generated/clientset/scheme This package contains the scheme of the automatically generated clientset.
pkg/client/clientset_generated/clientset/typed/kops/internalversion This package has the automatically generated typed clients.
pkg/client/clientset_generated/clientset/typed/kops/internalversion/fake Package fake has the automatically generated clients.
pkg/client/clientset_generated/clientset/typed/kops/v1alpha1 This package has the automatically generated typed clients.
pkg/client/clientset_generated/clientset/typed/kops/v1alpha1/fake Package fake has the automatically generated clients.
pkg/client/clientset_generated/clientset/typed/kops/v1alpha2 This package has the automatically generated typed clients.
pkg/client/clientset_generated/clientset/typed/kops/v1alpha2/fake Package fake has the automatically generated clients.
pkg/client/clientset_generated/internalclientset This package has the automatically generated clientset.
pkg/client/clientset_generated/internalclientset/fake This package has the automatically generated fake clientset.
pkg/client/clientset_generated/internalclientset/scheme This package contains the scheme of the automatically generated clientset.
pkg/client/clientset_generated/internalclientset/typed/kops/internalversion This package has the automatically generated typed clients.
pkg/client/clientset_generated/internalclientset/typed/kops/internalversion/fake Package fake has the automatically generated clients.
pkg/client/clientset_generated/internalclientset/typed/kops/v1alpha1 This package has the automatically generated typed clients.
pkg/client/clientset_generated/internalclientset/typed/kops/v1alpha1/fake Package fake has the automatically generated clients.
pkg/client/clientset_generated/internalclientset/typed/kops/v1alpha2 This package has the automatically generated typed clients.
pkg/client/clientset_generated/internalclientset/typed/kops/v1alpha2/fake Package fake has the automatically generated clients.
pkg/client/simple
pkg/client/simple/api
pkg/client/simple/vfsclientset
pkg/cloudinstances
pkg/commands
pkg/diff
pkg/dns
pkg/drain
pkg/edit
pkg/featureflag Package featureflag implements simple feature-flagging.
pkg/flagbuilder
pkg/formatter
pkg/instancegroups
pkg/jsonutils
pkg/k8scodecs
pkg/k8sversion
pkg/kopscodecs
pkg/kubeconfig
pkg/kubemanifest
pkg/model
pkg/model/alimodel
pkg/model/awsmodel
pkg/model/components
pkg/model/components/etcdmanager
pkg/model/components/node-authorizer
pkg/model/defaults
pkg/model/domodel
pkg/model/gcemodel
pkg/model/iam
pkg/model/openstackmodel
pkg/model/resources
pkg/model/spotinstmodel
pkg/model/vspheremodel
pkg/pki
pkg/pkiutil
pkg/pretty
pkg/rbac
pkg/resources
pkg/resources/ali
pkg/resources/aws
pkg/resources/digitalocean
pkg/resources/digitalocean/dns
pkg/resources/gce
pkg/resources/openstack
pkg/resources/ops
pkg/resources/spotinst
pkg/sshcredentials
pkg/systemd
pkg/templates
pkg/testutils
pkg/tokens
pkg/try
pkg/urls
pkg/util/stringorslice
pkg/util/subnet
pkg/util/templater
pkg/validation
pkg/values
protokube/cmd/protokube
protokube/pkg/etcd
protokube/pkg/gossip
protokube/pkg/gossip/ali
protokube/pkg/gossip/aws
protokube/pkg/gossip/dns
protokube/pkg/gossip/dns/hosts
protokube/pkg/gossip/dns/provider Package provider implements a dnsprovider backed by the gossip store.
protokube/pkg/gossip/gce
protokube/pkg/gossip/mesh Package mesh is a generated protocol buffer package.
protokube/pkg/gossip/openstack
protokube/pkg/protokube
upup/models
upup/pkg/fi
upup/pkg/fi/assettasks
upup/pkg/fi/cloudup
upup/pkg/fi/cloudup/alitasks
upup/pkg/fi/cloudup/aliup
upup/pkg/fi/cloudup/awstasks
upup/pkg/fi/cloudup/awsup
upup/pkg/fi/cloudup/baremetal
upup/pkg/fi/cloudup/cloudformation
upup/pkg/fi/cloudup/dnstasks
upup/pkg/fi/cloudup/do
upup/pkg/fi/cloudup/dotasks
upup/pkg/fi/cloudup/gce
upup/pkg/fi/cloudup/gcetasks
upup/pkg/fi/cloudup/openstack
upup/pkg/fi/cloudup/openstacktasks
upup/pkg/fi/cloudup/spotinsttasks
upup/pkg/fi/cloudup/terraform
upup/pkg/fi/cloudup/vsphere
upup/pkg/fi/cloudup/vspheretasks
upup/pkg/fi/fitasks
upup/pkg/fi/k8sapi
upup/pkg/fi/loader
upup/pkg/fi/nodeup
upup/pkg/fi/nodeup/cloudinit
upup/pkg/fi/nodeup/local
upup/pkg/fi/nodeup/nodetasks
upup/pkg/fi/nodeup/tags
upup/pkg/fi/secrets
upup/pkg/fi/utils
upup/pkg/kutil
upup/tools/generators/fitask
upup/tools/generators/pkg/codegen
util/pkg/env
util/pkg/exec
util/pkg/hashing
util/pkg/maps
util/pkg/proxy
util/pkg/reflectutils
util/pkg/slice Package slice provides utility methods for common operations on slices.
util/pkg/tables
util/pkg/text
util/pkg/ui
util/pkg/vfs