Skip to content

Commit

Permalink
fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
lejianwen committed Sep 29, 2024
1 parent 857abc1 commit eb5c7ef
Show file tree
Hide file tree
Showing 4 changed files with 96 additions and 27 deletions.
18 changes: 9 additions & 9 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ on:

env:
LATEST_TAG: latest
WEBCLIENT_SOURCE_LOCATION: ${{ github.event.inputs.WEBCLIENT_SOURCE_LOCATION }}
WEBCLIENT_SOURCE_LOCATION: ${{ github.event.inputs.WEBCLIENT_SOURCE_LOCATION || 'https://github.com/lejianwen/rustdesk-api-web' }}
BASE_IMAGE_NAMESPACE: ${{ github.event.inputs.BASE_IMAGE_NAMESPACE || github.actor }}
DOCKERHUB_IMAGE_NAMESPACE: ${{ github.event.inputs.DOCKERHUB_IMAGE_NAMESPACE || github.actor }}
GHCR_IMAGE_NAMESPACE: ${{ github.event.inputs.GHCR_IMAGE_NAMESPACE || github.actor }}
Expand Down Expand Up @@ -256,17 +256,17 @@ jobs:
uses: Noelware/docker-manifest-action@master
with:
base-image: ${{ env.BASE_IMAGE_NAMESPACE }}/rustdesk-api:${{ env.TAG }}
extra-images: ${{ env.DOCKERHUB_IMAGE_NAMESPACE }}/rustdesk-api:${{ env.TAG }}-amd64,
${{ env.DOCKERHUB_IMAGE_NAMESPACE }}/rustdesk-api:${{ env.TAG }}-arm64
extra-images: ${{ env.DOCKERHUB_IMAGE_NAMESPACE }}/rustdesk-api:${{ env.TAG }}-amd64,
${{ env.DOCKERHUB_IMAGE_NAMESPACE }}/rustdesk-api:${{ env.TAG }}-arm64
push: true

- name: Create and push manifest GHCR (:version)
if: ${{ env.SKIP_GHCR == 'false' }}
uses: Noelware/docker-manifest-action@master
with:
base-image: ghcr.io/${{ env.BASE_IMAGE_NAMESPACE }}/rustdesk-api:${{ env.TAG }}
extra-images: ghcr.io/${{ env.GHCR_IMAGE_NAMESPACE }}/rustdesk-api:${{ env.TAG }}-amd64,
ghcr.io/${{ env.GHCR_IMAGE_NAMESPACE }}/rustdesk-api:${{ env.TAG }}-arm64
extra-images: ghcr.io/${{ env.GHCR_IMAGE_NAMESPACE }}/rustdesk-api:${{ env.TAG }}-amd64,
ghcr.io/${{ env.GHCR_IMAGE_NAMESPACE }}/rustdesk-api:${{ env.TAG }}-arm64
push: true
amend: true

Expand All @@ -275,16 +275,16 @@ jobs:
uses: Noelware/docker-manifest-action@master
with:
base-image: ${{ env.BASE_IMAGE_NAMESPACE }}/rustdesk-api:latest
extra-images: ${{ env.DOCKERHUB_IMAGE_NAMESPACE }}/rustdesk-api:latest-amd64,
${{ env.DOCKERHUB_IMAGE_NAMESPACE }}/rustdesk-api:latest-arm64
extra-images: ${{ env.DOCKERHUB_IMAGE_NAMESPACE }}/rustdesk-api:latest-amd64,
${{ env.DOCKERHUB_IMAGE_NAMESPACE }}/rustdesk-api:latest-arm64
push: true

- name: Create and push manifest GHCR (:latest)
if: ${{ env.SKIP_GHCR == 'false' }}
uses: Noelware/docker-manifest-action@master
with:
base-image: ghcr.io/${{ env.BASE_IMAGE_NAMESPACE }}/rustdesk-api:latest
extra-images: ghcr.io/${{ env.GHCR_IMAGE_NAMESPACE }}/rustdesk-api:latest-amd64,
ghcr.io/${{ env.GHCR_IMAGE_NAMESPACE }}/rustdesk-api:latest-arm64
extra-images: ghcr.io/${{ env.GHCR_IMAGE_NAMESPACE }}/rustdesk-api:latest-amd64,
ghcr.io/${{ env.GHCR_IMAGE_NAMESPACE }}/rustdesk-api:latest-arm64
push: true
amend: true
38 changes: 32 additions & 6 deletions docs/admin/admin_docs.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const docTemplateadmin = `{
"token": []
}
],
"description": "创建地址簿",
"description": "批量创建地址簿",
"consumes": [
"application/json"
],
Expand All @@ -32,7 +32,7 @@ const docTemplateadmin = `{
"tags": [
"地址簿"
],
"summary": "创建地址簿",
"summary": "批量创建地址簿",
"parameters": [
{
"description": "地址簿信息",
Expand Down Expand Up @@ -1242,7 +1242,7 @@ const docTemplateadmin = `{
"token": []
}
],
"description": "设备删除",
"description": "批量设备删除",
"consumes": [
"application/json"
],
Expand All @@ -1252,15 +1252,15 @@ const docTemplateadmin = `{
"tags": [
"设备"
],
"summary": "设备删除",
"summary": "批量设备删除",
"parameters": [
{
"description": "设备信息",
"description": "设备id",
"name": "body",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/admin.PeerForm"
"$ref": "#/definitions/admin.PeerBatchDeleteForm"
}
}
],
Expand Down Expand Up @@ -1365,6 +1365,12 @@ const docTemplateadmin = `{
"description": "页大小",
"name": "page_size",
"in": "query"
},
{
"type": "integer",
"description": "时间",
"name": "time_ago",
"in": "query"
}
],
"responses": {
Expand Down Expand Up @@ -2311,6 +2317,12 @@ const docTemplateadmin = `{
"user_id": {
"type": "integer"
},
"user_ids": {
"type": "array",
"items": {
"type": "integer"
}
},
"username": {
"type": "string"
}
Expand Down Expand Up @@ -2398,6 +2410,20 @@ const docTemplateadmin = `{
}
}
},
"admin.PeerBatchDeleteForm": {
"type": "object",
"required": [
"row_ids"
],
"properties": {
"row_ids": {
"type": "array",
"items": {
"type": "integer"
}
}
}
},
"admin.PeerForm": {
"type": "object",
"properties": {
Expand Down
38 changes: 32 additions & 6 deletions docs/admin/admin_swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"token": []
}
],
"description": "创建地址簿",
"description": "批量创建地址簿",
"consumes": [
"application/json"
],
Expand All @@ -25,7 +25,7 @@
"tags": [
"地址簿"
],
"summary": "创建地址簿",
"summary": "批量创建地址簿",
"parameters": [
{
"description": "地址簿信息",
Expand Down Expand Up @@ -1235,7 +1235,7 @@
"token": []
}
],
"description": "设备删除",
"description": "批量设备删除",
"consumes": [
"application/json"
],
Expand All @@ -1245,15 +1245,15 @@
"tags": [
"设备"
],
"summary": "设备删除",
"summary": "批量设备删除",
"parameters": [
{
"description": "设备信息",
"description": "设备id",
"name": "body",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/admin.PeerForm"
"$ref": "#/definitions/admin.PeerBatchDeleteForm"
}
}
],
Expand Down Expand Up @@ -1358,6 +1358,12 @@
"description": "页大小",
"name": "page_size",
"in": "query"
},
{
"type": "integer",
"description": "时间",
"name": "time_ago",
"in": "query"
}
],
"responses": {
Expand Down Expand Up @@ -2304,6 +2310,12 @@
"user_id": {
"type": "integer"
},
"user_ids": {
"type": "array",
"items": {
"type": "integer"
}
},
"username": {
"type": "string"
}
Expand Down Expand Up @@ -2391,6 +2403,20 @@
}
}
},
"admin.PeerBatchDeleteForm": {
"type": "object",
"required": [
"row_ids"
],
"properties": {
"row_ids": {
"type": "array",
"items": {
"type": "integer"
}
}
}
},
"admin.PeerForm": {
"type": "object",
"properties": {
Expand Down
29 changes: 23 additions & 6 deletions docs/admin/admin_swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ definitions:
type: array
user_id:
type: integer
user_ids:
items:
type: integer
type: array
username:
type: string
required:
Expand Down Expand Up @@ -107,6 +111,15 @@ definitions:
- op
- redirect_url
type: object
admin.PeerBatchDeleteForm:
properties:
row_ids:
items:
type: integer
type: array
required:
- row_ids
type: object
admin.PeerForm:
properties:
cpu:
Expand Down Expand Up @@ -473,7 +486,7 @@ paths:
post:
consumes:
- application/json
description: 创建地址簿
description: 批量创建地址簿
parameters:
- description: 地址簿信息
in: body
Expand All @@ -499,7 +512,7 @@ paths:
$ref: '#/definitions/response.Response'
security:
- token: []
summary: 创建地址簿
summary: 批量创建地址簿
tags:
- 地址簿
/admin/address_book/delete:
Expand Down Expand Up @@ -1196,14 +1209,14 @@ paths:
post:
consumes:
- application/json
description: 设备删除
description: 批量设备删除
parameters:
- description: 设备信息
- description: 设备id
in: body
name: body
required: true
schema:
$ref: '#/definitions/admin.PeerForm'
$ref: '#/definitions/admin.PeerBatchDeleteForm'
produces:
- application/json
responses:
Expand All @@ -1217,7 +1230,7 @@ paths:
$ref: '#/definitions/response.Response'
security:
- token: []
summary: 设备删除
summary: 批量设备删除
tags:
- 设备
/admin/peer/detail/{id}:
Expand Down Expand Up @@ -1266,6 +1279,10 @@ paths:
in: query
name: page_size
type: integer
- description: 时间
in: query
name: time_ago
type: integer
produces:
- application/json
responses:
Expand Down

0 comments on commit eb5c7ef

Please sign in to comment.