A CircleCI Orb to simplify deployments to Amazon Elastic Container Service for Kubernetes (Amazon EKS).
Here are some features that the AWS EKS orb provides:
- Setting up and tearing down of EKS clusters via the
create-cluster
anddelete-cluster
commands / jobs - Allowing
kubectl
and other tools that accesskubeconfig
(likehelm
) to work with an EKS cluster via theupdate-kubeconfig-with-authenticator
command - Updating deployments with container image updates via the
update-container-image
job - Installing helm and helm charts (See:
install-helm-on-cluster
andinstall-helm-chart
)
See the orb registry listing for usage guidelines.
-
AWS credential information should be accessible to the AWS CLI. The easiest way to provide the information would be to configure
AWS_ACCESS_KEY_ID
,AWS_SECRET_ACCESS_KEY
andAWS_DEFAULT_REGION
as CircleCI project or context environment variables. -
curl
should be present inPATH
. -
A
python
installation present inPATH
that supports running the AWS CLI -
pip
if the AWS CLI needs to be installed
Full usage examples can be found on the AWS EKS orb's page in the orb registry, here.
A demo project is also available here.
version: 2.1
orbs:
aws-eks: circleci/aws-eks@x.y
kubernetes: circleci/kubernetes@0.4.0
jobs:
create-deployment:
executor: aws-eks/python3
parameters:
cluster-name:
description: |
Name of the EKS cluster
type: string
steps:
- checkout
- aws-eks/update-kubeconfig-with-authenticator:
cluster-name: << parameters.cluster-name >>
install-kubectl: true
- kubernetes/create-or-update-resource:
resource-file-path: "tests/nginx-deployment/deployment.yaml"
resource-name: "deployment/nginx-deployment"
get-rollout-status: true
show-kubectl-command: true
workflows:
deployment:
jobs:
- aws-eks/create-cluster:
cluster-name: eks-demo-deployment
- create-deployment:
cluster-name: eks-demo-deployment
requires:
- aws-eks/create-cluster
- aws-eks/update-container-image:
cluster-name: eks-demo-deployment
resource-name: "deployment/nginx-deployment"
container-image-updates: "nginx=nginx:1.9.1"
record: true
requires:
- create-deployment
- aws-eks/delete-cluster:
cluster-name: eks-demo-deployment
requires:
- aws-eks/update-container-image
We welcome issues to and pull requests against this repository!
For further questions/comments about this or other orbs, visit CircleCI's orbs discussion forum.