Skip to content

Commit e2e8489

Browse files
committed
RM - Added MySql Section
1 parent 41bbce4 commit e2e8489

File tree

1 file changed

+80
-20
lines changed

1 file changed

+80
-20
lines changed

README.md

Lines changed: 80 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,23 @@ The Django boilerplate with all you need to build your SaaS, AI tool, or any oth
5959
$ git clone https://github.com/app-generator/rocket-django.git
6060
$ cd rocket-django
6161
```
62-
62+
63+
> Create `.env` from `env.sample`
64+
65+
```env
66+
DEBUG=False
67+
68+
SECRET_KEY=<STRONG_KEY_HERE>
69+
70+
# For Myql or PgSQL Persistence
71+
# DB_ENGINE=mysql
72+
# DB_HOST=localhost
73+
# DB_NAME=appseed_rocket_django
74+
# DB_USERNAME=root
75+
# DB_PASS=
76+
# DB_PORT=3306
77+
```
78+
6379
> Install Node Modules
6480
6581
```
@@ -84,20 +100,42 @@ $ npm run dev
84100

85101
> Migrate DB
86102
87-
```
103+
```bash
88104
$ python manage.py makemigrations
89105
$ python manage.py migrate
90106
```
91107

92108
> Create Superuser & Start the APP
93109
94-
```
110+
```bash
95111
$ python manage.py createsuperuser # create the admin
96112
$ python manage.py runserver # start the project
97113
```
98114

99115
<br />
100116

117+
## Free vs. `PRO`
118+
119+
> `Have questions?` Contact **[Support](https://appseed.us/support/)** (Email & Discord) provided by **AppSeed**
120+
121+
| Free Version | PRO - $499 (plus VAT) | 🚀 Custom - $2999 (plus VAT) |
122+
| --------------------------------------| --------------------------------------| --------------------------------------|
123+
| ✓ Django 4.2.x | **Everything in Free**, plus: | **Everything in PRO**, plus: |
124+
| ✓ Best Practices |`OAuth` Google, GitHub |**1mo Custom Development** |
125+
|**TailwindCSS**/`Flowbite` |**Stripe** Payments |**Dedicated Developer** |
126+
| ✓ Extended User Model |**Wagtail** CMS | ✅ Weekly Sprints |
127+
|[Charts](https://rocket-django.onrender.com/charts/) | ✅ Multi-Language Support | ✅ Technical SPECS |
128+
|[DataTables](https://rocket-django.onrender.com/tables/) |**Sentry** Error Reporting | ✅ Documentation |
129+
|[API](https://rocket-django.onrender.com/api/product/) via `DRF` | ✅ Private REPO Access |**30 days Delivery Warranty** |
130+
|[Celery Beat](https://rocket-django.onrender.com/tasks/) |**Unlimited Projects** | - |
131+
|`Docker` | ✅ Lifetime Updates | - |
132+
|`CI/CD` Flow via Render |**PRO Support** - [Email & Discord](https://appseed.us/support/) | - |
133+
|`Free Support` (GitHub Issues) | ✅ Deployment Assistance | - |
134+
| ------------------------------------| ------------------------------------| ------------------------------------|
135+
| - | 🛒 `PRE Order`: **[$299](https://appseed.gumroad.com/l/rocket-django)** (via GUMROAD) | 🛒 `Order`: **[$2999](https://appseed.gumroad.com/l/rocket-django-custom)** (GUMROAD) |
136+
137+
<br />
138+
101139
## Start With Docker
102140

103141
> Download code
@@ -117,25 +155,47 @@ Visit the app in the browser `localhost:5085`.
117155

118156
<br />
119157

120-
## Free vs. `PRO`
158+
## Use MySql
121159

122-
> `Have questions?` Contact **[Support](https://appseed.us/support/)** (Email & Discord) provided by **AppSeed**
160+
By default, the starter uses SQLite for persistence. In order to use MySql, here are the steps:
161+
162+
- Start the MySql Server
163+
- Create a new DataBase
164+
- Create a new user with full privilegies over the database
165+
- Install the MySql Python Driver (used by Django to connect)
166+
- `$ pip install mysqlclient`
167+
- Edit the `.env` with the SQL Driver Information & DB Credentials
168+
169+
```env
170+
171+
DB_ENGINE=mysql
172+
DB_HOST=localhost
173+
DB_NAME=<DB_NAME_HERE>
174+
DB_USERNAME=<DB_USER_HERE>
175+
DB_PASS=<DB_PASS_HERE>
176+
DB_PORT=3306
177+
178+
```
179+
180+
Once the above settings are done, run the migration & cretae tables:
181+
182+
```bash
183+
$ python manage.py makemigrations
184+
$ python manage.py migrate
185+
```
186+
187+
<br />
188+
189+
## Production Build
190+
191+
To use the starter in production mode, here are the steps:
192+
193+
- Set **DEBUG=False** in `.env`
194+
- Execute `collectstatic` command
195+
- `$ python manage.py collectstatic --no-input`
196+
197+
As a model, feel free to take a look at [build.sh](./build.sh), the file executed by the CI/CD flow for Render:
123198

124-
| Free Version | PRO - $499 (plus VAT) | 🚀 Custom - $2999 (plus VAT) |
125-
| --------------------------------------| --------------------------------------| --------------------------------------|
126-
| ✓ Django 4.2.x | **Everything in Free**, plus: | **Everything in PRO**, plus: |
127-
| ✓ Best Practices |`OAuth` Google, GitHub |**1mo Custom Development** |
128-
|**TailwindCSS**/`Flowbite` |**Stripe** Payments |**Dedicated Developer** |
129-
| ✓ Extended User Model |**Wagtail** CMS | ✅ Weekly Sprints |
130-
|[Charts](https://rocket-django.onrender.com/charts/) | ✅ Multi-Language Support | ✅ Technical SPECS |
131-
|[DataTables](https://rocket-django.onrender.com/tables/) |**Sentry** Error Reporting | ✅ Documentation |
132-
|[API](https://rocket-django.onrender.com/api/product/) via `DRF` | ✅ Private REPO Access |**30 days Delivery Warranty** |
133-
|[Celery Beat](https://rocket-django.onrender.com/tasks/) |**Unlimited Projects** | - |
134-
|`Docker` | ✅ Lifetime Updates | - |
135-
|`CI/CD` Flow via Render |**PRO Support** - [Email & Discord](https://appseed.us/support/) | - |
136-
|`Free Support` (GitHub Issues) | ✅ Deployment Assistance | - |
137-
| ------------------------------------| ------------------------------------| ------------------------------------|
138-
| - | 🛒 `PRE Order`: **[$299](https://appseed.gumroad.com/l/rocket-django)** (via GUMROAD) | 🛒 `Order`: **[$2999](https://appseed.gumroad.com/l/rocket-django-custom)** (GUMROAD) |
139199

140200
<br />
141201

0 commit comments

Comments
 (0)