integrating developer and operator experience in k8s
play

INTEGRATING DEVELOPER AND OPERATOR EXPERIENCE IN K8S BRENDAN BURNS - PowerPoint PPT Presentation

INTEGRATING DEVELOPER AND OPERATOR EXPERIENCE IN K8S BRENDAN BURNS VELOCITY NYC - 2018 FIRST A QUESTION? Do you love your development environment? FIRST A QUESTION? (OR TWO) Do you love your development environment? Does your


  1. INTEGRATING DEVELOPER AND OPERATOR EXPERIENCE IN K8S BRENDAN BURNS VELOCITY – NYC - 2018

  2. FIRST A QUESTION? • Do you love your development environment?

  3. FIRST A QUESTION? (OR TWO) • Do you love your development environment? • Does your development environment love you?

  4. WHAT DO I MEAN? • We're editing code in the cloud • We're building code in the cloud • We're deploying code in the cloud • We're debugging code in the cloud

  5. WHAT DO I MEAN? • But our tools are tied to a single machine • And often our tools are confined to a single persona - --- ----- -- … ----

  6. GOALS AND NON-GOALS Goals: • Make developing, testing, deploying and debugging seamless • Build modular, composable tooling experiences Non-goals: • Develop an all-encompassing "railed" experience • Assuming that everyone will use these tools (all or some)

  7. A QUICK WORD FROM OUR SPONSORS... • J/K

  8. THE 'I' IN 'IDE' IS FOR INTEGRATION • Code doesn't run in a vacuum • Most of the things our code 'integrates' with don't live on our machine • Some of this we're somewhat good at: • Git • Most of it, we're pretty bad at: • Services, Replication, Logs, …. • And even the things that are on the machine often aren't great...

  9. GETTING STARTED (WITH K8S) Compiler Docker kubectl Kubernetes Code Dockerfile YAML Image Service Binary

  10. GETTING STARTED (WITH K8S) Compiler Docker kubectl Kubernetes Code Dockerfile YAML Image Service Binary But tools can help!

  11. FIRST THINGS FIRST, A PLACE TO DEPLOY... • The deployment environment for code used to be implicit. • Not anymore. • But tools can help with that too...

  12. AND THEN THERE'S THAT WHOLE DOCKERFILE AND YAML THING... • Three files • Three tools • Three syntaxes • Just to deploy one app!

  13. DRAFT DEMO • https://draft.sh

  14. BUILDING MODERN TOOLS

  15. BUILDING MODERN TOOLS

  16. BUILDING MODERN TOOLS

  17. BUILDING AND DEPLOYING IMAGES Compiler Docker kubectl Kubernetes Code Dockerfile YAML Image Service Binary

  18. BUILDING AND DEPLOYING WITH DRAFT

  19. VISIBILITY (OR THE LACK THERE-OF)

  20. EXPLORING YOUR CLUSTER • Connect the development and deployment environment together • Browse your cluster • Visualize service health • Don't learn 'awk' (yet)

  21. CONNECTING TO YOUR APPLICATION • My code's in the cloud... Now what?

  22. EXPLORING YOUR PODS (AND CONTAINERS) • Integrating Pod logs • Integrating Pod terminal - apiVersion: v1 --- kind: Pod ----- metadata: -- name: foo ---- … logs pods/foo Hello world! Request handled …

  23. DEBUGGING YOUR CODE • Bringing your services to a local proxy

  24. DEBUGGING YOUR CODE • Synchronizing external state to your local repository - --- ----- -- func main() { ---- http.ListenAndServe(:80) } git checkout <hash>

  25. UPGRADING YOUR JOBS • Edit and visual diff.

  26. UPGRADING YOUR JOBS • Making the changes in a principled way

  27. LOOKING FORWARD • Cloud state and cloud experiences.

  28. LOOKING FORWARD • Merging logs from many different sources... - apiVersion --- kind: Pod ----- metadata: -- name: foo ---- … Hello world! Request handled { app: frontend, stage: production } …

  29. LOOKING FORWARD Cloud-idiomatic code

  30. LOOKING FORWARD const server = http.createServer((request, response) => { console.log(request.url); response.end(`Hello World: hostname: ${os.hostname()}\n`); }); mp.containerize( { repository: 'docker.io/docker-user-goes-here', }, () => { server.listen(port, (err) => { if (err) { return console.log('server startup error: ', err); } console.log(`server up on ${port}`); }); } ); https://metaparticle.io

  31. LOOKING FORWARD from metaparticle import containerize class MyHandler(SimpleHTTPServer.SimpleHTTPRequestHandler): … @containerize( 'docker.io/your-docker-user-goes-here', options={'name': 'my-image', 'publish': True}) def main(): Handler = MyHandler httpd = socketserver.TCPServer(("", port), Handler) httpd.serve_forever() if __name__ == '__main__’: main() https://metaparticle.io

  32. CONTRIBUTIONS NEEDED • What about monitoring? • What about collaboration? • Configuration languages? • https://github.com/Azure/vscode-kubernetes-tools • https://github.com/helm/helm

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend