Update main.yml #4
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: Deploy app | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
clone: | |
runs-on: self-hosted | |
steps: | |
- name: Remove old repo | |
run: rm -rf T-Caps | |
- name: Clone repo | |
run: git clone https://github.com/HE-Arc/T-Caps.git | |
- name: Go to repo folder | |
run: cd T-Caps/T-Caps | |
- name: Composer install | |
run: composer install --optimize-autoloader --no-dev | |
- name: Npm install | |
run: npm install | |
- name: Copy .env file | |
run: cp ../../../../../.env .env | |
- name: Generate key | |
run: php artisan key:generate | |
- name: Migrate database | |
run: php artisan migrate | |
- name: Cache php artisan config | |
run: php artisan config:cache | |
- name: Cache php artisan route | |
run: php artisan route:cache | |
- name: Cache php artisan view | |
run: php artisan view:cache | |
- name: Npm run build | |
run: npm run build |