Skip to content

Instantly share code, notes, and snippets.

@joaquinacuna
Created December 30, 2019 15:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save joaquinacuna/3913c8bc7c637b7ef5818bb5b5c8c5c3 to your computer and use it in GitHub Desktop.
Save joaquinacuna/3913c8bc7c637b7ef5818bb5b5c8c5c3 to your computer and use it in GitHub Desktop.
# settings.py
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql',
'OPTIONS': {
'read_default_file': '/path/to/my.cnf',
},
}
}
# my.cnf
[client]
database = NAME
user = USER
password = PASSWORD
default-character-set = utf8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment