<commit_before># Running aws-operator Locally

**Note:** This should only be used for testing and development. See the
[/kubernetes/][kubernetes-dir] directory and [Secrets][secrets-doc] for
a production ready configuration.

[kubernetes-dir]: https://github.com/giantswarm/aws-operator/tree/master/kubernetes
[secrets-doc]: https://github.com/giantswarm/aws-operator#secret

This guide explains how to get aws-operator running locally - on minikube, for
example. Also how to create a managed Kubernetes cluster with single master and
single worker using the operator.

If not stated otherwise all commands are assumed to be run from `examples/local`
directory.

## Cluster Certificates

The easiest way to create certificates is to use the local [cert-operator]
setup. See [this guide][cert-operator-local-setup] for details. Using the [helm registry plugin]
the cert-operator charts can be installed easily:

```bash
helm registry install quay.io/giantswarm/cert-operator-lab-chart -- \
                   -n cert-operator-lab \
                   --set imageTag=latest \
                   --set clusterName=my-cluster \
                   --set commonDomain=my-common-domain \
                   --wait
helm registry install quay.io/giantswarm/cert-resource-lab-chart -- \
                   -n cert-resource-lab \
                   --set clusterName=my-cluster \
                   --set commonDomain=my-common-domain
```

- Note: `clusterName` and `commonDomain` chart values must match the values used
  during this guide.

[helm registry plugin]: https://github.com/app-registry/appr-helm-plugin

## Cluster-Local Docker Image

The operator needs a connection to the K8s API. The simplest approach is to run
the operator as a deployment and use the "in cluster" configuration.

In that case the Docker image needs to be accessible from the K8s cluster
running the operator. For Minikube run `eval $(minikube docker-env)` before
`docker build`, see [reusing the Docker daemon] for details.
<commit_msg>remove references to manually pushed charts (#485)<commit_after># Running aws-operator Locally

**Note:** This should only be used for testing and development. See the
[/kubernetes/][kubernetes-dir] directory and [Secrets][secrets-doc] for
a production ready configuration.

[kubernetes-dir]: https://github.com/giantswarm/aws-operator/tree/master/kubernetes
[secrets-doc]: https://github.com/giantswarm/aws-operator#secret

This guide explains how to get aws-operator running locally - on minikube, for
example. Also how to create a managed Kubernetes cluster with single master and
single worker using the operator.

If not stated otherwise all commands are assumed to be run from `examples/local`
directory.

## Cluster Certificates

The easiest way to create certificates is to use the local [cert-operator]
setup. See [this guide][cert-operator-local-setup] for details. The operator and certificates
to be used during aws-operator setup can be installed with:

```bash
git clone github.com/giantswarm/cert-operator ./cert-operator

helm \
  install -n cert-operator-lab ./cert-operator/examples/cert-operator-lab-chart/ \
  --set clusterName=my-cluster \
  --set commonDomain=my-common-domain \
  --set imageTag latest \
  --wait

# here the certificate TPR is created, wait until `kubectl get certificate` returns
# `No resources found.` before running the next command

helm install -n cert-resource-lab ./cert-operator/examples/cert-operator-lab-chart/ \
  --set clusterName=my-cluster \
  --set commonDomain=my-common-domain
```

- Note: `clusterName` and `commonDomain` chart values must match the values used
  during this guide.

## Cluster-Local Docker Image

The operator needs a connection to the K8s API. The simplest approach is to run
the operator as a deployment and use the "in cluster" configuration.

In that case the Docker image needs to be accessible from the K8s cluster
running the operator. For Minikube run `eval $(minikube docker-env)` before
`docker build`, see [reusing the Docker daemon] for details.

{'fraction_non_alphanumeric': 0.08751545117428924, 'fraction_numerical': 0.00173053152039555, 'mean_word_length': 3.6292906178489703, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 5, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2179264', 'n_tokens_mistral': 1121, 'n_tokens_neox': 1060, 'n_words': 445}