mirror of
https://code.forgejo.org/actions/setup-forgejo.git
synced 2024-11-23 20:50:58 -05:00
add parameters
This commit is contained in:
parent
9279b526cd
commit
579d09787e
2 changed files with 25 additions and 9 deletions
28
action.yml
28
action.yml
|
@ -1,20 +1,32 @@
|
||||||
name: 'Setup Forgejo'
|
name: 'Setup Forgejo'
|
||||||
|
author: 'Forgejo authors'
|
||||||
description: 'Setup Forgejo and a runner'
|
description: 'Setup Forgejo and a runner'
|
||||||
inputs:
|
inputs:
|
||||||
forgejo-image: # id of input
|
image:
|
||||||
description: 'Forgejo image'
|
description: 'Container image'
|
||||||
default: 'codeberg.org/forgejo/forgejo:v1.19'
|
default: 'codeberg.org/forgejo/forgejo'
|
||||||
|
image-version:
|
||||||
|
description: 'Container image version'
|
||||||
|
default: '1.19'
|
||||||
|
runner:
|
||||||
|
description: 'Runner git repository'
|
||||||
|
default: 'https://code.forgejo.org/fogejo/runner'
|
||||||
|
runner-version:
|
||||||
|
description: 'Runner version'
|
||||||
|
default: 'v1.4.1'
|
||||||
outputs:
|
outputs:
|
||||||
random-number:
|
url:
|
||||||
description: "Token"
|
description: "URL"
|
||||||
value: "token"
|
value: ${{ steps.forgejo.outputs.url }}"
|
||||||
runs:
|
runs:
|
||||||
using: "composite"
|
using: "composite"
|
||||||
steps:
|
steps:
|
||||||
- run: echo "${{ github.action_path }}" >> $GITHUB_PATH
|
- run: echo "${{ github.action_path }}" >> $GITHUB_PATH
|
||||||
shell: bash
|
shell: bash
|
||||||
- run: |
|
- id: forgejo
|
||||||
|
run: |
|
||||||
dependencies.sh
|
dependencies.sh
|
||||||
forgejo.sh setup root admin1234 codeberg.org/forgejo/forgejo:1.19
|
forgejo.sh setup root admin1234 ${{ inputs.image }}:${{ inputs.image-version }}
|
||||||
forgejo-runner.sh setup
|
forgejo-runner.sh setup
|
||||||
|
echo url="http://$(cat forgejo-ip):3000" >> $GITHUB_OUTPUT
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
6
testdata/try-setup-forgejo.yml
vendored
6
testdata/try-setup-forgejo.yml
vendored
|
@ -6,4 +6,8 @@ jobs:
|
||||||
runs-on: self-hosted
|
runs-on: self-hosted
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- uses: SELF/setup-forgejo@vTest
|
- id: forgejo
|
||||||
|
uses: SELF/setup-forgejo@vTest
|
||||||
|
- run:
|
||||||
|
set -ex
|
||||||
|
echo ${{ steps.forgejo.outputs.url }} | grep :3000
|
||||||
|
|
Loading…
Reference in a new issue