Amr Abdelwahab

Summarized using AI

Dockerization in the land of Ruby

Amr Abdelwahab • August 21, 2020 • online

In the talk titled "Dockerization in the land of Ruby," Amr Abdelwahab shares insights on enhancing Docker setups from development to production environments, alongside continuous integration. He emphasizes that technology is not just about technical skill; it involves community and collaboration in software development. Amr recounts a personal anecdote about a friend purchasing a ruby engagement ring, leading him to reflect on his experiences within the Ruby community, showcasing both its strengths and possible grievances.

Key Points Discussed:

  • Introduction to Docker: Docker has evolved since its inception and aims to improve the developer experience by providing comfort and efficiency when building applications.
  • Containerization Concept: Understanding containerization as a method for isolating applications from the underlying hardware, which helps maintain consistency across environments.
  • Challenges with Docker Adoption: There is often resistance among seasoned developers to adopting new tools like Docker, exacerbated by outdated resources in the Ruby community.
  • Streamlining Development Environments: Effective use of Docker requires simplification in day-to-day command usage to aid junior developers and minimize setup complexities.
  • Utilizing Docker Compose: Amr stresses the necessity of Docker Compose for managing multiple services and interacting containers efficiently.
  • Efficiency Practices: Suggestions like using multi-stage Dockerfiles, Docker volumes to retain bundles across sessions, and proper CI integration to improve build processes.
  • Focus on Usability: The biggest takeaway is to implement tools that genuinely enhance developer workflow and community usability rather than just embracing new innovations for novelty's sake.

In conclusion, Amr's insights encourage developers to adopt best practices prioritizing usability, ensuring their setups truly meet their project needs. His call to action encourages further exploration and discussions on Docker practices, fostering better collaboration within tech communities.

Dockerization in the land of Ruby
Amr Abdelwahab • August 21, 2020 • online

Whether you have never seen a dockerfile in your life or you have been working on a daily basis with docker in different environments, join this talk to learn some tips and tricks on improving your docker setup all the way from development to live environments passing through continuous integration.

Amr's is an African Egyptian native who crossed continents to work with his passion in digital environments. His interests span technology, tech-communities, politics and politics in tech, all enriched through various software engineering roles in Egypt, Hungary and Germany. In Berlin he's a co-organiser of RUG::B and code curious (Formerly known as Rails Girls Berlin)

Welcome to the #NoRuKo conference. A virtual unconference organized by Stichting Ruby NL.

#NoRuKo playlist with all talks and panels: https://www.youtube.com/playlist?list=PL9_A7olkztLlmJIAc567KQgKcMi7-qnjg

Recorded 21th of August, 2020.
NoRuKo website: https://noruko.org/
Stichting Ruby NL website: https://rubynl.org/

NoRuKo 2020

00:00:00.320 This is a talk by Amr Abdelwahab. I remember seeing him deliver a talk once, and it was as if I was on a spacecraft traveling many miles per hour. His presentation speed is astonishing.
00:00:07.759 Amr is an Egyptian native who has crossed continents to pursue his passion for digital environments. His interests span technology, tech communities, and politics within the tech world, enriched through various software engineering roles in Egypt, Hungary, and Germany.
00:00:22.560 Currently, he lives in Berlin where he is a co-organizer of RUG::B and Code Curious, formerly known as Rails Girls Berlin.
00:00:42.160 I hope everyone can hear me. I must admit, this is quite an interesting setup, talking directly to a computer, but I hope my voice is clear. As Arnold mentioned during the introduction, I usually speak about various topics related to politics, communities, and technology.
00:01:02.399 However, regardless of the topic, I always include a crucial slide in my presentations: technical excellence and skills are vital. There is no doubt about that, but we must always remember that communities are what truly matter. When we write software, we do so with and for other people; software that is not used collectively is not truly significant.
00:01:36.320 Let me begin with a story about my close friends, Alejandro and Anuri. This story dates back about a month before the pandemic began. I received a phone call from Alejandro, who excitedly shared that he bought a ring.
00:02:00.320 I congratulated him, thrilled for him, but then I became confused when he mentioned that the gem is ruby. I thought he was referring to the programming language, which puzzled me even more. But he meant that the ring should contain a ruby because he felt that this gem brought them together.
00:02:31.440 This moment led me to reflect on the nature of our discussions. I often express my grievances about Ruby and its framework. For instance, my previous talk was titled 'What's Wrong with Ruby?' I frequently find faults in the language, the frameworks, and the Ruby community. However, today, I want to express my gratitude for belonging to this community.
00:03:10.239 The Ruby community has been where I learned the most in recent years, and I want to celebrate the connections I've made, especially with Alejandro. My name is Amr Abdelwahab, and for those who've never encountered my name, please don’t worry — it’s not complicated.
00:03:38.760 I am a tech lead at a startup called Turlin, based in Berlin, mainly focused on travel tech. I’m also very active in the Ruby community, particularly in Europe. I've contributed to various organizations, including Code Curious (formerly Rails Girls Berlin) and I'm actually the chair organizer for NoRuKo 2017 in Budapest.
00:04:05.440 My journey began in Cairo, Egypt, where I was born and raised. Then, I moved to Budapest in 2013, and finally to Berlin in 2017. Whenever I have a new idea for a talk, I ask myself why it should be interesting and relevant. We currently live in an era of distributed systems architecture.
00:04:44.520 It’s uncommon to find a company that solely builds monolithic applications. While there are still some, they are increasingly rare. This shift introduces numerous benefits but also adds layers of complexity. Previously, you might have only needed to bootstrap a service a couple of times throughout the company's life, but now it's nearly every few weeks.
00:05:18.960 With consistently changing teams and a high turnover rate among developers, it's essential to streamline the setup process for new repositories. We need easier development environments to ensure consistency in this fast-evolving technological landscape.
00:05:49.680 'It works on my machine' is a long-standing issue we need to eliminate. Some might ask why I am the one to speak about this subject. I acknowledge that, like everyone else in this room, I am primarily a Ruby developer focused on the application side of things.
00:06:15.840 However, since Docker's inception, I have been a huge fan of containerization tools. Like Ruby, these tools prioritize developer happiness, offering comfort and efficiency for building better-quality applications.
00:06:51.360 My experience has made me the go-to person in my team for leading Docker implementations. I have had several successes where, after changing company setups, developers who were initially resistant would later express their appreciation for Docker. A select few have remarked that they could never go back after experiencing the conveniences of Docker.
00:07:30.880 Now, let's explore the theory around containerization, not limited to Docker. Containerization means taking your application along with its requirements into an isolated space separate from your main machine. It ensures that the application runs the same, regardless of the underlying hardware.
00:08:11.680 Docker promotes faster onboarding and minimizes wasted time setting up development environments. It facilitates quickly spinning up new instances and allows for local copies of production environments.
00:08:51.680 Its potential for polyglot development makes it easier to change between various tools and eliminate environment inconsistencies. While Docker is conceptually simple with only about a dozen commands, its real challenges lie with people and their communities.
00:09:38.880 Adopting new tools requires overcoming a steep learning curve, especially for seasoned application developers entrenched in their habits prior to Docker's popularity.
00:10:19.680 In the Ruby community, outdated and inaccurate resources abound regarding Docker setups. Many 'tips and tricks' once valid may no longer apply, given that Docker continues to evolve, introducing new features that improve its usability.
00:10:52.640 This misalignment between what Docker offers and developers’ needs as application developers is problematic. Many projects simply adopt Docker for the sake of it, neglecting to consider how it fulfills their requirements. We must prioritize ease of use and adaptability when establishing development setups.
00:11:32.640 A simple Rails application setup typically involves several components: a web server, a database server, and often a background worker process. Many applications now include systems like Redis for job queuing.
00:12:09.360 When developing with Docker, the ability to run everyday commands without excessive hassle is important. Running tests, linters, updating dependencies, managing migrations, and starting servers should be straightforward.
00:12:45.440 For development setups, I focus on two main constraints: minimizing changes in day-to-day commands and hiding setup complexity to ensure junior developers can engage without needing to learn extensive Docker commands.
00:13:40.560 Effective development requires more than just a Docker file. It is essential to use Docker Compose for orchestrating container interactions and managing multiple services.
00:14:23.520 Additionally, having build files enables added abstractions. Despite the abundance of resources available, many Docker tutorials focus on security or performance optimization rather than developer happiness.
00:15:12.560 Most examples I see lack focus on usability in development environments, which is critical. For example, using multi-stage Docker files simplifies the process of maintaining separate environments for development and production.
00:15:54.640 This concept allows for multiple resource levels managed in one-command containers. If correctly implemented, developers should execute common Rails commands without excessive complexity.
00:16:47.680 Using Docker volumes ensures bundles persist across sessions, preventing the need to reinstall upon every container start. This optimizes developer workflow remarkably, reducing wasteful rebuilds.
00:17:43.920 Moving onwards to CI integration, using multi-stage builds allows caching dependencies more effectively while keeping build processes organized. The right setup in this phase can enhance the quality of the code being built.
00:18:38.560 Finally, when making builds live, it’s essential to adapt staging environments to support scalability and longevity. The most crucial lesson from this talk is to optimize practices for community use rather than sheer novelty.
00:19:36.480 Developers should prioritize foundational needs, ensuring they implement the tools that best align with their requirements rather than merely following trends. In essence, successful containerization should be realistic rather than whimsical.
00:20:26.640 If you want to explore my practices further, check out the boilerplate code available on my GitHub. Feel free to suggest improvements or discuss anything related to this topic. Let's engage.
00:21:12.960 Thank you for listening. I hope you enjoyed this talk and found the information useful.
00:22:04.640 It’s been a pleasure to share my insights with you today.
00:22:36.800 As we transition to the developer dilemmas segment, we will dive into discussing issues related to monoliths versus microservices.
00:23:18.480 I personally prefer using monoliths within Docker, as they foster team cohesion. When there are a multitude of services, it can be challenging to know all your colleagues.
00:24:06.400 I have noticed that teams gravitating towards microservices often become disconnected from one another.
00:24:38.960 One question that arises is regarding Docker Compose setup. I see some teams using Docker Compose 2.4 to implement health checks. Does anyone have experience with that?
00:25:14.640 Yes, I typically use version 3.7; there's a well-known script called 'wait for it' or 'wait for' available on GitHub that accomplishes this quite well.
00:26:09.760 This script simply pings the port until the other service is functional. I wouldn't limit your version of Docker Compose based on this single feature.
00:26:58.560 I emphasize the importance of focusing on usability over novelty. It’s crucial for tech teams to confirm that new implementations are genuinely beneficial.
00:27:37.680 The discussion on pre-built images raises concerns. I am personally cautious about using pre-built stack images like Ruby and others, as I prefer knowing what’s in the package.
00:28:17.320 Additionally, a past incident with a MySQL Docker-based image underscored my unease regarding reliance on public images.
00:29:11.120 It’s prudent to inspect the contents of a base image before deploying it into production.
00:29:49.720 Many organizations adhere to using only their builds for Docker images, ensuring control over their environments.
00:30:26.280 I appreciate your participation and the valuable questions raised today.
00:30:45.680 Thank you for joining me today. I hope the insights shared will help in your development journey. Farewell!
Explore all talks recorded at NoRuKo 2020
+10