Skip to content

Commit

Permalink
Merge pull request #105 from creative-commoners/pulls/1.6/more-debug-…
Browse files Browse the repository at this point in the history
…output

MNT Output more info for debugging failures
  • Loading branch information
sabina-talipova authored Feb 21, 2024
2 parents 792671b + 65fed72 commit dd462e7
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,8 @@ jobs:
fi
echo "PHP has been configured"
echo "PHP info:"
php -i
- name: Install additional requirements
env:
Expand Down Expand Up @@ -680,14 +682,19 @@ jobs:
# each newline in the .env file
if [[ "${{ matrix.db }}" =~ mysql ]]; then
if [[ "${{ matrix.db }}" == "mysql57pdo" ]]; then
echo "mysql version":
mysql --port=3357 --version
cat << EOF > .env
SS_DATABASE_CLASS="MySQLPDODatabase"
SS_DATABASE_PORT="3357"
EOF
else
MYSQL_PORT=${{ matrix.db == 'mysql57' && '3357' || '3380' }}
echo "mysql version":
mysql --port=$MYSQL_PORT --version
cat << EOF > .env
SS_DATABASE_CLASS="MySQLDatabase"
SS_DATABASE_PORT="${{ matrix.db == 'mysql57' && '3357' || '3380' }}"
SS_DATABASE_PORT="${MYSQL_PORT}"
EOF
fi
cat << EOF >> .env
Expand All @@ -696,6 +703,8 @@ jobs:
SS_DATABASE_PASSWORD="root"
EOF
elif [[ "${{ matrix.db }}" =~ pgsql ]]; then
echo "postgres version:"
psql --version
cat << EOF > .env
SS_DATABASE_CLASS="PostgreSQLDatabase"
SS_DATABASE_SERVER="localhost"
Expand All @@ -704,13 +713,17 @@ jobs:
SS_DATABASE_PASSWORD="postgres"
EOF
elif [[ "${{ matrix.db }}" =~ sqlite3 ]]; then
echo "sqlite version":
sqlite3 --version
cat << EOF > .env
SS_DATABASE_CLASS="SQLite3Database"
SS_DATABASE_USERNAME="root"
SS_DATABASE_PASSWORD=""
SS_SQLITE_DATABASE_PATH=":memory:"
EOF
elif [[ "${{ matrix.db }}" =~ mariadb ]]; then
echo "mariadb version":
mysql --port=3311 --version
cat << EOF > .env
SS_DATABASE_SERVER="127.0.0.1"
SS_DATABASE_PORT="3311"
Expand Down

0 comments on commit dd462e7

Please sign in to comment.