Skip to content

Commit

Permalink
workflows bugfix super privilege
Browse files Browse the repository at this point in the history
  • Loading branch information
silverqx committed Apr 11, 2024
1 parent d6d98f2 commit 617161c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/msvc2019-qt5.yml
Original file line number Diff line number Diff line change
Expand Up @@ -203,11 +203,16 @@ jobs:
DB_MYSQL_ROOT_PASSWORD: ${{ secrets.DB_MYSQL_ROOT_PASSWORD }}
DB_MYSQL_ROOT_USERNAME: ${{ secrets.DB_MYSQL_ROOT_USERNAME }}

# I had to assign the SUPER privilege to be able set global `max_allowed_packet` for tst_blobs,
# it looks like it's only needed for MySQL v5.7, on MySQL v8 isn't needed, also, the SUPER
# privilege can't be assigned to the table eg. tinyorm_% because it's a global privilege so
# * have to be used
- name: MySQL create TinyORM user
run: >-
"create user '$env:DB_MYSQL_USERNAME'@'%'
identified by '$env:DB_MYSQL_PASSWORD';
grant all privileges on ``tinyorm\_%``.* to '$env:DB_MYSQL_USERNAME'@'%';
grant super on *.* to '$env:DB_MYSQL_USERNAME'@'%';
grant select on ``mysql``.``time_zone_name`` to '$env:DB_MYSQL_USERNAME'@'%';
flush privileges;" |
mysql.exe --user=$env:DB_MYSQL_ROOT_USERNAME --password=$env:DB_MYSQL_ROOT_PASSWORD
Expand Down

0 comments on commit 617161c

Please sign in to comment.