-
-
Save aduzsardi/cf0480f47626e7f3e7a8de45829b988f to your computer and use it in GitHub Desktop.
How to use composer (php) including cache with gitlab-ci
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
build:install-vendor: | |
stage: build | |
image: <any-image-with-composer> | |
before_script: | |
- composer config -g cache-dir "$(pwd)/.composer-cache" | |
script: | |
- composer install --ignore-platform-reqs --no-dev --optimize-autoloader --no-ansi --no-interaction --no-progress | |
cache: | |
paths: | |
- .composer-cache/ | |
artifacts: | |
expire_in: 30 min | |
paths: | |
- vendor/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment