You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
We want to configure a pipeline for one of our projects, we are occuring an issue related to Bitbucket's Pipeline.
On a given step, we want to perform tests:
There is our step:
- step: &Tests
name: Build Prisma to perform tests
- eval $(cat secrets.def | sed 's/^/export /')
- pecl install xdebug
- docker-php-ext-enable xdebug
- export XDEBUG_MODE=coverage
curl -sSL https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions -o - | sh -s \
- cp .env.testing .env
- curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
- composer install
- export APP_URL="http://host.docker.internal:8000"
- php artisan key:generate
- php artisan migrate
- php artisan optimize && php artisan optimize:clear
- echo "memory_limit = 512M" > $PHP_INI_DIR/conf.d/php-memory-limits.ini
- php artisan test --coverage
And this is the result:
We watched on host.docker.internal (it changes nothing), also increase the available memory, same result.
I hope there is someone to help us.
Based on the output you posted here, the error seems to be related to your source code rather than an issue with Pipelines.
At the end of the screenshot, the following error is mentioned
TypeError: Unsupported operand types: string * int in <...>
along with the path of a file. I would suggest starting by checking this specific file.
/opt/atlassian/pipelines/agent/build is the path where the repo is cloned in the Docker container where the build is running. The rest should be the path of this file in your repo unless you generate this file during the build.
Hello @Theodora Boudale
Thank you for your answer, I was in holidays, my collegues did read your response and continue digging. They find a difference between development branch and our pipelines ; an environment variable was empty for PHP (SESSION_LIFETIME).
They also seperated php's server and vite too, the first one was not running because `npm run dev` took priority. It works fine now.