Add workflow_dispatch and build args for API URL
This commit is contained in:
parent
c99a772b54
commit
b1bd08ba7a
2 changed files with 18 additions and 0 deletions
9
.github/workflows/ci.yml
vendored
9
.github/workflows/ci.yml
vendored
|
|
@ -5,6 +5,13 @@ on:
|
|||
branches: [main, master]
|
||||
pull_request:
|
||||
branches: [main, master]
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
api_url:
|
||||
description: 'API URL'
|
||||
required: false
|
||||
default: 'http://ut.khoavo.myds.me:8981/api'
|
||||
type: string
|
||||
|
||||
jobs:
|
||||
lint:
|
||||
|
|
@ -103,3 +110,5 @@ jobs:
|
|||
platforms: linux/amd64
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
build-args: |
|
||||
NEXT_PUBLIC_API_URL=${{ github.event.inputs.api_url || 'http://ut.khoavo.myds.me:8981/api' }}
|
||||
|
|
|
|||
9
.github/workflows/docker-publish.yml
vendored
9
.github/workflows/docker-publish.yml
vendored
|
|
@ -4,6 +4,13 @@ on:
|
|||
push:
|
||||
tags:
|
||||
- 'v*'
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
api_url:
|
||||
description: 'API URL'
|
||||
required: false
|
||||
default: 'http://ut.khoavo.myds.me:8981/api'
|
||||
type: string
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
|
@ -45,3 +52,5 @@ jobs:
|
|||
platforms: linux/amd64
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
build-args: |
|
||||
NEXT_PUBLIC_API_URL=${{ github.event.inputs.api_url || 'http://ut.khoavo.myds.me:8981/api' }}
|
||||
|
|
|
|||
Loading…
Reference in a new issue