Between this and your Udemy Spring Boot course, I learned that you are a LEGEND! I wish there was someone like you who made an ASPdotNET web API course that was as good as your Spring Boot course. Every one that exists doesn't stand up to what you've done. Thank you so much for everything you've given us. I see in the comments others feel the same way. I wish there were more like you, but unfortunately, there is only one Rayan Slim. Keep being you buddy.
Thank you, Rayan. You are absolutely right that students today are overwhelmed with their studies. But we just keep on truckin, right? Your info on Docker is very timely, indeed. But this field is moving at lightening speed, and we need to stay on top of things. Thanks so very much!!
So this is the face of the teacher who taught me Java and Spring-Boot. Good to see you sir. I like your teaching style from your voice to your slides to your clear explanations of complex topics, Masha Allah. Thank you for your Udemy courses. And thank you for this course as well. Delivered with clarity as expected 👍👍
Much appreciated Rayan. I've been meaning to learn Docker for ages. I have your Java course and really like your teaching style, so I am looking forward to following this. Thanks again
@@RayanSlim087 Thanks Ryan,. After Java, I have passed through the PHP world, and am now in the heart of React JS trying my hand at web app development. Great to see you expand your horizon. Cheers.
I honestly enjoy your courses, they I so organised, even an absolute beginner with prior coding experience can easily grab and understand all your lessons because of the way you teach and how well you explain thing, not to forget how well you break down each lesson in a way that anyone can easily digest the information. Thank you for your amazing lessons, especially the Complete Java Bootcamp on Udemy, I really appreciate you time and effort you took when preparing for each and every lesson
Chapter3 running the command on windows machine yielded an error. I converted the slash marks as described but getting an "exec format error" while using the rest of the command exactly as described. Further attempts appear to increase the number of container IDs needing to be removed per the end of chapter cleanup.
Okay, I was on windows and it was important to specfiy which drive in the format /// i.e. docker run -v //d/containers-crash-course/lessons/01-starter-code:/src/app -w /src/app python:3.8-slim python python-app.py Note I set the working directry with -w but this shouldn't be necessary. Before when I didn't have //d/ set, even though my powershell terminal was on d it just did not work and kept saying file not found...
What if I intend to run my docker containers in different operating systems (like Windows and Linux), how should I configure the persistent storage for the containers in this case, as the file paths would be different?
Good question! For two containers to communicate, one of two criteria needs to be met: They either need to be on the same Docker network, or they must have explicit port mappings that allow external connections. In Chapter 8, the containers are running in isolated networks. Therefore, you cannot omit the port mapping for the MySQL container. The Flask application needs to know how to reach the MySQL database. By setting DATABASE_HOST=host.docker.internal, we intend for the Flask Docker container to access the host machine's network stack. In Chapter 9, the containers are running in the same network (within the same Docker Compose environment). Therefore, omitting the port mapping for the MySQL container should be fine.
hey awesome - how about including a certificate at the end of this - would really help - I am your student at Udemy though. so which course would you suggest for a docket certi at udemy
In section 8, I still see failed to connect to db in flask app. I have MySQL installed locally from 2 years ago running on 3306. When running the container with the mysql-server:8.0 image, i set the port to -p 3306:3306, but the port is in use which I get. I tried 3307:3306 and the container runs fine, but the flask app still doesn't connect. In running the flask app, I tried host.docker.internal and host.docker.internal:3307, but still can't make the connection. Is there something I'm missing? The flask container runs, the mysql container runs, but the connection is not being made. Is the flask app still trying to connect to the local instance of MySQL rather than the running container?
It works in chapter 9 with yaml. My guess is instead of using host.docker.internal, I could use the name of the container running the mysql image. I'll try that later.
Hey, that’s pretty strange. Have you tried removing the MySQL server that is locally installed? Also does this still happen when you run both of them within the same docker compose environment (next chapter)? Edit: nvm just saw the reply. At least it worked with docker compose. I’m not too certain why the connection isn’t being made with the run commands. Feel free to paste them here if you’d like.
@@RayanSlim087 docker run -p 8000:3000 -e DATABASE_HOST=host.docker.internal -e DATABASE_USER=user -e DATABASE_PASSWORD=password -e DATABASE_NAME=db flask-mysql:latest docker run -p 3307:3306 -e MYSQL_DATABASE=db -e MYSQL_USER=user -e MYSQL_PASSWORD=password mysql/mysql-server:8.0 I tried running the mysql container first. Then, for running the flask container, I tried DATABASE_HOST=interesting_perlman (name of mysql container) instead of DATABASE_HOST=host.docker.internal I think the flask app still points to the local MySQL server instead of the container. Oh well. On to the practice workbooks. It's Java time!
Thanks to this man, I got my first job as a backend developer, and I am eternally grateful
Congratulations Wiston. I hope you find tremendous success in your new job. I am sure that soon you will surpass me 🙏.
Rayan courses probably has the most organized content I have ever seen.
You spelled definitely wrong
Between this and your Udemy Spring Boot course, I learned that you are a LEGEND! I wish there was someone like you who made an ASPdotNET web API course that was as good as your Spring Boot course. Every one that exists doesn't stand up to what you've done. Thank you so much for everything you've given us. I see in the comments others feel the same way. I wish there were more like you, but unfortunately, there is only one Rayan Slim. Keep being you buddy.
Thank you for the kind words my friend ♥
Thank you, Rayan. You are absolutely right that students today are overwhelmed with their studies. But we just keep on truckin, right? Your info on Docker is very timely, indeed. But this field is moving at lightening speed, and we need to stay on top of things. Thanks so very much!!
You helped me understand Docker so well. Your teaching is amazing. Thank you.
The best teacher and #asmr voice 🤤
thank you😂
So this is the face of the teacher who taught me Java and Spring-Boot. Good to see you sir. I like your teaching style from your voice to your slides to your clear explanations of complex topics, Masha Allah. Thank you for your Udemy courses. And thank you for this course as well. Delivered with clarity as expected 👍👍
Thank you my friend 🙏
This was amazing, thanks a bunch..very clear and orginized
Much appreciated Rayan. I've been meaning to learn Docker for ages. I have your Java course and really like your teaching style, so I am looking forward to following this.
Thanks again
Legend is back❤❤
Your sound so familiar, and then I relized you the Udemy Springboot guy!!!
Haha, that would be me :D
Super proficient ! Thank you so much Rayan
Well organised and well taught
Thanks!
Long time student and fan. Will give this a spin.
It’s great to hear from you again, James!
@@RayanSlim087 Thanks Ryan,. After Java, I have passed through the PHP world, and am now in the heart of React JS trying my hand at web app development. Great to see you expand your horizon. Cheers.
I honestly enjoy your courses, they I so organised, even an absolute beginner with prior coding experience can easily grab and understand all your lessons because of the way you teach and how well you explain thing, not to forget how well you break down each lesson in a way that anyone can easily digest the information. Thank you for your amazing lessons, especially the Complete Java Bootcamp on Udemy, I really appreciate you time and effort you took when preparing for each and every lesson
Thank you so much for the kind words ❤
This is very informative and easy to watch, thank youu!!
Glad you liked it!!
Also, maybe I missed this (or the author did) but you need to be authenictaed with your registry using docker login and follow the instructions
Chapter3 running the command on windows machine yielded an error. I converted the slash marks as described but getting an "exec format error" while using the rest of the command exactly as described. Further attempts appear to increase the number of container IDs needing to be removed per the end of chapter cleanup.
Hey, feel free to copy your command here in the comments section. I can have a look,
@@RayanSlim087 I think i found it, missing the second reference to /src/app
Okay, I was on windows and it was important to specfiy which drive in the format ///
i.e. docker run -v //d/containers-crash-course/lessons/01-starter-code:/src/app -w /src/app python:3.8-slim python python-app.py
Note I set the working directry with -w but this shouldn't be necessary. Before when I didn't have //d/ set, even though my powershell terminal was on d it just did not work and kept saying file not found...
What if I intend to run my docker containers in different operating systems (like Windows and Linux), how should I configure the persistent storage for the containers in this case, as the file paths would be different?
but in connecting to mysql database why it works without specifying a port with the network.
Good question! For two containers to communicate, one of two criteria needs to be met: They either need to be on the same Docker network, or they must have explicit port mappings that allow external connections.
In Chapter 8, the containers are running in isolated networks. Therefore, you cannot omit the port mapping for the MySQL container. The Flask application needs to know how to reach the MySQL database. By setting DATABASE_HOST=host.docker.internal, we intend for the Flask Docker container to access the host machine's network stack.
In Chapter 9, the containers are running in the same network (within the same Docker Compose environment). Therefore, omitting the port mapping for the MySQL container should be fine.
Hi python:3.8-slim does no longer exist in the hub. I used 3.9-slim instead. is that okay?
hey awesome - how about including a certificate at the end of this - would really help - I am your student at Udemy though. so which course would you suggest for a docket certi at udemy
Hey! This course isn't affiliated with Udemy, so unfortunately I cannot provide a certificate by the end of it.
In section 8, I still see failed to connect to db in flask app. I have MySQL installed locally from 2 years ago running on 3306. When running the container with the mysql-server:8.0 image, i set the port to -p 3306:3306, but the port is in use which I get. I tried 3307:3306 and the container runs fine, but the flask app still doesn't connect. In running the flask app, I tried host.docker.internal and host.docker.internal:3307, but still can't make the connection. Is there something I'm missing? The flask container runs, the mysql container runs, but the connection is not being made. Is the flask app still trying to connect to the local instance of MySQL rather than the running container?
It works in chapter 9 with yaml. My guess is instead of using host.docker.internal, I could use the name of the container running the mysql image. I'll try that later.
Hey, that’s pretty strange. Have you tried removing the MySQL server that is locally installed? Also does this still happen when you run both of them within the same docker compose environment (next chapter)?
Edit: nvm just saw the reply. At least it worked with docker compose. I’m not too certain why the connection isn’t being made with the run commands. Feel free to paste them here if you’d like.
@@RayanSlim087 docker run -p 8000:3000 -e DATABASE_HOST=host.docker.internal -e DATABASE_USER=user -e DATABASE_PASSWORD=password -e DATABASE_NAME=db flask-mysql:latest
docker run -p 3307:3306 -e MYSQL_DATABASE=db -e MYSQL_USER=user -e MYSQL_PASSWORD=password mysql/mysql-server:8.0
I tried running the mysql container first. Then, for running the flask container, I tried DATABASE_HOST=interesting_perlman (name of mysql container) instead of DATABASE_HOST=host.docker.internal
I think the flask app still points to the local MySQL server instead of the container. Oh well. On to the practice workbooks. It's Java time!
can also so 'docker inspect --format='{{.Config.ExposedPorts}}' ' to find ports though it's a bit verbose