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

CI/CD pipeline examples: GCP, AWS and Azure infra stacks in GitLab, ArgoCD, Jenkins #631

Closed
7 of 18 tasks
prasek opened this issue Jul 31, 2019 · 1 comment
Closed
7 of 18 tasks
Assignees
Labels
services status/consider considering for a milestone

Comments

@prasek
Copy link
Member

prasek commented Jul 31, 2019

Provide working examples and associated blog posts describing how to integrate Crossplane into various CI/CD pipelines for continuous deployment of Kubernetes apps and the cloud services they depend on.

Part of the 0.3 release

Why? What problem are we solving?

Crossplane simplifies k8s app deployments into different target environments (dev, test, prod) that often use their own networks, subnets, k8s clusters, cloud services, credentials, and security configuration.

For shared environments supporting multiple app teams, it can save a lot of time & work to configure each target environment once (networks, subnets, target k8s clusters, cloud service provisioners, cloud credentials) esp. since it can take several minutes to provision k8s clusters on demand and esp. in dev/test environments the k8s apps & cloud service instances are often ephemeral and transient in nature.

Even when an app team owns their own target environments (dev/test/prod) and k8s clusters, there are often multiple developers on a team sharing a (dev/test) cluster, and k8s app deployments (with cloud services) are frequently torn down (from-scratch vs. in-place upgrades) and the deployed k8s app instances need to be rapidly cycled as new commits land on master or changes are promoted.

Even if you're the only developer on an app and you have your own target environments (dev/test/prod) that you exclusively own and manage you probably don't want the time hit of k8s target cluster creation every time you cycle your k8s app deployment with cloud services in dev/test. So even then configuring your target environments once and rapidly cycling your k8s app instances is desirable.

So there are 2 primary problems:
(1) config of target environments (networks, subnets, target k8s clusters, ...), to support
(2) rapid deploy & reclaim k8s apps and cloud service dependencies in dev/test and maybe prod.

It's often considered a best practice to have these configurations stored 'as code' in a VCS, and then have changes committed trigger a traditional CI/CD pipeline like Jenkins or GitLab or have a GitOps style flow that polls Git and synchronizes desired state (e.g. WeaveWorks Flux, Google Anthos, etc).

So as a Crossplane user:

  • How should I use Crossplane infra stacks and app stacks from my CI/CD pipeline of choice?
  • Is there an example I can use to get started quickly?
  • Should I use kubectl apply or are is there a CLI tool I should use instead (e.g. to build, publish, and then apply stacks)?

What does it look like when we're done?

For (Jenkins pipeline, GitLab pipeline, GitOps flow)x(GCP, AWS, Azure stacks):

  • Blog describing how Crossplane should be used and working examples I can copy to:
    • configure target environments:
      • networks, subnets, target k8s clusters, default resource classes, credentials, etc.
    • rapidly cycle k8s app instances with cloud services
      • no app stacks, using resource claims only
      • with app stacks, pushing new app stack version
        • upgrading (in-place)
        • redeploying app instance (from-scratch)
  • Split into separate epic? Dogfood repo/pipeline is set up and running to implement a true GitOps continuous delivery scenario. Some infrastructure and application is deployed and managed entirely from this GitOps pipeline. Mattermost. config repo. pipelines all setup in that repo. first time pipeline runs it spins up Mattermost, which exists, then change to repo, edit some config, pipeline runs and updates the real matter most server in the wild. Live up-and-running instance controlled and configured by GitOps pipeline and repo.
  • Crossplane enhancements to improve CI/CD pipeline UX as required

How could this be demonstrated?

  1. Crossplane user reads the blog post describing this new functionality
  2. Click through to the updated user guide
  3. Try out the updated example(s)
  4. View the dogfood GitOps CD pipeline as a real functional example

For (Jenkins pipeline, GitLab pipeline, GitOps flow)x(GCP stack, AWS stack, Azure stack):

  • Read blog, follow examples, demonstrate using Crossplane infra & apps stacks

Releases:

Related:

@prasek prasek added this to the v0.3 milestone Jul 31, 2019
@prasek prasek added the status/consider considering for a milestone label Aug 27, 2019
@jbw976 jbw976 removed this from the v0.3 milestone Sep 13, 2019
@prasek prasek changed the title CI/CD pipeline examples: GCP and AWS infra stacks in Jenkins, GitLab, and a GitOps flow CI/CD pipeline examples: GCP and AWS infra stacks in Jenkins, GitLab, and Argo CD GitOps Sep 27, 2019
@jbw976 jbw976 changed the title CI/CD pipeline examples: GCP and AWS infra stacks in Jenkins, GitLab, and Argo CD GitOps CI/CD pipeline examples and dogfooding: GCP and AWS infra stacks in Jenkins, GitLab, and Argo CD GitOps Oct 2, 2019
@soorena776 soorena776 changed the title CI/CD pipeline examples and dogfooding: GCP and AWS infra stacks in Jenkins, GitLab, and Argo CD GitOps CI/CD pipeline examples and dogfooding: GCP, AWS and Azure infra stacks in Jenkins, GitLab, and Argo CD GitOps Oct 4, 2019
@soorena776 soorena776 changed the title CI/CD pipeline examples and dogfooding: GCP, AWS and Azure infra stacks in Jenkins, GitLab, and Argo CD GitOps CI/CD pipeline examples and dogfooding: GCP, AWS and Azure infra stacks in GitLab, Jenkins, ArgoCD Oct 7, 2019
@soorena776 soorena776 changed the title CI/CD pipeline examples and dogfooding: GCP, AWS and Azure infra stacks in GitLab, Jenkins, ArgoCD CI/CD pipeline examples and dog fooding: GCP, AWS and Azure infra stacks in GitLab, ArgoCD, Jenkins Oct 7, 2019
@prasek prasek changed the title CI/CD pipeline examples and dog fooding: GCP, AWS and Azure infra stacks in GitLab, ArgoCD, Jenkins CI/CD pipeline examples: GCP, AWS and Azure infra stacks in GitLab, ArgoCD, Jenkins Oct 14, 2019
@hasheddan hasheddan assigned hasheddan and unassigned soorena776 Nov 4, 2019
@negz negz closed this as completed Mar 31, 2020
@muvaf
Copy link
Member

muvaf commented Apr 1, 2020

@negz Why is this not considered useful anymore?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
services status/consider considering for a milestone
Projects
None yet
Development

No branches or pull requests

6 participants