Skip to content

Commit

Permalink
fix: cannot connect
Browse files Browse the repository at this point in the history
  • Loading branch information
irtazaakram committed Sep 12, 2024
1 parent 9b9d25d commit a86c5fb
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,13 +40,17 @@ jobs:
sudo apt-get update
sudo apt-get install -y mysql-server
# Ensure the MySQL service is started
sudo service mysql start
sudo service mysql status
# Wait for MySQL service to be fully ready
sleep 10
# Set root password and allow password-based root access
sudo mysql -e "ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'root_password';"
sudo mysql -e "FLUSH PRIVILEGES;"
# Start MySQL service
sudo service mysql start
# Create database and user
mysql -u root -proot_password -e 'CREATE DATABASE edx_notes_api;'
mysql -u root -proot_password -e "CREATE USER 'notes001'@'localhost' IDENTIFIED BY 'secret';"
Expand Down

0 comments on commit a86c5fb

Please sign in to comment.