2024-03-12 10:39:01 +03:00
|
|
|
name: Gitea Actions
|
2024-03-12 10:17:09 +03:00
|
|
|
run-name: ${{ gitea.actor }} is testing out Gitea Actions ??
|
|
|
|
on: [push]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
Explore-Gitea-Actions:
|
2024-03-12 10:58:13 +03:00
|
|
|
runs-on: ubuntu
|
2024-03-12 10:17:09 +03:00
|
|
|
steps:
|
2024-03-12 12:48:27 +03:00
|
|
|
- run: cat "${{ vars.ENV_PROD }}" > .env
|
2024-03-12 10:39:01 +03:00
|
|
|
- run: echo "Stopping gitea service..."
|
2024-03-12 11:01:03 +03:00
|
|
|
- run: systemctl stop resume
|
2024-03-12 10:39:01 +03:00
|
|
|
- run: echo "Gitea service stopped"
|
|
|
|
- run: echo "Pulling repo..."
|
2024-03-12 10:17:09 +03:00
|
|
|
- name: Check out repository code
|
|
|
|
uses: actions/checkout@v3
|
2024-03-12 10:39:01 +03:00
|
|
|
- run: echo "Repo pulled"
|
|
|
|
- run: echo "Updating npm dependencies..."
|
2024-03-12 12:42:45 +03:00
|
|
|
- run: pwd; node -v; npm i --progress=false;
|
2024-03-12 10:39:01 +03:00
|
|
|
- run: echo "NPM dependencies updated"
|
|
|
|
- run: echo "Updating composer dependencies..."
|
2024-03-12 12:42:45 +03:00
|
|
|
- run: pwd; export COMPOSER_ALLOW_SUPERUSER=1; composer show; composer update;
|
2024-03-12 10:39:01 +03:00
|
|
|
- run: echo "Composer dependencies updated"
|
|
|
|
- run: echo "Building frontend..."
|
2024-03-12 12:42:45 +03:00
|
|
|
- run: pwd; npm run build;
|
2024-03-12 10:39:01 +03:00
|
|
|
- run: echo "Frontend built"
|
|
|
|
- run: echo "Starting Gitea service"
|
2024-03-12 12:02:45 +03:00
|
|
|
- run: systemctl start resume
|
2024-03-12 10:39:01 +03:00
|
|
|
- run: echo "Gitea service started"
|