All checks were successful
Build / build (push) Successful in 31s
* Use deploy workflow for staging, too * Reduce deploy.sh script
39 lines
893 B
YAML
39 lines
893 B
YAML
name: Deploy
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
inputs:
|
|
hostname:
|
|
description: Hostname
|
|
type: string
|
|
required: true
|
|
default: antville.org
|
|
|
|
jobs:
|
|
stage:
|
|
runs-on: antville
|
|
|
|
environment:
|
|
name: production
|
|
url: ${{ inputs.hostname }}
|
|
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Build with Gradle
|
|
run: ./gradlew installDist
|
|
|
|
- name: Copy build files to server
|
|
run: |
|
|
rsync ./build/install/helma/ ${{ inputs.hostname }}:./ \
|
|
--verbose --archive --delete --compress \
|
|
--filter '+ /bin' \
|
|
--filter '+ /extras' \
|
|
--filter '+ /launcher.jar' \
|
|
--filter '- /lib/ext' \
|
|
--filter '+ /lib' \
|
|
--filter '+ /modules' \
|
|
--filter '- /*'
|
|
|
|
- name: Restart Helma
|
|
run: ssh ${{ inputs.hostname }} restart
|