SlideShare una empresa de Scribd logo
1 de 53
Instant Self-contained Development
Environments for Everyone
Yshay Yaacobi
CTO @ Livecycle
yshay@livecycle.io
yshayy
TWEEKATHON
@yshayy
About me
● CTO & co-founder of livecycle
● Full-stack developer for quite a time
● Passionate about cloud development,
backend architecture, UX/DX, functional
programming and Docker
● Creator & maintainer of Tweek - an open-source, “cloud-
native” feature management solution
● Things I care about in code: simplicity, consistency and elegance
@yshayy
About Livecycle
● Next generation collaboration tools for development teams
● Continuous playground environments
● Bridging the gap between coders & non-coders
● Soon in public beta
How does it feel like to start working on a new
complex codebase?
@yshayy
Try to build & run
● Wrong OS
● Missing or conflicting SDKs and/or PL runtimes
● Package managers throw “random” errors
@yshayy
Read README.md and try to make it work
● Run some magic scripts (and watch them fails)
● Change hosts file
● Install required tools & dependencies on the environment
● Install Root CA?
@yshayy
Try to develop
● Debugging doesn’t work
● IDE have problem with autocomplete or dependencies
● Code watch & build doesn’t work and we need watchman
● HMR doesn’t work because of websocket issues
● Problems with external dependencies
● CORS
Integration tests?
Do it all over again after few months of working
on something else....
@yshayy
Why is it so difficult?
● Different OSes (or versions)
● Lots of versions and fragmentation of sdk & runtimes
● Work on my machine syndrome
● Vast amount of different toolchains, IDEs, extensions
● Complex development flows that are difficult to setup and easily break:
○ Debugging, watching+building, hot-reloading, docker mounts
● Developers’ machines are polluted and overloaded with tools
● Environments and tools tend to change rapidly in active repositories
● ----> Waste of time and frustration!
The dream
Development environments that are...
Consistent
Provide the same predictable experience...
Reproducible
It’s possible to destroy & rebuild them
Isolated
Don’t or get affected by other environments
Self-Contained
All dependencies and tools needed for development
are defined & packaged inside
UNBREAKABLE
We won’t struggle countless hours to get things
working again
@yshayy
Running our environments in containers
@yshayy
Before we begin
● All examples & slides are available on Github
● All tools used in this presentation are OSS or free-to-use projects
● Most examples here are far from bullet-proof and some of them use tools that
can be considered experimental
@yshayy
Example #1 - qeesung/image2ascii
CLI tool for creating ASCII art from images
● Project written in Go
● Before Go modules
@yshayy
The Development Container
● Integration with SCM
● Remote code editing
● Remote terminal
@yshayy
Configuring our environment
● Setting Runtime/SDKS/CLIs
● Setting environment variables and path
● Configure our shell
● Defining extensions
@yshayy
Example #2 - yshayy/email-sender
Simple Flask app to send email based on SendGrid example
New challenges
● Running & interacting with a server
● Managing secrets
● Debugging
@yshayy
Secrets Encryption
● Secrets sit inside the repository
● Using Mozilla Sops for encrypting secrets
● GPG keys are nice for start, but it can also integrate with cloud encryptions-as-
service solution such as KMS, KeyVault
● MetaData is saved unencrypted which make it easy to do diffing and check
history
● Practice usually used in GitOps context
● Other solutions - git-secret, git-crypt, Kamus, SealedSecrets, etc...
@yshayy
IDE settings
● Launch settings - launch.json
● Port forwarding - forwarding port on the localhost
@yshayy
#3 HabitRPG/Habitica
OSS Web-based RPG for organizing your life
New Challenges
● Huge project
● Front end
● Backend
● DB
@yshayy
Full-stack application
● Docker-compose
● DB Image
● Additional tools
@yshayy
Data seeding
● Basic scripts
● Alternatively, we can clone data from staging/production
@yshayy
Use reverse proxy
● Route services to several subdomains instead of ports
● Wildcard “localhost” dns-es (localtest.me, xip)
● Traefik - a very simple and developer friendly reverse proxy
The next one is personal...
@yshayy
#4 - Soluto/Tweek
Cloud-native open-source feature flags and configuration management
New challenges
● Several microservices
● Several DBs/Messaging systems
● Cross service communications
● Polyglot environment
@yshayy
Complex architecture
@yshayy
“Nested” containers
● Docker-in-docker vs docker-from-docker
● Development in nested containers with Tilt + Docker-Compose
○ Watching & rebuilding on every code commit
○ Remote debugging
○ “Hot” code reloading if possible
● Things can get slower...
@yshayy
“Mock” cloud dependencies
● Docker images of databases (redis, mongo, postgres, etc…)
● Wire-compatible solutions (Minio, OIDC mock server)
● Manual mocks
● Full frameworks (localstack)
● Encrypted credentials with dedicated tenants. (or dynamic provisioning)
@yshayy
#5 - kubecost/cost-model
Tool for managing kubernetes costs
New challenges
● We need kubernetes
● Metrics server
● Prometheus
@yshayy
What can we do with Kubernetes?
● Kubernetes local development is already difficult
○ Fragmentation - Mini-kube, Docker for Desktop k8s, micro-k8s, kind, k3s, etc…
○ Versioning
○ Upgrading
● Using a single kubernetes distro+version can make life easy
@yshayy
Kubernetes in dev-container
● K3S - minimal kubernetes distribution
● K3D - Make it easy to run k3s and a dedicated registry inside Docker
● Stable and cluster can be re-created
● Helm controller for installing helm charts declaratively
● Tilt facilitate building/pushing/running
@yshayy
Docker Host
Dev Container
IDE
Tilt
Docker-in-Docker
Registry
K3S Node
ContainerD
App
To put it “simply”....
@yshayy
No more demos…
@yshayy
Containerized development environments
● Development environment configuration is also source-controlled and
correspond to the application code.
● Developer machine stays clean
● Can scale well to multiple environments without conflicts
● Can run locally or remotely
@yshayy
Our setup
● ~10 microservices in Golang & typescript/js
● Frontend with HMR
● Our own Kubernetes CR and controllers
● External dependencies (GH api, sendgrid, auth0, etc…)
● DB + Graphql engine
● A full blown CI system
● Container Registry
● Dynamic dns subdomains
● SSL Certs for local development
● Multiple CLI/SDKs for kubernetes and code-generation
@yshayy
Results
● Time to teardown and download/rebuild all cluster and dependencies <15m
● Time to build/run/test code changes < 10s
● Time to onboard new developer < 3h
(including remote provisioning of a dedicated host on AWS)
● Time to introduce new tool and update dev-environments if needed <5m)
● No “works on my machine” occurrences
● No strain on developer machines
● Developers need to deal less with secrets
● Our team work on both M1 and Intel Macs
@yshayy
Future optimizations
● Shared build cache
● Snapshots (for reducing time or sharing state)
● Using a cloud provider optimized for dev-machines (cost, location, hibernation,
cpu/ram, etc...)
@yshayy
Drawbacks
● Creating the initial setup can take some time
● Many tools, some are bleeding-edge
● Additional code to manage
● Dev-Environments are not standardized yet
● Coupling to VS-Code, Docker, Git and Linux
● Some performance issues
● Security challenges between development and production context
@yshayy
Alternatives to VS Code?
● It’s possible to use terminal based code-editors
● GitPod.io & Theia have similar features with gitpod.yaml
● Jetbrains Projector
● Run local IDE with Docker mounts
@yshayy
What about serverless?
● Should work although some pieces might be missing
● FaaS frameworks and sdks usually can run locally
● For the other PaaS features - cloud mocking frameworks, emulators or wire
compatible solutions. (localstack, minio, etc…)
● If necessary, throw IaC tools to the mix (pulumi/terraform) for dynamic
provisioning
@yshayy
What about native mobile?
● The problem still exists, developers can engage in epic battles with mobile IDEs,
workspace, build and debug.
● It might be possible to stream applications with VNC/WebRTC during
development, but experience is not optimal
● Mobile-emulators are heavy and can require nested virtualization to perform
● Container ecosystem is optimized for Linux
● IDEs for mobile are very tailored for mobile development
● Might be easier/possible with more cross-platform frameworks such as react-
native/flutter
@yshayy
Part of a larger trend to put more stuff in the repository
● Linting, style guidelines
● Declarative application dependencies
● Documentation
● OpenAPI Specification
● CI Pipelines definition
● Workflows (PR)
● Design systems
● Infrastructure-As-Code
● Secrets (encrypted)
● Dashboards/alerts/SLA configuration
● Notebooks
● ...
@yshayy
Self-Contained Repositories
● All code, tools, knowledge, definitions and processes related to project resides
in the repository.
● Git as the single source of truth
● Code is more accessible, lowering the barrier of entry
● Applications are portable
● Fine-grained developer experience
● Emerging tools ecosystem
@yshayy
Patterns & Cheatsheet
Challenge Solution Exampletools
Basic SDK/Runtime
dependencies
Development in
container
VSCode+Docker, GitPod
Cloud dependencies Compatible dockerized
implementations
Minio, redis
Initial application data Data seeding Scripts, replicating from cloud
More hardware Remote environment Docker-machine, codespaces
Multi-Container Apps Nested Containers Dind, compose, tilt
Kubernetes Apps Nested Kubernetes Kind, k3d, tilt, skaffold
Exposing network
dependencies
Reverse proxy, wild card
development dns
Traefik, nginx, *.xip, *.localtest.me
Serverless Mock cloud frameworks Localstack
Thank you
@yshayy
https://github.com/yshayy/self-contained-repositories
Questions

Más contenido relacionado

La actualidad más candente

[D2 COMMUNITY] Open Container Seoul Meetup - Kubernetes를 이용한 서비스 구축과 openshift
[D2 COMMUNITY] Open Container Seoul Meetup - Kubernetes를 이용한 서비스 구축과 openshift[D2 COMMUNITY] Open Container Seoul Meetup - Kubernetes를 이용한 서비스 구축과 openshift
[D2 COMMUNITY] Open Container Seoul Meetup - Kubernetes를 이용한 서비스 구축과 openshiftNAVER D2
 
[DevConf.US 2019]Quarkus Brings Serverless to Java Developers
[DevConf.US 2019]Quarkus Brings Serverless to Java Developers[DevConf.US 2019]Quarkus Brings Serverless to Java Developers
[DevConf.US 2019]Quarkus Brings Serverless to Java DevelopersDaniel Oh
 
Going deep (learning) with tensor flow and quarkus
Going deep (learning) with tensor flow and quarkusGoing deep (learning) with tensor flow and quarkus
Going deep (learning) with tensor flow and quarkusRed Hat Developers
 
PHPIDOL#80: Kubernetes 101 for PHP Developer. Yusuf Hadiwinata - VP Operation...
PHPIDOL#80: Kubernetes 101 for PHP Developer. Yusuf Hadiwinata - VP Operation...PHPIDOL#80: Kubernetes 101 for PHP Developer. Yusuf Hadiwinata - VP Operation...
PHPIDOL#80: Kubernetes 101 for PHP Developer. Yusuf Hadiwinata - VP Operation...Yusuf Hadiwinata Sutandar
 
Secure your Quarkus applications | DevNation Tech Talk
Secure your Quarkus applications | DevNation Tech TalkSecure your Quarkus applications | DevNation Tech Talk
Secure your Quarkus applications | DevNation Tech TalkRed Hat Developers
 
16. Cncf meetup-docker
16. Cncf meetup-docker16. Cncf meetup-docker
16. Cncf meetup-dockerJuraj Hantak
 
Cloud Foundry Summit 2015: Managing Multiple Cloud with a Single BOSH Deploym...
Cloud Foundry Summit 2015: Managing Multiple Cloud with a Single BOSH Deploym...Cloud Foundry Summit 2015: Managing Multiple Cloud with a Single BOSH Deploym...
Cloud Foundry Summit 2015: Managing Multiple Cloud with a Single BOSH Deploym...VMware Tanzu
 
Sebastien goasguen cloud stack and docker
Sebastien goasguen   cloud stack and dockerSebastien goasguen   cloud stack and docker
Sebastien goasguen cloud stack and dockerShapeBlue
 
KUBEBOOT - SPRING BOOT DEPLOYMENT ON KUBERNETES
KUBEBOOT - SPRING BOOT DEPLOYMENT ON KUBERNETESKUBEBOOT - SPRING BOOT DEPLOYMENT ON KUBERNETES
KUBEBOOT - SPRING BOOT DEPLOYMENT ON KUBERNETESAlex Soto
 
Azure ai on premises with docker
Azure ai on premises with  dockerAzure ai on premises with  docker
Azure ai on premises with dockerVishwas N
 
Your journey into the serverless world
Your journey into the serverless worldYour journey into the serverless world
Your journey into the serverless worldRed Hat Developers
 
Introduction to Kubernetes - Docker Global Mentor Week 2016
Introduction to Kubernetes - Docker Global Mentor Week 2016Introduction to Kubernetes - Docker Global Mentor Week 2016
Introduction to Kubernetes - Docker Global Mentor Week 2016Opsta
 
CI/CD with Openshift and Jenkins
CI/CD with Openshift and JenkinsCI/CD with Openshift and Jenkins
CI/CD with Openshift and JenkinsAri LiVigni
 
Deploy your favorite apps on Kubernetes
Deploy your favorite apps on KubernetesDeploy your favorite apps on Kubernetes
Deploy your favorite apps on KubernetesAdnan Abdulhussein
 
Kubernetes from the ground up
Kubernetes from the ground upKubernetes from the ground up
Kubernetes from the ground upSander Knape
 
Kubernetes for Serverless - Serverless Summit 2017 - Krishna Kumar
Kubernetes for Serverless  - Serverless Summit 2017 - Krishna KumarKubernetes for Serverless  - Serverless Summit 2017 - Krishna Kumar
Kubernetes for Serverless - Serverless Summit 2017 - Krishna KumarCodeOps Technologies LLP
 
Discover Quarkus and GraalVM
Discover Quarkus and GraalVMDiscover Quarkus and GraalVM
Discover Quarkus and GraalVMRomain Schlick
 
Quarkus on Knative at Red Hat Summit 2019
Quarkus on Knative at Red Hat Summit 2019Quarkus on Knative at Red Hat Summit 2019
Quarkus on Knative at Red Hat Summit 2019Daniel Oh
 
[Srijan Wednesday Webinar] How to Run Stateless and Stateful Services on K8S ...
[Srijan Wednesday Webinar] How to Run Stateless and Stateful Services on K8S ...[Srijan Wednesday Webinar] How to Run Stateless and Stateful Services on K8S ...
[Srijan Wednesday Webinar] How to Run Stateless and Stateful Services on K8S ...Srijan Technologies
 

La actualidad más candente (20)

[D2 COMMUNITY] Open Container Seoul Meetup - Kubernetes를 이용한 서비스 구축과 openshift
[D2 COMMUNITY] Open Container Seoul Meetup - Kubernetes를 이용한 서비스 구축과 openshift[D2 COMMUNITY] Open Container Seoul Meetup - Kubernetes를 이용한 서비스 구축과 openshift
[D2 COMMUNITY] Open Container Seoul Meetup - Kubernetes를 이용한 서비스 구축과 openshift
 
[DevConf.US 2019]Quarkus Brings Serverless to Java Developers
[DevConf.US 2019]Quarkus Brings Serverless to Java Developers[DevConf.US 2019]Quarkus Brings Serverless to Java Developers
[DevConf.US 2019]Quarkus Brings Serverless to Java Developers
 
On Prem Container Cloud - Lessons Learned
On Prem Container Cloud - Lessons LearnedOn Prem Container Cloud - Lessons Learned
On Prem Container Cloud - Lessons Learned
 
Going deep (learning) with tensor flow and quarkus
Going deep (learning) with tensor flow and quarkusGoing deep (learning) with tensor flow and quarkus
Going deep (learning) with tensor flow and quarkus
 
PHPIDOL#80: Kubernetes 101 for PHP Developer. Yusuf Hadiwinata - VP Operation...
PHPIDOL#80: Kubernetes 101 for PHP Developer. Yusuf Hadiwinata - VP Operation...PHPIDOL#80: Kubernetes 101 for PHP Developer. Yusuf Hadiwinata - VP Operation...
PHPIDOL#80: Kubernetes 101 for PHP Developer. Yusuf Hadiwinata - VP Operation...
 
Secure your Quarkus applications | DevNation Tech Talk
Secure your Quarkus applications | DevNation Tech TalkSecure your Quarkus applications | DevNation Tech Talk
Secure your Quarkus applications | DevNation Tech Talk
 
16. Cncf meetup-docker
16. Cncf meetup-docker16. Cncf meetup-docker
16. Cncf meetup-docker
 
Cloud Foundry Summit 2015: Managing Multiple Cloud with a Single BOSH Deploym...
Cloud Foundry Summit 2015: Managing Multiple Cloud with a Single BOSH Deploym...Cloud Foundry Summit 2015: Managing Multiple Cloud with a Single BOSH Deploym...
Cloud Foundry Summit 2015: Managing Multiple Cloud with a Single BOSH Deploym...
 
Sebastien goasguen cloud stack and docker
Sebastien goasguen   cloud stack and dockerSebastien goasguen   cloud stack and docker
Sebastien goasguen cloud stack and docker
 
KUBEBOOT - SPRING BOOT DEPLOYMENT ON KUBERNETES
KUBEBOOT - SPRING BOOT DEPLOYMENT ON KUBERNETESKUBEBOOT - SPRING BOOT DEPLOYMENT ON KUBERNETES
KUBEBOOT - SPRING BOOT DEPLOYMENT ON KUBERNETES
 
Azure ai on premises with docker
Azure ai on premises with  dockerAzure ai on premises with  docker
Azure ai on premises with docker
 
Your journey into the serverless world
Your journey into the serverless worldYour journey into the serverless world
Your journey into the serverless world
 
Introduction to Kubernetes - Docker Global Mentor Week 2016
Introduction to Kubernetes - Docker Global Mentor Week 2016Introduction to Kubernetes - Docker Global Mentor Week 2016
Introduction to Kubernetes - Docker Global Mentor Week 2016
 
CI/CD with Openshift and Jenkins
CI/CD with Openshift and JenkinsCI/CD with Openshift and Jenkins
CI/CD with Openshift and Jenkins
 
Deploy your favorite apps on Kubernetes
Deploy your favorite apps on KubernetesDeploy your favorite apps on Kubernetes
Deploy your favorite apps on Kubernetes
 
Kubernetes from the ground up
Kubernetes from the ground upKubernetes from the ground up
Kubernetes from the ground up
 
Kubernetes for Serverless - Serverless Summit 2017 - Krishna Kumar
Kubernetes for Serverless  - Serverless Summit 2017 - Krishna KumarKubernetes for Serverless  - Serverless Summit 2017 - Krishna Kumar
Kubernetes for Serverless - Serverless Summit 2017 - Krishna Kumar
 
Discover Quarkus and GraalVM
Discover Quarkus and GraalVMDiscover Quarkus and GraalVM
Discover Quarkus and GraalVM
 
Quarkus on Knative at Red Hat Summit 2019
Quarkus on Knative at Red Hat Summit 2019Quarkus on Knative at Red Hat Summit 2019
Quarkus on Knative at Red Hat Summit 2019
 
[Srijan Wednesday Webinar] How to Run Stateless and Stateful Services on K8S ...
[Srijan Wednesday Webinar] How to Run Stateless and Stateful Services on K8S ...[Srijan Wednesday Webinar] How to Run Stateless and Stateful Services on K8S ...
[Srijan Wednesday Webinar] How to Run Stateless and Stateful Services on K8S ...
 

Similar a Instant developer onboarding with self contained repositories

Building a Pluggable, Cloud-native Event-driven Serverless Architecture - Rea...
Building a Pluggable, Cloud-native Event-driven Serverless Architecture - Rea...Building a Pluggable, Cloud-native Event-driven Serverless Architecture - Rea...
Building a Pluggable, Cloud-native Event-driven Serverless Architecture - Rea...Dan Farrelly
 
Modern Web-site Development Pipeline
Modern Web-site Development PipelineModern Web-site Development Pipeline
Modern Web-site Development PipelineGlobalLogic Ukraine
 
Kubernetes, Toolbox to fail or succeed for beginners - Demi Ben-Ari, VP R&D @...
Kubernetes, Toolbox to fail or succeed for beginners - Demi Ben-Ari, VP R&D @...Kubernetes, Toolbox to fail or succeed for beginners - Demi Ben-Ari, VP R&D @...
Kubernetes, Toolbox to fail or succeed for beginners - Demi Ben-Ari, VP R&D @...Demi Ben-Ari
 
Docker. Does it matter for Java developer ?
Docker. Does it matter for Java developer ?Docker. Does it matter for Java developer ?
Docker. Does it matter for Java developer ?Izzet Mustafaiev
 
Not my problem - Delegating responsibility to infrastructure
Not my problem - Delegating responsibility to infrastructureNot my problem - Delegating responsibility to infrastructure
Not my problem - Delegating responsibility to infrastructureYshay Yaacobi
 
Introduction to Modern DevOps Technologies
Introduction to  Modern DevOps TechnologiesIntroduction to  Modern DevOps Technologies
Introduction to Modern DevOps TechnologiesKriangkrai Chaonithi
 
Настройка окружения для кросскомпиляции проектов на основе docker'a
Настройка окружения для кросскомпиляции проектов на основе docker'aНастройка окружения для кросскомпиляции проектов на основе docker'a
Настройка окружения для кросскомпиляции проектов на основе docker'acorehard_by
 
Containers: from development to production at DevNation 2015
Containers: from development to production at DevNation 2015Containers: from development to production at DevNation 2015
Containers: from development to production at DevNation 2015Jérôme Petazzoni
 
A vision of persistence
A vision of persistenceA vision of persistence
A vision of persistenceDocker, Inc.
 
Developer workflow with docker
Developer workflow with dockerDeveloper workflow with docker
Developer workflow with dockerLalatendu Mohanty
 
Philipe Riand - Building Social Applications using the Social Business Toolki...
Philipe Riand - Building Social Applications using the Social Business Toolki...Philipe Riand - Building Social Applications using the Social Business Toolki...
Philipe Riand - Building Social Applications using the Social Business Toolki...LetsConnect
 
Designing flexible apps deployable to App Engine, Cloud Functions, or Cloud Run
Designing flexible apps deployable to App Engine, Cloud Functions, or Cloud RunDesigning flexible apps deployable to App Engine, Cloud Functions, or Cloud Run
Designing flexible apps deployable to App Engine, Cloud Functions, or Cloud Runwesley chun
 
Developing the Stratoscale System at Scale - Muli Ben-Yehuda, Stratoscale - D...
Developing the Stratoscale System at Scale - Muli Ben-Yehuda, Stratoscale - D...Developing the Stratoscale System at Scale - Muli Ben-Yehuda, Stratoscale - D...
Developing the Stratoscale System at Scale - Muli Ben-Yehuda, Stratoscale - D...DevOpsDays Tel Aviv
 
Bgoug 2019.11 building free, open-source, plsql products in cloud
Bgoug 2019.11   building free, open-source, plsql products in cloudBgoug 2019.11   building free, open-source, plsql products in cloud
Bgoug 2019.11 building free, open-source, plsql products in cloudJacek Gebal
 
Who needs containers in a serverless world
Who needs containers in a serverless worldWho needs containers in a serverless world
Who needs containers in a serverless worldMatthias Luebken
 
[20200720]cloud native develoment - Nelson Lin
[20200720]cloud native develoment - Nelson Lin[20200720]cloud native develoment - Nelson Lin
[20200720]cloud native develoment - Nelson LinHanLing Shen
 
Podman, Buildah, and Quarkus - The Latest in Linux Containers Technologies
Podman, Buildah, and Quarkus - The Latest in Linux Containers Technologies Podman, Buildah, and Quarkus - The Latest in Linux Containers Technologies
Podman, Buildah, and Quarkus - The Latest in Linux Containers Technologies Daniel Oh
 
AirBNB's ML platform - BigHead
AirBNB's ML platform - BigHeadAirBNB's ML platform - BigHead
AirBNB's ML platform - BigHeadKarthik Murugesan
 

Similar a Instant developer onboarding with self contained repositories (20)

Building a Pluggable, Cloud-native Event-driven Serverless Architecture - Rea...
Building a Pluggable, Cloud-native Event-driven Serverless Architecture - Rea...Building a Pluggable, Cloud-native Event-driven Serverless Architecture - Rea...
Building a Pluggable, Cloud-native Event-driven Serverless Architecture - Rea...
 
Modern Web-site Development Pipeline
Modern Web-site Development PipelineModern Web-site Development Pipeline
Modern Web-site Development Pipeline
 
Kubernetes, Toolbox to fail or succeed for beginners - Demi Ben-Ari, VP R&D @...
Kubernetes, Toolbox to fail or succeed for beginners - Demi Ben-Ari, VP R&D @...Kubernetes, Toolbox to fail or succeed for beginners - Demi Ben-Ari, VP R&D @...
Kubernetes, Toolbox to fail or succeed for beginners - Demi Ben-Ari, VP R&D @...
 
Docker. Does it matter for Java developer ?
Docker. Does it matter for Java developer ?Docker. Does it matter for Java developer ?
Docker. Does it matter for Java developer ?
 
DDD with Behat
DDD with BehatDDD with Behat
DDD with Behat
 
Not my problem - Delegating responsibility to infrastructure
Not my problem - Delegating responsibility to infrastructureNot my problem - Delegating responsibility to infrastructure
Not my problem - Delegating responsibility to infrastructure
 
Introduction to Modern DevOps Technologies
Introduction to  Modern DevOps TechnologiesIntroduction to  Modern DevOps Technologies
Introduction to Modern DevOps Technologies
 
JOSA TechTalks - Docker in Production
JOSA TechTalks - Docker in ProductionJOSA TechTalks - Docker in Production
JOSA TechTalks - Docker in Production
 
Настройка окружения для кросскомпиляции проектов на основе docker'a
Настройка окружения для кросскомпиляции проектов на основе docker'aНастройка окружения для кросскомпиляции проектов на основе docker'a
Настройка окружения для кросскомпиляции проектов на основе docker'a
 
Containers: from development to production at DevNation 2015
Containers: from development to production at DevNation 2015Containers: from development to production at DevNation 2015
Containers: from development to production at DevNation 2015
 
A vision of persistence
A vision of persistenceA vision of persistence
A vision of persistence
 
Developer workflow with docker
Developer workflow with dockerDeveloper workflow with docker
Developer workflow with docker
 
Philipe Riand - Building Social Applications using the Social Business Toolki...
Philipe Riand - Building Social Applications using the Social Business Toolki...Philipe Riand - Building Social Applications using the Social Business Toolki...
Philipe Riand - Building Social Applications using the Social Business Toolki...
 
Designing flexible apps deployable to App Engine, Cloud Functions, or Cloud Run
Designing flexible apps deployable to App Engine, Cloud Functions, or Cloud RunDesigning flexible apps deployable to App Engine, Cloud Functions, or Cloud Run
Designing flexible apps deployable to App Engine, Cloud Functions, or Cloud Run
 
Developing the Stratoscale System at Scale - Muli Ben-Yehuda, Stratoscale - D...
Developing the Stratoscale System at Scale - Muli Ben-Yehuda, Stratoscale - D...Developing the Stratoscale System at Scale - Muli Ben-Yehuda, Stratoscale - D...
Developing the Stratoscale System at Scale - Muli Ben-Yehuda, Stratoscale - D...
 
Bgoug 2019.11 building free, open-source, plsql products in cloud
Bgoug 2019.11   building free, open-source, plsql products in cloudBgoug 2019.11   building free, open-source, plsql products in cloud
Bgoug 2019.11 building free, open-source, plsql products in cloud
 
Who needs containers in a serverless world
Who needs containers in a serverless worldWho needs containers in a serverless world
Who needs containers in a serverless world
 
[20200720]cloud native develoment - Nelson Lin
[20200720]cloud native develoment - Nelson Lin[20200720]cloud native develoment - Nelson Lin
[20200720]cloud native develoment - Nelson Lin
 
Podman, Buildah, and Quarkus - The Latest in Linux Containers Technologies
Podman, Buildah, and Quarkus - The Latest in Linux Containers Technologies Podman, Buildah, and Quarkus - The Latest in Linux Containers Technologies
Podman, Buildah, and Quarkus - The Latest in Linux Containers Technologies
 
AirBNB's ML platform - BigHead
AirBNB's ML platform - BigHeadAirBNB's ML platform - BigHead
AirBNB's ML platform - BigHead
 

Último

How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerThousandEyes
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providermohitmore19
 
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdfAzure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdfryanfarris8
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdfPearlKirahMaeRagusta1
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comFatema Valibhai
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Steffen Staab
 
10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024Mind IT Systems
 
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension AidPhilip Schwarz
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionSolGuruz
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVshikhaohhpro
 
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...kalichargn70th171
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxComplianceQuest1
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Modelsaagamshah0812
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️Delhi Call girls
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...ICS
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...Health
 
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesVictorSzoltysek
 

Último (20)

How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdfAzure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdf
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.com
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
 
10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024
 
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
 
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdfMicrosoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdf
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with Precision
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docx
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS LiveVip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
 
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
 

Instant developer onboarding with self contained repositories

  • 1. Instant Self-contained Development Environments for Everyone Yshay Yaacobi CTO @ Livecycle yshay@livecycle.io yshayy
  • 3. @yshayy About me ● CTO & co-founder of livecycle ● Full-stack developer for quite a time ● Passionate about cloud development, backend architecture, UX/DX, functional programming and Docker ● Creator & maintainer of Tweek - an open-source, “cloud- native” feature management solution ● Things I care about in code: simplicity, consistency and elegance
  • 4. @yshayy About Livecycle ● Next generation collaboration tools for development teams ● Continuous playground environments ● Bridging the gap between coders & non-coders ● Soon in public beta
  • 5. How does it feel like to start working on a new complex codebase?
  • 6. @yshayy Try to build & run ● Wrong OS ● Missing or conflicting SDKs and/or PL runtimes ● Package managers throw “random” errors
  • 7. @yshayy Read README.md and try to make it work ● Run some magic scripts (and watch them fails) ● Change hosts file ● Install required tools & dependencies on the environment ● Install Root CA?
  • 8. @yshayy Try to develop ● Debugging doesn’t work ● IDE have problem with autocomplete or dependencies ● Code watch & build doesn’t work and we need watchman ● HMR doesn’t work because of websocket issues ● Problems with external dependencies ● CORS
  • 10. Do it all over again after few months of working on something else....
  • 11. @yshayy Why is it so difficult? ● Different OSes (or versions) ● Lots of versions and fragmentation of sdk & runtimes ● Work on my machine syndrome ● Vast amount of different toolchains, IDEs, extensions ● Complex development flows that are difficult to setup and easily break: ○ Debugging, watching+building, hot-reloading, docker mounts ● Developers’ machines are polluted and overloaded with tools ● Environments and tools tend to change rapidly in active repositories ● ----> Waste of time and frustration!
  • 13. Consistent Provide the same predictable experience...
  • 14. Reproducible It’s possible to destroy & rebuild them
  • 15. Isolated Don’t or get affected by other environments
  • 16. Self-Contained All dependencies and tools needed for development are defined & packaged inside
  • 17. UNBREAKABLE We won’t struggle countless hours to get things working again
  • 19. @yshayy Before we begin ● All examples & slides are available on Github ● All tools used in this presentation are OSS or free-to-use projects ● Most examples here are far from bullet-proof and some of them use tools that can be considered experimental
  • 20. @yshayy Example #1 - qeesung/image2ascii CLI tool for creating ASCII art from images ● Project written in Go ● Before Go modules
  • 21. @yshayy The Development Container ● Integration with SCM ● Remote code editing ● Remote terminal
  • 22. @yshayy Configuring our environment ● Setting Runtime/SDKS/CLIs ● Setting environment variables and path ● Configure our shell ● Defining extensions
  • 23. @yshayy Example #2 - yshayy/email-sender Simple Flask app to send email based on SendGrid example New challenges ● Running & interacting with a server ● Managing secrets ● Debugging
  • 24. @yshayy Secrets Encryption ● Secrets sit inside the repository ● Using Mozilla Sops for encrypting secrets ● GPG keys are nice for start, but it can also integrate with cloud encryptions-as- service solution such as KMS, KeyVault ● MetaData is saved unencrypted which make it easy to do diffing and check history ● Practice usually used in GitOps context ● Other solutions - git-secret, git-crypt, Kamus, SealedSecrets, etc...
  • 25. @yshayy IDE settings ● Launch settings - launch.json ● Port forwarding - forwarding port on the localhost
  • 26. @yshayy #3 HabitRPG/Habitica OSS Web-based RPG for organizing your life New Challenges ● Huge project ● Front end ● Backend ● DB
  • 28. @yshayy Data seeding ● Basic scripts ● Alternatively, we can clone data from staging/production
  • 29. @yshayy Use reverse proxy ● Route services to several subdomains instead of ports ● Wildcard “localhost” dns-es (localtest.me, xip) ● Traefik - a very simple and developer friendly reverse proxy
  • 30. The next one is personal...
  • 31. @yshayy #4 - Soluto/Tweek Cloud-native open-source feature flags and configuration management New challenges ● Several microservices ● Several DBs/Messaging systems ● Cross service communications ● Polyglot environment
  • 33. @yshayy “Nested” containers ● Docker-in-docker vs docker-from-docker ● Development in nested containers with Tilt + Docker-Compose ○ Watching & rebuilding on every code commit ○ Remote debugging ○ “Hot” code reloading if possible ● Things can get slower...
  • 34. @yshayy “Mock” cloud dependencies ● Docker images of databases (redis, mongo, postgres, etc…) ● Wire-compatible solutions (Minio, OIDC mock server) ● Manual mocks ● Full frameworks (localstack) ● Encrypted credentials with dedicated tenants. (or dynamic provisioning)
  • 35. @yshayy #5 - kubecost/cost-model Tool for managing kubernetes costs New challenges ● We need kubernetes ● Metrics server ● Prometheus
  • 36. @yshayy What can we do with Kubernetes? ● Kubernetes local development is already difficult ○ Fragmentation - Mini-kube, Docker for Desktop k8s, micro-k8s, kind, k3s, etc… ○ Versioning ○ Upgrading ● Using a single kubernetes distro+version can make life easy
  • 37. @yshayy Kubernetes in dev-container ● K3S - minimal kubernetes distribution ● K3D - Make it easy to run k3s and a dedicated registry inside Docker ● Stable and cluster can be re-created ● Helm controller for installing helm charts declaratively ● Tilt facilitate building/pushing/running
  • 38. @yshayy Docker Host Dev Container IDE Tilt Docker-in-Docker Registry K3S Node ContainerD App To put it “simply”....
  • 41. @yshayy Containerized development environments ● Development environment configuration is also source-controlled and correspond to the application code. ● Developer machine stays clean ● Can scale well to multiple environments without conflicts ● Can run locally or remotely
  • 42. @yshayy Our setup ● ~10 microservices in Golang & typescript/js ● Frontend with HMR ● Our own Kubernetes CR and controllers ● External dependencies (GH api, sendgrid, auth0, etc…) ● DB + Graphql engine ● A full blown CI system ● Container Registry ● Dynamic dns subdomains ● SSL Certs for local development ● Multiple CLI/SDKs for kubernetes and code-generation
  • 43. @yshayy Results ● Time to teardown and download/rebuild all cluster and dependencies <15m ● Time to build/run/test code changes < 10s ● Time to onboard new developer < 3h (including remote provisioning of a dedicated host on AWS) ● Time to introduce new tool and update dev-environments if needed <5m) ● No “works on my machine” occurrences ● No strain on developer machines ● Developers need to deal less with secrets ● Our team work on both M1 and Intel Macs
  • 44. @yshayy Future optimizations ● Shared build cache ● Snapshots (for reducing time or sharing state) ● Using a cloud provider optimized for dev-machines (cost, location, hibernation, cpu/ram, etc...)
  • 45. @yshayy Drawbacks ● Creating the initial setup can take some time ● Many tools, some are bleeding-edge ● Additional code to manage ● Dev-Environments are not standardized yet ● Coupling to VS-Code, Docker, Git and Linux ● Some performance issues ● Security challenges between development and production context
  • 46. @yshayy Alternatives to VS Code? ● It’s possible to use terminal based code-editors ● GitPod.io & Theia have similar features with gitpod.yaml ● Jetbrains Projector ● Run local IDE with Docker mounts
  • 47. @yshayy What about serverless? ● Should work although some pieces might be missing ● FaaS frameworks and sdks usually can run locally ● For the other PaaS features - cloud mocking frameworks, emulators or wire compatible solutions. (localstack, minio, etc…) ● If necessary, throw IaC tools to the mix (pulumi/terraform) for dynamic provisioning
  • 48. @yshayy What about native mobile? ● The problem still exists, developers can engage in epic battles with mobile IDEs, workspace, build and debug. ● It might be possible to stream applications with VNC/WebRTC during development, but experience is not optimal ● Mobile-emulators are heavy and can require nested virtualization to perform ● Container ecosystem is optimized for Linux ● IDEs for mobile are very tailored for mobile development ● Might be easier/possible with more cross-platform frameworks such as react- native/flutter
  • 49. @yshayy Part of a larger trend to put more stuff in the repository ● Linting, style guidelines ● Declarative application dependencies ● Documentation ● OpenAPI Specification ● CI Pipelines definition ● Workflows (PR) ● Design systems ● Infrastructure-As-Code ● Secrets (encrypted) ● Dashboards/alerts/SLA configuration ● Notebooks ● ...
  • 50. @yshayy Self-Contained Repositories ● All code, tools, knowledge, definitions and processes related to project resides in the repository. ● Git as the single source of truth ● Code is more accessible, lowering the barrier of entry ● Applications are portable ● Fine-grained developer experience ● Emerging tools ecosystem
  • 51. @yshayy Patterns & Cheatsheet Challenge Solution Exampletools Basic SDK/Runtime dependencies Development in container VSCode+Docker, GitPod Cloud dependencies Compatible dockerized implementations Minio, redis Initial application data Data seeding Scripts, replicating from cloud More hardware Remote environment Docker-machine, codespaces Multi-Container Apps Nested Containers Dind, compose, tilt Kubernetes Apps Nested Kubernetes Kind, k3d, tilt, skaffold Exposing network dependencies Reverse proxy, wild card development dns Traefik, nginx, *.xip, *.localtest.me Serverless Mock cloud frameworks Localstack