44 lines
1.3 KiB
YAML
44 lines
1.3 KiB
YAML
name: 'Build Agent'
|
|
on:
|
|
workflow_dispatch:
|
|
inputs:
|
|
branch:
|
|
description: 'Ветка'
|
|
required: true
|
|
type: string
|
|
default: 'feature/DEVX-191'
|
|
jobs:
|
|
deploy-dev:
|
|
name: 'Deploy to dev'
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: 'Print Info'
|
|
run: |
|
|
echo "Cloning ${{ github.event.inputs.repo_path }}"
|
|
echo "From branch ${{ github.event.inputs.branch }}"
|
|
- name: Cloning
|
|
uses: https://git.binom.pw/otp/devops/clone@main
|
|
with:
|
|
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
|
|
repository: 'devspc/devspace-agent'
|
|
branch: ${{ github.event.inputs.branch }}
|
|
- uses: https://git.binom.pw/otp/devops/config-gradle@main
|
|
- uses: https://git.binom.pw/otp/devops/setup-gradle@main
|
|
- name: Setup Jvm
|
|
uses: actions/setup-java@v4
|
|
with:
|
|
java-version: 21
|
|
distribution: "adopt"
|
|
- name: Building
|
|
run: |
|
|
./gradlew shadowJar --no-daemon -x cyclonedxBom
|
|
echo 'Jar in libs folder'
|
|
ls ./build/libs
|
|
- name: 'Cleanup'
|
|
if: always()
|
|
shell: bash
|
|
run: |
|
|
echo 'Cleaning...'
|
|
rm -rf ~/.gradle/init.gradle.kts
|
|
rm -rf ~/.ssh/config
|
|
rm -rf ~/.ssh/my_key |