adjust rspamd user to froxlor #62
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
name: Froxlor-CI-MySQL | |
on: ['push', 'pull_request', 'create'] | |
jobs: | |
froxlor: | |
name: Froxlor (PHP ${{ matrix.php-versions }}, MySQL ${{ matrix.mysql-version }}) | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
php-versions: ['7.4', '8.2'] | |
mysql-version: [8.0, 5.7] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup PHP, with composer and extensions | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ matrix.php-versions }} | |
tools: composer:v2 | |
extensions: mbstring, xml, ctype, pdo_mysql, mysql, curl, json, zip, session, filter, posix, openssl, fileinfo, bcmath, gmp, gnupg | |
- name: Install tools | |
run: sudo apt-get install -y ant | |
- name: Adjust firewall | |
run: | | |
sudo ufw allow out 3306/tcp | |
sudo ufw allow in 3306/tcp | |
- name: Setup MySQL | |
uses: samin/[email protected] | |
with: | |
mysql version: ${{ matrix.mysql-version }} | |
mysql database: 'froxlor010' | |
mysql root password: 'fr0xl0r.TravisCI' | |
- name: Wait for database | |
run: sleep 15 | |
- name: Setup database | |
run: | | |
mysql -h 127.0.0.1 --protocol=TCP -u root -pfr0xl0r.TravisCI -e "CREATE USER 'froxlor010'@'%' IDENTIFIED BY 'fr0xl0r.TravisCI';" | |
mysql -h 127.0.0.1 --protocol=TCP -u root -pfr0xl0r.TravisCI -e "GRANT ALL ON froxlor010.* TO 'froxlor010'@'%';" | |
php -r "echo include('install/froxlor.sql.php');" > /tmp/froxlor.sql | |
mysql -h 127.0.0.1 --protocol=TCP -u root -pfr0xl0r.TravisCI froxlor010 < /tmp/froxlor.sql | |
- name: Run testing | |
run: ant quick-build |