Skip to content

Commit

Permalink
.github: django: Use runner MySQL
Browse files Browse the repository at this point in the history
Signed-off-by: Shashank Verma <[email protected]>
  • Loading branch information
shank03 committed Oct 4, 2023
1 parent 071e5e2 commit e276bad
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
11 changes: 4 additions & 7 deletions .github/workflows/django.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,10 @@ jobs:

steps:
- uses: actions/checkout@v3
- name: Shutdown Ubuntu MySQL (SUDO)
run: sudo service mysql stop
- name: Setup MySQL
uses: mirromutth/[email protected]
with:
mysql user: 'dbuser' # Required if "mysql root password" is empty, default is empty. The superuser for the specified database. Can use secrets, too
mysql password: '1234' # Required if "mysql user" exists. The password for the "mysql user"
- name: Set up MySQL
run: |
sudo /etc/init.d/mysql start
mysql -uroot -proot -hlocalhost -P3306 -e "create database 'contrihub23_db'"
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
Expand Down
2 changes: 1 addition & 1 deletion contrihub/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
# Database
# https://docs.djangoproject.com/en/3.2/ref/settings/#databases

DB_NAME = config('DB_NAME', default='contrihub')
DB_NAME = config('DB_NAME', default='contrihub23_db')
DB_USER = config('DB_USER', default='dbuser')
DB_PASSWORD = config('DB_PASSWORD', default='1234')
DB_HOST = config('DB_HOST', default='localhost')
Expand Down

0 comments on commit e276bad

Please sign in to comment.