namespace for repo company-wide convention each env (production, qa, sandbox) has a Kubernetes cluster same third-party services across all services commit hash as image tag automatic deploy after PR merged for most apps configuration build/deploy monitoring etc…
to invoke `kubectl set image` Use same image in every purpose prod, qa, and dev set image check pull deploy Fully managed The Latest k8s ops flow Automatic deploy to production
to build an app servicex • Log format and collection • Error collection • Performance monitoring • Distributed Tracing • Client Library for other services Following the rule has to be the easiest way Available in Golang, Ruby, Python Ideally less than an hour to deploy to the production a bootstrap document to launch a new app
rule has to be the easiest way In-house build/deploy tool Same tools in CI and laptops Automation is transparent to developers kube build kube prod deploy master to build and push a docker image to deploy to production to generate manifest files auto generated manifests kube generate autoscale
here install: - bash <(curl -sL https://get.wantedlyapp.com/kube) script: - kube build deploy: - skip_cleanup: true provider: script script: kube prod deploy $TRAVIS_COMMIT on: branch: master Every command works in local laptops Install kube build and push a docker image
here install: - bash <(curl -sL https://get.wantedlyapp.com/kube) script: - kube build deploy: - skip_cleanup: true provider: script script: kube prod deploy $TRAVIS_COMMIT on: branch: master deploy the revision Install kube build and push a docker image Every command works in local laptops
to k8s Dockerfile from scratch Faster Build Hack assets:precompile QA/Dev first Communication with the backend team Drop fast-rollback feature Drop automatic deploy As test for both Infra team and the backend team
tag Env Var Modern EC2 Travis Env Commit hash in images k8s secrets Deploy blue / green rolling Fully AWS Fully Managed Infra Modern has the best practice Strategy manual automatic
worth performing Enforcement to follow the conventions •same third-party services •commit hash as tag •automatic deploy •servicex a library to install everything •kube in CI and laptops •one namespace for one repo •temporary exception is ok •but, have to follow the rule sooner or later