-
Notifications
You must be signed in to change notification settings - Fork 90
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #113 from semsol/2.4
New release: 2.4
- Loading branch information
Showing
296 changed files
with
12,370 additions
and
8,100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 4 | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
#!/bin/bash | ||
|
||
# | ||
# acknowledgement: | ||
# copied from https://github.com/PyMySQL/PyMySQL/blob/master/.travis/initializedb.sh | ||
# | ||
|
||
# debug | ||
set -x | ||
# verbose | ||
set -v | ||
|
||
if [ ! -z "${DB}" ]; then | ||
# disable existing database server in case of accidential connection | ||
sudo service mysql stop | ||
|
||
docker pull ${DB} | ||
docker run -it --name=mysqld -d -e MYSQL_ALLOW_EMPTY_PASSWORD=yes -p 3306:3306 ${DB} | ||
sleep 10 | ||
|
||
mysql() { | ||
docker exec mysqld mysql "${@}" | ||
} | ||
while : | ||
do | ||
sleep 5 | ||
mysql -e 'select version()' | ||
if [ $? = 0 ]; then | ||
break | ||
fi | ||
echo "server logs" | ||
docker logs --tail 5 mysqld | ||
done | ||
|
||
mysql -e 'select VERSION()' | ||
|
||
if [ $DB == 'mysql:8.0' ]; then | ||
WITH_PLUGIN='with mysql_native_password' | ||
mysql -e 'SET GLOBAL local_infile=on' | ||
docker cp mysqld:/var/lib/mysql/public_key.pem "${HOME}" | ||
docker cp mysqld:/var/lib/mysql/ca.pem "${HOME}" | ||
docker cp mysqld:/var/lib/mysql/server-cert.pem "${HOME}" | ||
docker cp mysqld:/var/lib/mysql/client-key.pem "${HOME}" | ||
docker cp mysqld:/var/lib/mysql/client-cert.pem "${HOME}" | ||
else | ||
WITH_PLUGIN='' | ||
fi | ||
|
||
mysql -uroot -e 'create database testdb DEFAULT CHARACTER SET utf8mb4' | ||
else | ||
cat ~/.my.cnf | ||
|
||
mysql -e 'select VERSION()' | ||
mysql -e 'create database testdb DEFAULT CHARACTER SET utf8 DEFAULT COLLATE utf8_general_ci;' | ||
fi |
Oops, something went wrong.