image: php:7.1.5-cli before_script: - ... stuff ... stages: - test - build - deploy test: stage: test artifacts: paths: - vendor/ script: - php composer.phar install - vendor/bin/codecept run stage_build: stage: build only: - master artifacts: paths: - vendor/ - public/js/ - public/css/ script: - apt-get install -y npm - ln -s /usr/bin/nodejs /usr/bin/node - php composer.phar install --no-dev - npm install -g gulp - npm install - gulp deploy stage_deploy: stage: deploy only: - master script: - ... stuff ...