[Temp] Check CI propel-orm 18.1 / propel beta2 #2261
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: CI | |
on: | |
pull_request: | |
push: | |
branches: | |
- master | |
workflow_dispatch: | |
jobs: | |
validation: | |
name: "CS, ArchSniffer, PHPStan, Evaluator" | |
runs-on: ubuntu-20.04 | |
strategy: | |
fail-fast: false | |
matrix: | |
php-version: [ | |
'8.0', | |
'8.1' | |
] | |
env: | |
APPLICATION_ENV: ci.mysql | |
APPLICATION_STORE: DE | |
PROJECT: suite | |
services: | |
redis: | |
image: redis | |
ports: | |
- 6379/tcp | |
options: --health-cmd="redis-cli ping" --health-interval=10s --health-timeout=5s --health-retries=3 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Configure sysctl limits | |
run: | | |
sudo swapoff -a | |
sudo sysctl -w vm.swappiness=1 | |
sudo sysctl -w fs.file-max=262144 | |
sudo sysctl -w vm.max_map_count=262144 | |
- name: Runs Elasticsearch | |
uses: elastic/elastic-github-actions/elasticsearch@master | |
with: | |
stack-version: 7.10.0 | |
port: 9200 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: '18' | |
- name: Setup PHP | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ matrix.php-version }} | |
extensions: mbstring, intl, pdo_mysql, redis | |
tools: composer:v2 | |
- name: Composer get cache directory | |
id: composer-cache | |
run: | | |
echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT | |
- name: Composer cache | |
uses: actions/cache@v3 | |
with: | |
path: ${{ steps.composer-cache.outputs.dir }} | |
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} | |
restore-keys: | | |
${{ runner.os }}-composer- | |
- name: Composer validate | |
run: composer validate | |
- name: Composer version | |
run: composer --version | |
- name: Composer install | |
run: composer install | |
- name: Generate transfer objects | |
run: vendor/bin/console transfer:generate | |
- name: Generate transfer databuilder objects | |
run: vendor/bin/console transfer:databuilder:generate | |
- name: Propel install | |
run: | | |
vendor/bin/console propel:schema:copy | |
vendor/bin/console propel:model:build | |
vendor/bin/console transfer:entity:generate | |
- name: Setup search | |
run: vendor/bin/console setup:search | |
- name: Codecept build | |
run: vendor/bin/codecept build --ansi | |
- name: Generate autocompletion files | |
run: vendor/bin/console dev:ide-auto-completion:generate | |
- name: Generate rest API dcoumentation | |
run: vendor/bin/console rest-api:generate:documentation | |
- name: Frontend install-dependencies | |
run: | | |
vendor/bin/console frontend:project:install-dependencies -vvv | |
- name: Install NPM packages | |
run: | | |
sudo npm i --location=global --unsafe-perm [email protected] | |
- name: Speccy lint Glue specification | |
run: speccy lint src/Generated/Glue/Specification/spryker_rest_api.schema.yml --rules=default | |
- name: Style lint | |
run: npm run yves:stylelint | |
- name: ES lint | |
run: npm run yves:lint | |
- name: Front-end Formatter | |
run: npm run formatter | |
- name: Front-end MP Lint | |
run: npm run mp:lint | |
- name: Front-end MP Style lint | |
run: npm run mp:stylelint | |
- name: Front-end MP Unit Tests | |
run: npm run mp:test | |
- name: Validate propel files | |
run: | | |
vendor/bin/console propel:schema:validate | |
vendor/bin/console propel:schema:validate-xml-names | |
- name: Validate transfer files | |
run: vendor/bin/console transfer:validate | |
- name: Run PHPStan | |
run: vendor/bin/phpstan analyze | |
- name: Run Architecture rules | |
run: vendor/bin/phpmd src/ text vendor/spryker/architecture-sniffer/src/ruleset.xml --minimumpriority 2 | |
- name: Run CodeStyle checks | |
run: vendor/bin/console code:sniff:style | |
- name: Run Evaluator | |
run: vendor/bin/evaluator evaluate | |
php-81-mariadb-glue-alpine: | |
name: "PHP 8.1 / MariaDB / Glue / Alpine" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.1 | |
TRAVIS: 1 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install apt-packages | |
run: | | |
sudo apt-get install apache2-utils | |
- name: Install docker-compose | |
run: | | |
sudo curl -L "https://github.com/docker/compose/releases/download/1.27.4/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
- name: Run docker | |
run: | | |
git clone https://github.com/spryker/docker-sdk.git ./docker | |
docker/sdk boot deploy.ci.api.mariadb.yml -v | |
docker/sdk up -t -v | |
docker/sdk testing codecept fixtures | |
docker/sdk testing console queue:worker:start --stop-when-empty | |
docker/sdk testing codecept run -c codeception.api.yml | |
php-81-mariadb-acceptance-alpine: | |
name: "PHP 8.1 / MariaDB / Acceptance / Alpine" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.1 | |
TRAVIS: 1 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install apt-packages | |
run: | | |
sudo apt-get install apache2-utils | |
- name: Install docker-compose | |
run: | | |
sudo curl -L "https://github.com/docker/compose/releases/download/1.27.4/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
- name: Run docker | |
run: | | |
git clone https://github.com/spryker/docker-sdk.git ./docker | |
docker/sdk boot -v deploy.ci.acceptance.mariadb.yml | |
docker/sdk up -t | |
docker/sdk testing console queue:worker:start --stop-when-empty | |
docker/sdk testing codecept run -c codeception.acceptance.yml | |
php-81-mariadb-functional-alpine: | |
name: "PHP 8.1 / MariaDB / Functional / Alpine" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.1 | |
TRAVIS: 1 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install apt-packages | |
run: | | |
sudo apt-get install apache2-utils | |
- name: Install docker-compose | |
run: | | |
sudo curl -L "https://github.com/docker/compose/releases/download/2.12.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
- name: Run docker | |
run: | | |
git clone https://github.com/spryker/docker-sdk.git ./docker | |
docker/sdk boot deploy.ci.functional.mariadb.yml -v | |
docker/sdk up -t -v | |
docker/sdk testing codecept run -c codeception.functional.yml | |
php-80-mariadb-glue-alpine: | |
name: "PHP 8.0 / MariaDB / Glue / Alpine" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.0 | |
TRAVIS: 1 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install apt-packages | |
run: | | |
sudo apt-get install apache2-utils | |
- name: Install docker-compose | |
run: | | |
sudo curl -L "https://github.com/docker/compose/releases/download/2.12.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
- name: Run docker | |
run: | | |
git clone https://github.com/spryker/docker-sdk.git ./docker | |
docker/sdk boot deploy.ci.api.mariadb.yml -v | |
docker/sdk up -t -v | |
docker/sdk testing codecept fixtures | |
docker/sdk testing console queue:worker:start --stop-when-empty | |
docker/sdk testing codecept run -c codeception.api.yml | |
php-80-postgresql-acceptance-alpine: | |
name: "PHP 8.0 / PostgreSQL / Acceptance / Alpine" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.0 | |
TRAVIS: 1 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install apt-packages | |
run: | | |
sudo apt-get install apache2-utils | |
- name: Install docker-compose | |
run: | | |
sudo curl -L "https://github.com/docker/compose/releases/download/2.12.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
- name: Run docker | |
run: | | |
git clone https://github.com/spryker/docker-sdk.git ./docker | |
docker/sdk boot -v deploy.ci.acceptance.yml | |
docker/sdk up -t | |
docker/sdk testing console queue:worker:start --stop-when-empty | |
docker/sdk testing codecept run -c codeception.acceptance.yml | |
php-80-postgresql-functional-alpine: | |
name: "PHP 8.0 / PostgreSQL / Functional / Alpine" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.0 | |
TRAVIS: 1 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install apt-packages | |
run: | | |
sudo apt-get install apache2-utils | |
- name: Install docker-compose | |
run: | | |
sudo curl -L "https://github.com/docker/compose/releases/download/2.12.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
- name: Run docker | |
run: | | |
git clone https://github.com/spryker/docker-sdk.git ./docker | |
docker/sdk boot -v deploy.ci.acceptance.yml | |
docker/sdk up -t | |
docker/sdk testing console queue:worker:start --stop-when-empty | |
docker/sdk testing codecept run -c codeception.functional.yml | |
php-80-mariadb-acceptance-alpine: | |
name: "PHP 8.0 / MariaDB / Acceptance / Alpine" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.0 | |
TRAVIS: 1 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install apt-packages | |
run: | | |
sudo apt-get install apache2-utils | |
- name: Install docker-compose | |
run: | | |
sudo curl -L "https://github.com/docker/compose/releases/download/2.12.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
- name: Run docker | |
run: | | |
git clone https://github.com/spryker/docker-sdk.git ./docker | |
docker/sdk boot -v deploy.ci.acceptance.mariadb.yml | |
docker/sdk up -t | |
docker/sdk testing console queue:worker:start --stop-when-empty | |
docker/sdk testing codecept run -c codeception.acceptance.yml | |
php-80-mariadb-functional-alpine: | |
name: "PHP 8.0 / MariaDB / Functional / Alpine" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.0 | |
TRAVIS: 1 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install apt-packages | |
run: | | |
sudo apt-get install apache2-utils | |
- name: Install docker-compose | |
run: | | |
sudo curl -L "https://github.com/docker/compose/releases/download/2.12.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
- name: Run docker | |
run: | | |
git clone https://github.com/spryker/docker-sdk.git ./docker | |
docker/sdk boot deploy.ci.functional.mariadb.yml -v | |
docker/sdk up -t -v | |
docker/sdk testing codecept run -c codeception.functional.yml | |
php-80-postgres-functional-debian: | |
name: "PHP 8.0 / PostgreSQL / Functional / Debian" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.0-debian | |
TRAVIS: 1 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install apt-packages | |
run: | | |
sudo apt-get install apache2-utils | |
- name: Install docker-compose | |
run: | | |
sudo curl -L "https://github.com/docker/compose/releases/download/2.12.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
- name: Run docker | |
run: | | |
git clone https://github.com/spryker/docker-sdk.git ./docker | |
docker/sdk boot deploy.ci.functional.yml -v | |
docker/sdk up -t -v | |
docker/sdk testing codecept run -c codeception.functional.yml | |
php-80-frontend-and-assets-alpine: | |
name: "PHP 8.0 / Frontend & Assets / Alpine" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.0 | |
TRAVIS: 1 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install apt-packages | |
run: | | |
sudo apt-get install apache2-utils | |
- name: Install docker-compose | |
run: | | |
sudo curl -L "https://github.com/docker/compose/releases/download/2.12.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
- name: Run docker | |
run: | | |
git clone https://github.com/spryker/docker-sdk.git ./docker | |
docker/sdk boot deploy.yml | |
SPRYKER_BUILD_HASH=myhash docker/sdk export images | |
docker run -i --rm -e SPRYKER_NGINX_CGI_HOST_YVES_EU=localhost -e SPRYKER_NGINX_CGI_HOST_BACKOFFICE_EU=localhost -e SPRYKER_NGINX_CGI_HOST_BACKEND_GATEWAY_EU=localhost -e SPRYKER_NGINX_CGI_HOST_BACKEND_API_EU=localhost -e SPRYKER_NGINX_CGI_HOST_GLUE_EU=localhost -e SPRYKER_NGINX_CGI_HOST_CONFIGURATOR_EU=localhost -e SPRYKER_NGINX_CGI_HOST_YVES_US=localhost -e SPRYKER_NGINX_CGI_HOST_GLUE_US=localhost -e SPRYKER_NGINX_CGI_HOST_BACKOFFICE_US=localhost -e SPRYKER_NGINX_CGI_HOST_BACKEND_GATEWAY_US=localhost -e SPRYKER_NGINX_CGI_HOST_BACKEND_API_US=localhost -e ALLOWED_IP=127.0.0.1 spryker_demo_frontend:1.0-frontend nginx -t | |
docker run -i --rm --entrypoint='' spryker_demo_frontend:1.0-frontend ls -al /data/public/Yves/assets/myhash | |
docker run -i --rm --entrypoint='' spryker_demo_frontend:1.0-frontend ls -al /data/public/Zed/assets/ | |
php-80-lowest: | |
name: "PHP 8.0 / Prefer Lowest" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.0 | |
TRAVIS: 1 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install apt-packages | |
run: | | |
sudo apt-get install apache2-utils | |
- name: Install prefer lowest | |
run: | | |
composer lowest-setup | |
- name: Run prefer lowest | |
run: | | |
composer lowest | |
docker-alpine-php-8-0-mariadb-robot: | |
name: "Docker / Alpine / PHP 8.0 / MariaDB / Robot" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.0 | |
TRAVIS: 1 | |
ROBOT_TESTS_ARTIFACTS_BUCKET_REGION: eu-west-1 | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.9' | |
- name: Install packages | |
run: | | |
sudo apt-get update | |
sudo apt-get install apache2-utils | |
sudo apt install awscli -q | |
python3 -m pip install --upgrade pip | |
python3 -m pip install -U robotframework | |
python3 -m pip install -U robotframework-requests | |
python3 -m pip install -U robotframework-jsonlibrary | |
python3 -m pip install -U robotframework-databaselibrary | |
python3 -m pip install PyMySQL | |
- name: Install docker-compose | |
run: | | |
sudo curl -L "https://github.com/docker/compose/releases/download/2.12.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
- name: Install Robot tests | |
run: | | |
git clone https://github.com/spryker/robotframework-suite-tests.git --single-branch --branch master robotframework-tests | |
- name: Install Project | |
continue-on-error: true | |
run: | | |
git clone https://github.com/spryker/docker-sdk.git ./docker | |
docker/sdk boot -v deploy.ci.acceptance.mariadb.yml | |
docker/sdk up -t -v | |
docker/sdk testing console queue:worker:start --stop-when-empty | |
sudo bash -c "echo '127.0.0.1 backend-api.at.spryker.local backend-api.de.spryker.local backend-gateway.at.spryker.local backend-gateway.de.spryker.local backoffice.at.spryker.local backoffice.de.spryker.local date-time-configurator-example.spryker.local glue.at.spryker.local glue.de.spryker.local yves.at.spryker.local yves.de.spryker.local glue-backend.de.spryker.local glue-storefront.de.spryker.local' >> /etc/hosts" | |
- name: Run Tests | |
run: | | |
cd robotframework-tests | |
robot -v env:api_suite --exclude skip-due-to-issueORskip-due-to-refactoring -d results -s tests.api.suite . | |
- name: Upload artifacts | |
if: always() | |
run: | | |
AWS_DEFAULT_REGION=${{env.ROBOT_TESTS_ARTIFACTS_BUCKET_REGION}} AWS_ACCESS_KEY_ID=${{ secrets.ROBOT_TESTS_ARTIFACTS_KEY }} AWS_SECRET_ACCESS_KEY=${{ secrets.ROBOT_TESTS_ARTIFACTS_SECRET }} aws s3 cp robotframework-tests/results s3://${{vars.ROBOT_TESTS_ARTIFACTS_BUCKET}}/suite/${GITHUB_RUN_ID}/PHP8.0MariaDBRobot/ \ | |
--recursive \ | |
--expires "$(date -d '+7 days' --utc +'%Y-%m-%dT%H:%M:%SZ')" | |
docker-alpine-php-8-1-postgresql-robot: | |
name: "Docker / Alpine / PHP 8.1 / PostgreSQL / Robot" | |
runs-on: ubuntu-20.04 | |
env: | |
PROGRESS_TYPE: plain | |
SPRYKER_PLATFORM_IMAGE: spryker/php:8.1 | |
TRAVIS: 1 | |
ROBOT_TESTS_ARTIFACTS_BUCKET_REGION: eu-west-1 | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.9' | |
- name: Install packages | |
run: | | |
sudo apt-get update | |
sudo apt-get install apache2-utils | |
sudo apt install awscli -q | |
python3 -m pip install --upgrade pip | |
python3 -m pip install -U robotframework | |
python3 -m pip install -U robotframework-requests | |
python3 -m pip install -U robotframework-jsonlibrary | |
python3 -m pip install -U robotframework-databaselibrary | |
python3 -m pip install psycopg2-binary | |
- name: Install docker-compose | |
run: | | |
sudo curl -L "https://github.com/docker/compose/releases/download/2.12.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose | |
sudo chmod +x /usr/local/bin/docker-compose | |
- name: Install Robot tests | |
run: | | |
git clone https://github.com/spryker/robotframework-suite-tests.git --single-branch --branch master robotframework-tests | |
- name: Install Project | |
continue-on-error: true | |
run: | | |
git clone https://github.com/spryker/docker-sdk.git ./docker | |
docker/sdk boot -v deploy.ci.acceptance.yml | |
docker/sdk up -t -v | |
docker/sdk testing console queue:worker:start --stop-when-empty | |
sudo bash -c "echo '127.0.0.1 backend-api.at.spryker.local backend-api.de.spryker.local backend-gateway.at.spryker.local backend-gateway.de.spryker.local backoffice.at.spryker.local backoffice.de.spryker.local date-time-configurator-example.spryker.local glue.at.spryker.local glue.de.spryker.local yves.at.spryker.local yves.de.spryker.local glue-backend.de.spryker.local glue-storefront.de.spryker.local' >> /etc/hosts" | |
- name: Run Tests | |
run: | | |
cd robotframework-tests | |
robot -v env:api_suite -v db_engine:psycopg2 --exclude skip-due-to-issueORskip-due-to-refactoring -d results -s tests.api.suite . | |
- name: Upload artifacts | |
if: always() | |
run: | | |
AWS_DEFAULT_REGION=${{env.ROBOT_TESTS_ARTIFACTS_BUCKET_REGION}} AWS_ACCESS_KEY_ID=${{ secrets.ROBOT_TESTS_ARTIFACTS_KEY }} AWS_SECRET_ACCESS_KEY=${{ secrets.ROBOT_TESTS_ARTIFACTS_SECRET }} aws s3 cp robotframework-tests/results s3://${{vars.ROBOT_TESTS_ARTIFACTS_BUCKET}}/suite/${GITHUB_RUN_ID}/PHP8.1PostgreSQLRobot/ \ | |
--recursive \ | |
--expires "$(date -d '+7 days' --utc +'%Y-%m-%dT%H:%M:%SZ')" | |