2024-05-04 00:53:37 +00:00
|
|
|
---
|
|
|
|
kind: pipeline
|
2024-05-14 16:18:54 +00:00
|
|
|
name: Docker - Quick Test
|
2024-05-04 00:53:37 +00:00
|
|
|
steps:
|
2024-05-11 09:19:56 +00:00
|
|
|
- name: run
|
2024-05-14 16:18:54 +00:00
|
|
|
image: bobicloudvision/phyre-panel:latest
|
2024-05-14 16:20:32 +00:00
|
|
|
environment:
|
|
|
|
DEBIAN_FRONTEND: noninteractive
|
|
|
|
commands:
|
2024-05-14 16:44:12 +00:00
|
|
|
- service mysql start
|
|
|
|
- service phyre start
|
2024-05-14 16:20:32 +00:00
|
|
|
- MAIN_REPO_DIR=$(pwd)
|
2024-05-14 22:30:35 +00:00
|
|
|
- apt-get install -yq rsync
|
2024-05-14 16:37:08 +00:00
|
|
|
- cp /usr/local/phyre/web/phyre-config.ini /usr/local/phyre/phyre-config.ini.bak
|
|
|
|
- rm -rf /usr/local/phyre/web
|
|
|
|
- cp -r $MAIN_REPO_DIR/web /usr/local/phyre/web
|
|
|
|
- cp /usr/local/phyre/phyre-config.ini.bak /usr/local/phyre/web/phyre-config.ini
|
2024-05-14 16:26:23 +00:00
|
|
|
- cd /usr/local/phyre/web/
|
2024-05-14 16:41:17 +00:00
|
|
|
- ls -la
|
2024-05-14 16:31:46 +00:00
|
|
|
- wget https://getcomposer.org/download/latest-stable/composer.phar
|
|
|
|
- COMPOSER_ALLOW_SUPERUSER=1 phyre-php composer.phar install
|
2024-05-14 16:42:51 +00:00
|
|
|
- phyre-php artisan phyre:set-ini-settings APP_ENV "local"
|
2024-05-14 16:41:17 +00:00
|
|
|
- phyre-php artisan migrate
|
2024-05-14 21:10:47 +00:00
|
|
|
- phyre-php artisan test
|
2024-05-14 16:50:34 +00:00
|
|
|
---
|
|
|
|
kind: pipeline
|
|
|
|
name: Ubuntu 22.04 - Unit Test & Code Coverage
|
|
|
|
steps:
|
|
|
|
- name: run
|
|
|
|
image: ubuntu:22.04
|
2024-05-14 22:17:48 +00:00
|
|
|
platform: linux/amd64
|
2024-05-14 16:50:34 +00:00
|
|
|
environment:
|
|
|
|
DEBIAN_FRONTEND: noninteractive
|
|
|
|
CODECOV_TOKEN:
|
|
|
|
from_secret: CODECOV_TOKEN
|
|
|
|
commands:
|
2024-05-14 18:45:13 +00:00
|
|
|
- export DEBIAN_FRONTEND=noninteractive
|
2024-05-14 16:50:34 +00:00
|
|
|
- MAIN_REPO_DIR=$(pwd)
|
|
|
|
- apt-get update
|
2024-05-14 22:34:10 +00:00
|
|
|
- apt-get install -yq libicu-dev sudo cron apt-utils daemonize dbus-user-session fontconfig rsync
|
2024-05-14 16:50:34 +00:00
|
|
|
- daemonize /usr/bin/unshare --fork --pid --mount-proc /lib/systemd/systemd --system-unit=basic.target
|
|
|
|
|
|
|
|
- ls -la
|
|
|
|
- mkdir /phyre-panel
|
|
|
|
|
|
|
|
- cp installers/ubuntu-22.04/install-partial/install_base.sh /phyre-panel/install_base.sh
|
|
|
|
- chmod +x /phyre-panel/install_base.sh
|
|
|
|
- /phyre-panel/install_base.sh
|
|
|
|
|
|
|
|
- cp installers/ubuntu-22.04/install-partial/install_web.sh /phyre-panel/install_web.sh
|
|
|
|
- chmod +x /phyre-panel/install_web.sh
|
|
|
|
|
|
|
|
- cp -r web /usr/local/phyre/web/
|
|
|
|
- cd /usr/local/phyre/web/
|
|
|
|
- ls -la
|
|
|
|
|
|
|
|
- wget https://getcomposer.org/download/latest-stable/composer.phar
|
|
|
|
- COMPOSER_ALLOW_SUPERUSER=1 phyre-php composer.phar install
|
|
|
|
|
|
|
|
- /phyre-panel/install_web.sh
|
|
|
|
|
|
|
|
- apt-get install autoconf build-essential -y
|
|
|
|
- mkdir -p /usr/local/phyre/php-xdebug
|
|
|
|
- cd /usr/local/phyre/php-xdebug
|
|
|
|
- wget http://xdebug.org/files/xdebug-3.3.2.tgz
|
|
|
|
- tar -xvzf xdebug-3.3.2.tgz
|
|
|
|
- cd xdebug-3.3.2
|
|
|
|
- /usr/local/phyre/php/bin/phpize
|
|
|
|
- ./configure --enable-xdebug --with-php-config=/usr/local/phyre/php/bin/php-config
|
|
|
|
- make
|
|
|
|
|
|
|
|
- mkdir -p /usr/local/phyre/php/zend-xdebug
|
|
|
|
- cp modules/xdebug.so /usr/local/phyre/php/zend-xdebug/xdebug.so
|
|
|
|
|
|
|
|
- chmod 777 /usr/local/phyre/php/zend-xdebug/xdebug.so
|
|
|
|
|
|
|
|
- cp /usr/local/phyre/web/tests/xdebug-php-ini.txt /usr/local/phyre/php/bin/php.ini
|
|
|
|
|
|
|
|
- chmod 777 /usr/local/phyre/php/bin/php.ini
|
|
|
|
- phyre-php -v
|
|
|
|
|
|
|
|
- cd /usr/local/phyre/web/
|
|
|
|
- chmod -R 777 vendor
|
|
|
|
- apt install composer -y
|
2024-05-14 22:04:10 +00:00
|
|
|
- phyre-php artisan phyre:set-ini-settings APP_ENV "local"
|
2024-05-14 16:50:34 +00:00
|
|
|
- composer test:coverage
|
|
|
|
- mv clover.xml $MAIN_REPO_DIR/clover.xml
|
|
|
|
- mv coverage.xml $MAIN_REPO_DIR/coverage.xml
|
|
|
|
- cd $MAIN_REPO_DIR
|
2024-05-14 22:30:35 +00:00
|
|
|
- apt install -yq pip
|
2024-05-14 16:50:34 +00:00
|
|
|
- pip install codecov-cli
|
|
|
|
- codecovcli --verbose upload-process -t $CODECOV_TOKEN
|