Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deployment #4

Closed
3 tasks done
CarwynNelson opened this issue Jun 21, 2020 · 4 comments · Fixed by #10
Closed
3 tasks done

Deployment #4

CarwynNelson opened this issue Jun 21, 2020 · 4 comments · Fixed by #10
Assignees

Comments

@CarwynNelson
Copy link
Contributor

CarwynNelson commented Jun 21, 2020

Requirements

We require an easy way for contributors to test and deploy their work to testing and production environments.

  • Pick a deployment method (elasticbeanstalk, kubernetes, EC2)
  • Hand rolled kubernetes cluster in AWS (production-level setup can come at a later stage)
  • Build and deploy changes to k8s on merge to master

In the future I would like trusted members to be able to deploy pull requests to a test environment. eg my-branch.test.geek.zone. This can be dealt with at a later date.

@CarwynNelson CarwynNelson self-assigned this Jun 21, 2020
@CarwynNelson
Copy link
Contributor Author

We (@jamesgeddes and I) have decided to go with Kubernetes for deploying this project. It can be complicated to manage, but multiple dev volunteers are interested in learning and managing it, and it is considered to be a draw for new volunteers who might want to learn it to add to their CV.

Importantly it is a robust and flexible platform to develop on and will almost certainly have almost if not all future GeekZone deployment needs covered.

@CarwynNelson
Copy link
Contributor Author

I am currently brushing up on my Kubernetes skills using this Pluralsight path https://app.pluralsight.com/paths/skill/using-kubernetes-as-a-developer.

I plan to put together a first-pass deployment setup for this repository once I have completed the first part of this Pluralsight path.

@CarwynNelson
Copy link
Contributor Author

CarwynNelson commented Jun 28, 2020

I have put a first pass together which is available at http://test.geek.zone/. The code for this is on the kubernetes-deployment WIP branch

@CarwynNelson
Copy link
Contributor Author

I now have a branch that can deploy master to the test Kubernetes cluster using circleci. This branch needs some tidying up, and I need to update the documentation but I feel like i'm 90% towards having this merged into master.

Before we go live we will have to spend some time production-ising the k8s cluster and IAM permissions etc, but I can raise a separate issue for that.

CarwynNelson added a commit that referenced this issue Jul 1, 2020
Resolves #4.

This commit allows members and contributors to deploy their changes to
a testing environment.

The testing environment is currently a temporary Kubernetes cluster
hosted on AWS using their Elastic Kubernetes Service (EKS).

CircleCI builds docker images of the django web app and an nginx proxy
and then pushes them up to the GeekZone Elastic Container
Registry (ECR). CircleCI then applies the kuberenetes configuration
located in the `k8s` folder to the kubernetes cluster.

Docker images are tagged with the circleci workflow id which is unqiue
to every run of the pipeline.

The django service is run using Gunicorn and all requests to it are
proxied via nginx which serves static assets. There might be a better
way of doing this in the long term?
CarwynNelson added a commit that referenced this issue Jul 1, 2020
Resolves #4.

This commit allows members and contributors to deploy their changes to
a testing environment.

The testing environment is currently a temporary Kubernetes cluster
hosted on AWS using their Elastic Kubernetes Service (EKS).

CircleCI builds docker images of the django web app and an nginx proxy
and then pushes them up to the GeekZone Elastic Container
Registry (ECR). CircleCI then applies the kuberenetes configuration
located in the `k8s` folder to the kubernetes cluster.

Docker images are tagged with the circleci workflow id which is unqiue
to every run of the pipeline.

The django service is run using Gunicorn and all requests to it are
proxied via nginx which serves static assets. There might be a better
way of doing this in the long term?
CarwynNelson added a commit that referenced this issue Jul 1, 2020
Resolves #4.

This commit allows members and contributors to deploy their changes to
a testing environment.

The testing environment is currently a temporary Kubernetes cluster
hosted on AWS using their Elastic Kubernetes Service (EKS).

CircleCI builds docker images of the django web app and an nginx proxy
and then pushes them up to the GeekZone Elastic Container
Registry (ECR). CircleCI then applies the kuberenetes configuration
located in the `k8s` folder to the kubernetes cluster.

Docker images are tagged with the circleci workflow id which is unqiue
to every run of the pipeline.

The django service is run using Gunicorn and all requests to it are
proxied via nginx which serves static assets. There might be a better
way of doing this in the long term?
CarwynNelson added a commit that referenced this issue Jul 1, 2020
Resolves #4.

This commit allows members and contributors to deploy their changes to
a testing environment.

The testing environment is currently a temporary Kubernetes cluster
hosted on AWS using their Elastic Kubernetes Service (EKS).

CircleCI builds docker images of the django web app and an nginx proxy
and then pushes them up to the GeekZone Elastic Container
Registry (ECR). CircleCI then applies the kuberenetes configuration
located in the `k8s` folder to the kubernetes cluster.

Docker images are tagged with the circleci workflow id which is unqiue
to every run of the pipeline.

The django service is run using Gunicorn and all requests to it are
proxied via nginx which serves static assets. There might be a better
way of doing this in the long term?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant