I will write the process of creating a web application (PHP) with Docker and deploying it on AWS in an easy-to-understand manner! !! I've become able to program, but I want to bring what I've made to the world, but I don't know! For those who have become
It consists of three parts (1) to (3) ① Overall picture and overall flow, like a table of contents ② Reason for using Docker and project creation procedure ③ Upload the created project to AWS (EC2 instance) and put it out to the world!
The whole image looks like this.
If you create this, you can put the created web application out to the world! !!
** 1. Install Docker on your PC **
** 2. Project (create a directory) **
** 3. Build environment using Docker in Project ** --Install the web server (nginx) --Install application server (php: 7.4-fpm), install PHP package management tool (Composer) --Install database server (mysql) --Install a framework (Laravel) that handles PHP
** 4. UP Project to Github **
** 5. Free programming in the local state! !! ** ** I'm programming with Laravel (PHP) here! !!
** 6. Upload the finished product to Github **
--- Explanation in ② so far ---
** 7. Register with AWS and create an EC2 instance (Ubuntu
** 8. Build environment in EC2 instance (Ubuntu) ** --Install PHP --Install the web server (nginx) --Install application server (php: 7.4-fpm), install PHP package management tool (Composer) --Install database server (mysql) --Install a framework (Laravel) that handles PHP
** 9. Git clone to a directory inside your EC2 instance (Ubuntu). Bring the project from Github! !! ** **
** 10. Access and display the corresponding URL! !! Successful deployment! ** **
I'm tired so I'll do something like this in this article Next time, from building an environment using Docker to uploading to Github Then go to ② [For beginners] Laravel Docker AWS (EC2) How to easily deploy a web application (PHP) from 0 (free) ②-Docker development environment construction (Laravel)- https://qiita.com/SG_Sg/items/12fdaeef1d9b7bbb397d
** I think there are some parts that are difficult to read or incorrect in Qiita's first post, but I would appreciate it if you could kindly point out in the comments. ** **
Recommended Posts