Moving Legacy Applications to Docker Josh Ellithorpe Software Architect (NOTE: PASTE IN PORTRAIT AND SEND BEHIND FOREGROUND GRAPHIC FOR CROP)
Auditing Resources Networking Data Services Dependencies Kernel Agenda Configuration Templates / ENV Service Discovery Lifecycle Build vs. Deploy App Updates
Auditing
(NOTE: PASTE IN PHOTO AND SEND BEHIND FOREGROUND GRAPHIC FOR CROP) CPU Multi-core runtime? Average load Disk Memory Consumption while running Network Resources
(NOTE: PASTE IN PHOTO AND SEND BEHIND FOREGROUND GRAPHIC FOR CROP) Required TCP/UDP ports External service connectivity Certificates/SSL Latency / Bandwidth Networking / Connectivity Useful Tools: tcpdump netstat lsof -P netdata
(NOTE: PASTE IN PHOTO AND SEND BEHIND FOREGROUND GRAPHIC FOR CROP) Where does your app write data to the filesystem? What persistent datastore do you want to use? (NFS/CIFS/etc) What databases or other data services are required? What are their connection details? Data Services / Storage Useful Tools: strace lsof
(NOTE: PASTE IN PHOTO AND SEND BEHIND FOREGROUND GRAPHIC FOR CROP) What OS is required? What packages are needed to run the app? Runtime Shared libraries What application dependencies are required? NPM modules, gems, etc. Dependencies Useful Tools: ld strace lsof
(NOTE: PASTE IN PHOTO AND SEND BEHIND FOREGROUND GRAPHIC FOR CROP) Does your app require a privileged container? Does your app require custom kernel modules/parameters? Kernel
Configuration
(NOTE: PASTE IN PHOTO AND SEND BEHIND FOREGROUND GRAPHIC FOR CROP) Can the application read ENV vars? Does it require a startup script to setup the container before the application/service starts? Templates / ENV Variables Recommendations: Write the entire config in the start script instead of using sed/awk
(NOTE: PASTE IN PHOTO AND SEND BEHIND FOREGROUND GRAPHIC FOR CROP) Etcd / Zookeeper Consul DNS Static Values Service Discovery
Lifecycle
(NOTE: PASTE IN PHOTO AND SEND BEHIND FOREGROUND GRAPHIC FOR CROP) Understand where your concerns are. Build Dependencies, required ports, and startup scripts Deploy Persistent volumes, network context, and scheduling Runtime Writing needed configurations via start script Consuming services from service discovery system Clean startup and shutdown Build / Deploy / Runtime
(NOTE: PASTE IN PHOTO AND SEND BEHIND FOREGROUND GRAPHIC FOR CROP) Traditional VM based deployments only update the application, however when using containers you must rebuild the entire dependency set down to the OS. It is critical to create an automated build process to handle this. That way it can pull in the new dependencies you need, and script out the generation of your Dockerfile. App Updates
Thank you!