mirror of
https://code.forgejo.org/actions/setup-forgejo.git
synced 2024-11-23 21:40:59 -05:00
pass through the runner inputs
This commit is contained in:
parent
0bc6cdef11
commit
e9c25f1577
2 changed files with 6 additions and 4 deletions
|
@ -16,7 +16,7 @@ inputs:
|
||||||
default: 'admin1234'
|
default: 'admin1234'
|
||||||
runner:
|
runner:
|
||||||
description: 'Runner git repository'
|
description: 'Runner git repository'
|
||||||
default: 'https://code.forgejo.org/fogejo/runner'
|
default: 'https://code.forgejo.org/forgejo/runner'
|
||||||
runner-version:
|
runner-version:
|
||||||
description: 'Runner version'
|
description: 'Runner version'
|
||||||
default: 'v1.4.1'
|
default: 'v1.4.1'
|
||||||
|
@ -44,7 +44,7 @@ runs:
|
||||||
cd $(mktemp -d)
|
cd $(mktemp -d)
|
||||||
dependencies.sh
|
dependencies.sh
|
||||||
forgejo.sh setup ${{ inputs.user }} "${{ inputs.password }}" ${{ inputs.image }}:${{ inputs.image-version }}
|
forgejo.sh setup ${{ inputs.user }} "${{ inputs.password }}" ${{ inputs.image }}:${{ inputs.image-version }}
|
||||||
forgejo-runner.sh setup
|
forgejo-runner.sh setup ${{ inputs.runner }} ${{ inputs.runner-version }} http://$(cat forgejo-ip):3000/
|
||||||
echo url="http://$(cat forgejo-ip):3000" >> $GITHUB_OUTPUT
|
echo url="http://$(cat forgejo-ip):3000" >> $GITHUB_OUTPUT
|
||||||
echo host-port="$(cat forgejo-ip):3000" >> $GITHUB_OUTPUT
|
echo host-port="$(cat forgejo-ip):3000" >> $GITHUB_OUTPUT
|
||||||
echo token=$(cat forgejo-token) >> $GITHUB_OUTPUT
|
echo token=$(cat forgejo-token) >> $GITHUB_OUTPUT
|
||||||
|
|
|
@ -41,12 +41,14 @@ function register() {
|
||||||
function run() {
|
function run() {
|
||||||
./forgejo-runner/forgejo-runner daemon >& forgejo-runner.log &
|
./forgejo-runner/forgejo-runner daemon >& forgejo-runner.log &
|
||||||
echo $! > forgejo-runner-pid
|
echo $! > forgejo-runner-pid
|
||||||
|
sleep 1
|
||||||
|
cat forgejo-runner.log
|
||||||
}
|
}
|
||||||
|
|
||||||
function setup() {
|
function setup() {
|
||||||
local git="${1:-https://codeberg.org/forgejo/runner}"
|
local git="${1:-https://codeberg.org/forgejo/runner}"
|
||||||
local version="${1:-v1.4.1}"
|
local version="${2:-v1.4.1}"
|
||||||
local forgejo="${1:-http://$(cat forgejo-ip):3000/}"
|
local forgejo="${3:-http://$(cat forgejo-ip):3000/}"
|
||||||
|
|
||||||
dependencies
|
dependencies
|
||||||
checkout $git
|
checkout $git
|
||||||
|
|
Loading…
Reference in a new issue