Last active
April 6, 2022 05:36
-
-
Save yousuf-hossain-shanto/c5630f9cfd1378c78408946e63c12283 to your computer and use it in GitHub Desktop.
Gitlab CI for Laravel Vapor
This file contains hidden or 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
| deploy: | |
| stage: deploy | |
| rules: | |
| - if: '$CI_PIPELINE_SOURCE == "merge_request_event"' | |
| when: never | |
| - if: '$CI_COMMIT_BRANCH == "develop"' | |
| when: always | |
| image: bitnami/laravel | |
| variables: | |
| VAPOR_API_TOKEN: $VAPOR_API_TOKEN | |
| script: | |
| - composer install --no-interaction --prefer-dist --optimize-autoloader | |
| - composer global require laravel/vapor-cli | |
| - VAPOR_API_TOKEN=$VAPOR_API_TOKEN ./vendor/bin/vapor deploy staging --commit="${CI_COMMIT_ID}" --message="${CI_MESSAGE}" |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Working on merge and push branch. Fixed duplicate job issue on merge request
developto branch you want to deploy fromstagingto your Laravel Vapor deploy typeOne more thing, don't forget to hit on star 😌