CI/CD trigger test #12
Workflow file for this run
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: Review app on pull request | |
on: | |
pull_request: | |
branches: main | |
env: | |
BRANCH_NAME: ${{ github.head_ref || github.ref_name }} | |
CLEVER_SECRET: ${{ secrets.CLEVER_SECRET }} | |
CLEVER_TOKEN: ${{ secrets.CLEVER_TOKEN }} | |
#ORGA_ID: ${{ secrets.ORGA_ID }} | |
HUGO_VERSION: | |
jobs: | |
setup: | |
runs-on: ubuntu-latest | |
steps: | |
- id: install | |
run: npm install -g clever-tools | |
- id: connect | |
run: clever login --token ${{ env.CLEVER_TOKEN }} --secret ${{ env.CLEVER_SECRET }} | |
- id: create | |
run: clever create --type static-apache ${{ env.BRANCH_NAME }} --alias ${{ env.BRANCH_NAME }} --region par --org ${{secrets.ORGA_ID}} | |
- id: link | |
run: clever link ${{ env.BRANCH_NAME }} --alias ${{ env.BRANCH_NAME }} && clever scale --flavor XS | |
set-env: | |
runs-on: ubuntu-latest | |
steps: | |
- name: prebuild | |
run: clever env set CC_PRE_BUILD_HOOK "./clevercloud-deploy-script.sh" | |
- name: index | |
run: clever env set CC_WEBROOT "/public" | |
- name: hugo-env | |
run: clever env set HUGO_ENV "production" | |
- name: hugo-version | |
run: clever env set HUGO_VERSION ${{env.HUGO_VERSION}} | |
- name: php | |
run: clever env set CC_PHP_VERSION "7" | |
- name: hugo-env | |
run: clever env set HUGO_VERSION ${{env.HUGO_VERSION}} | |
- name: cgi | |
run: clever env set CC_CGI_IMPLEMENTATION "proxy_fcgi" | |
- name: composer | |
run: clever env set CC_COMPOSER_VERSION "2" | |
- name: domain | |
run: clever domain add ${{ env.BRANCH_NAME }}.cleverapps.io | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Set up app | |
run: clever deploy |