Skip to content

Build Package

Build Package #8

Workflow file for this run

name: Build Package
on:
workflow_dispatch:
jobs:
deploy:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Get Branch Name
uses: nelonoel/[email protected]
- run: echo "BRANCH_NAME=${BRANCH_NAME}" >> $GITHUB_ENV
- name: Build & Deploy GPM Package
uses: appleboy/[email protected]
env:
BRANCH: ${{ env.BRANCH_NAME }}
with:
command_timeout: 20m
host: ${{ secrets.DEPLOY_HOST }}
key: ${{ secrets.DEPLOY_KEY }}
username: ${{ secrets.DEPLOY_USER }}
envs: BRANCH
script_stop: true
script: |
cd /www/pkgs/fred/
git add .
git stash
git fetch origin
git checkout -f $BRANCH
git pull origin $BRANCH
cd /www/pkgs/fred/core/components/fred/
/home/.bin/composer install --no-dev
cd /www/pkgs/fred/
npm install
npm run build
rm -rf _packages
/www/pkgs/gpm/cli/bin/gpm package:update --pkg fred --updateDB=alter
/www/pkgs/gpm/cli/bin/gpm package:build --pkg fred