Auto DevOps Challenges when moving design system to Auto DevOps
All steps needed
- Remove
.gitlab-ci.ymlbecause we don't need this when using auto devops: DylanGriffith/design.gitlab.com@452b59df - Add a K8s cluster on GKE and install tiller + ingress
- Enable autodevops and use suggested nip.io domain
- Updates to package.json to make it compatible:
- Add a stub
yarn testcommand as the test step will fail if there is no test command to run: DylanGriffith/design.gitlab.com@6f264f3b - Remove the hardcoded
PORTfromyarn startas auto devops deployment expects to provide this port variable: DylanGriffith/design.gitlab.com@b3e778e2 - Ensure
yarn startresults in listening on all interfaces not just loopback as we need to access port 5000 outside of the container. This resulted in constant restarts as the health checker was killing the application: DylanGriffith/design.gitlab.com@b3a43b92
- Add a stub
Things to improve
- We should have better error messages about needing a
yarn testcommand. This probably requires changes to herokuish so it gives more useful error messages after running/bin/herokuish buildpack test. We got this build log but nowhere does it say that it's trying to runyarn test. It should at least output the command that failed. But further it should tell you how to fix it by adding atestcommand to yourpackage.json - We need to either document or somehow make it automated that
yarn startwill result in listening on all interfaces for you. I thinkHOST=0.0.0.0probably works for a lot of web frameworks so maybe we can just add this variable to the pod.
Other thoughts
- This application does not need a database so we should set
POSTGRES_ENABLED=falseso we save resources on the cluster and perhaps speed up deployment. Could we detect this automatically? - The pipeline takes a very long time. We can speed up by setting
CONTAINER_SCANNING_DISABLED=truebut then we won't get this feature. It takes 5 minutes currently.
Edited by 🤖 GitLab Bot 🤖