adigunsherif / Django-School-Management-System

School Management System based on Django framework.
MIT License
354 stars 197 forks source link

Create Mysql server.txt #20

Closed AvTe closed 3 years ago

adigunsherif commented 4 years ago

If you need mysql connection, you can simple modify the settings.py file , DATABASES section (line 86) to something like this

DATABASES = { 'default': { 'ENGINE': 'django.db.backends.mysql', 'OPTIONS': { 'read_default_file': '/etc/mysql/my.cnf', }, } }

Then in the my.cnf, you simply update the client section like so

[client] database = database_name user = dbusername password = your_actual_password default-character-set = utf8

Since the application can be used with all db django supports, I do not think commiting db-specific instructions is necessary.
You can Google "how to connect django to mysql" and the process works the same way for this app.