Skip to content

Commit 2c24ddf

Browse files
committed
Changed README
1 parent f04269b commit 2c24ddf

File tree

2 files changed

+27
-4
lines changed

2 files changed

+27
-4
lines changed

README.md

Lines changed: 26 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,19 +13,30 @@ Includes local end production settings.
1313
**Note:** Local environment tested only on Ubuntu. Feel free create an Issue for other OS.
1414
1. **Clone repository**
1515
````
16-
mkdir {YOUR_PROJECT_FOLDER}
17-
cd {YOUR_PROJECT_FOLDER}
16+
mkdir {YOUR_NEW_FOLDER}
17+
cd {YOUR_NEW_FOLDER}
1818
git clone [email protected]:dmsemenov/laravel-docker-environment.git .
1919
````
2020
2. **Configure main `.env` file**
2121
````
2222
cp .env.example .env
2323
````
2424
Set `PROJECT_NAME` variable.
25-
Set `PROJECT_FOLDER` variable for example 'backend' or whatever you want - by default it is main.
25+
Set `PROJECT_FOLDER` variable for example 'backend' or whatever you want. By default it is `main`.
26+
27+
3. **Install Application**
28+
Install or copy your existing application to `PROJECT_FOLDER`.
29+
````
30+
# Install new
31+
composer create-project --prefer-dist laravel/laravel `PROJECT_FOLDER`
32+
````
2633
3. **Configure main `docker-compose.yml` file**
2734
````
28-
cp docker-compose.yml.local docker-compose.yml
35+
# Local development
36+
cp docker-compose.yml.local docker-compose.yml
37+
38+
# Production
39+
cp docker-compose.yml.prod docker-compose.yml
2940
````
3041
Set variables for mysql container. Docker will create database and user at first UP.
3142
````
@@ -63,3 +74,14 @@ Includes local end production settings.
6374
````
6475
6. **Launch http://localhost:8989/register**
6576
77+
### LetsEncrypt and Production
78+
If you are going to use LetsEncrypt at production look at branch 'letsencrypt' this repository.
79+
Branch contains ready to use configuration for letsEncrypt in production based on great article [Nginx and Let’s Encrypt with Docker in Less Than 5 Minutes](https://medium.com/@pentacent/nginx-and-lets-encrypt-with-docker-in-less-than-5-minutes-b4b8a60d3a71).
80+
To use letsEncrypt at production just follow steps below:
81+
2. Initial settings
82+
Open ``./init-letsencrypt.sh`` add your domains instead `{YOUR_DOMAIN}` www.`{YOUR_DOMAIN}` and set `{YOUR_EMAIL}`.
83+
Run ``./init-letsencrypt.sh``. It will create initial settings.
84+
Note: don't forget to add A DNS record for domain with www.
85+
3. Nginx settings
86+
At `.provision/nginx/conf.d/vhost.prod.conf` set `{YOUR_DOMAIN}` variable.
87+

main/readme.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Your laravel App here

0 commit comments

Comments
 (0)