Skip to content

Commit 5bfb81a

Browse files
author
root
committed
fix migrations
1 parent cc688bb commit 5bfb81a

108 files changed

Lines changed: 2010 additions & 3856 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Makefile

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ help:
4444
@echo " make sync-store Refresh web/public/store/*.json from artifact.websoft9.com"
4545
@echo " make run Copy artifacts + restart services (~10s)"
4646
@echo " make run 9092 Copy artifacts + restart on custom port"
47-
@echo " make redo Full rebuild: rm volumes + build + image + start dev"
47+
@echo " make redo Full rebuild: build + image, then replace container/volumes + start dev"
4848
@echo ""
4949
@printf "\033[36mTesting & Quality:\033[0m\n"
5050
@echo " make test Run strict tests (Go + JS + E2E smoke, stop early)"
@@ -236,17 +236,17 @@ else
236236
endif
237237

238238
redo:
239-
@echo "Full rebuild: removing container + volumes, then building and restarting..."
240-
@docker rm -f $$(docker ps -aq --filter name=$(CONTAINER)) 2>/dev/null || true
241-
@$(COMPOSE_CMD) down --timeout 5 -v 2>/dev/null || true
242-
@echo "✓ Container and volumes removed"
239+
@echo "Full rebuild: building artifacts and image before replacing container + volumes..."
243240
@if grep -q '^APPOS_SECRET_KEY=replace-with-a-random-base64-secret' build/.env 2>/dev/null; then \
244241
NEW_KEY=$$(openssl rand -base64 32); \
245242
sed -i "s|^APPOS_SECRET_KEY=replace-with-a-random-base64-secret|APPOS_SECRET_KEY=$$NEW_KEY|" build/.env; \
246243
echo "✓ Generated APPOS_SECRET_KEY in build/.env"; \
247244
fi
248245
@$(MAKE) build
249246
@$(MAKE) image build-local
247+
@docker rm -f $$(docker ps -aq --filter name=$(CONTAINER)) 2>/dev/null || true
248+
@$(COMPOSE_CMD) down --timeout 5 -v 2>/dev/null || true
249+
@echo "✓ Previous container and volumes removed after successful build"
250250
@$(MAKE) start dev
251251
@sleep 3
252252
@docker exec $(CONTAINER) supervisorctl -c /etc/supervisor/supervisord.conf restart appos 2>/dev/null || true

Note.md

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -128,32 +128,24 @@ resource/  server/  database/  integration/  registry/  ...
128128
1. 如果你要把“网络可达性”再升级成应用层探测,我下一步可以把 MySQL/PostgreSQL/Redis/Kafka 从 TCP 通断扩展到协议握手级检查。
129129
2. 把 connectors 和 servers 里还保留的旧版 “新建 Secret” 对话框也完全切到 SecretCreateDialog.tsx。
130130

131-
132131
add resource 统一入口,仍然没有链接到具体的创建弹窗,而仅仅是列表页。除了 server 之外
133132

134-
135133
tunnul 的Port Forward Effective Mappings 区域没有显示具体的内容了
136134

137-
Prerequisites
138-
139-
140-
141135
请将 epic29 下的几个 story 名称更改一下
142136

143137
除了 story29.xx 名称的前缀之外,文件名称最多不超过3个单词
144138

145139
ports tab 不稳定,经常打开显示 somethins wrong
146140

147-
148141
addons 的 netdata restart 报错
149142

150143
去掉所有与 docker.sock 的强依赖与硬编码
151144

152-
rss 文章总数量,每个 source 文章上限问题,清理机制
153-
154-
155-
145+
## 去nginx 改造
156146

147+
## dockerfile
157148

149+
1. 明确 curl/wget, tar,unzip 等目前是走容器命令,还是走的 golang 包
158150

159-
## 去nginx 改造
151+
数据初始化怎么做的?

backend/docs/openapi/api.yaml

Lines changed: 2 additions & 134 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,6 @@ tags:
5555
name: Realtime
5656
- description: Release inventory and app-scoped release inspection APIs.
5757
name: Releases
58-
- description: Generic resource-store collection APIs for scripts only.
59-
name: Resource
6058
- description: Secret storage, rotation, resolve, and reveal APIs.
6159
name: Secrets
6260
- description: Server registry CRUD and remote operations APIs for connectivity, power, cron, ports, and systemd management.
@@ -112,6 +110,8 @@ components:
112110
type: string
113111
reference:
114112
type: string
113+
script_extension:
114+
type: string
115115
source_kind:
116116
type: string
117117
storage_kind:
@@ -5494,138 +5494,6 @@ paths:
54945494
summary: Reload proxy config
54955495
tags:
54965496
- Proxy
5497-
/api/ext/resources/scripts:
5498-
get:
5499-
operationId: get_api_ext_resources_scripts
5500-
responses:
5501-
"200":
5502-
content:
5503-
application/json:
5504-
schema:
5505-
$ref: '#/components/schemas/SuccessEnvelope'
5506-
description: OK
5507-
"401":
5508-
content:
5509-
application/json:
5510-
schema:
5511-
$ref: '#/components/schemas/ErrorEnvelope'
5512-
description: Unauthorized
5513-
security:
5514-
- bearerAuth: []
5515-
summary: Get resources scripts
5516-
tags:
5517-
- Resource
5518-
post:
5519-
operationId: post_api_ext_resources_scripts
5520-
requestBody:
5521-
content:
5522-
application/json:
5523-
schema:
5524-
$ref: '#/components/schemas/GenericRequest'
5525-
required: false
5526-
responses:
5527-
"200":
5528-
content:
5529-
application/json:
5530-
schema:
5531-
$ref: '#/components/schemas/SuccessEnvelope'
5532-
description: OK
5533-
"401":
5534-
content:
5535-
application/json:
5536-
schema:
5537-
$ref: '#/components/schemas/ErrorEnvelope'
5538-
description: Unauthorized
5539-
security:
5540-
- bearerAuth: []
5541-
summary: Create or execute resources scripts
5542-
tags:
5543-
- Resource
5544-
/api/ext/resources/scripts/{id}:
5545-
delete:
5546-
operationId: delete_api_ext_resources_scripts_id
5547-
parameters:
5548-
- in: path
5549-
name: id
5550-
required: true
5551-
schema:
5552-
type: string
5553-
responses:
5554-
"200":
5555-
content:
5556-
application/json:
5557-
schema:
5558-
$ref: '#/components/schemas/SuccessEnvelope'
5559-
description: OK
5560-
"401":
5561-
content:
5562-
application/json:
5563-
schema:
5564-
$ref: '#/components/schemas/ErrorEnvelope'
5565-
description: Unauthorized
5566-
security:
5567-
- bearerAuth: []
5568-
summary: Delete resources scripts by id
5569-
tags:
5570-
- Resource
5571-
get:
5572-
operationId: get_api_ext_resources_scripts_id
5573-
parameters:
5574-
- in: path
5575-
name: id
5576-
required: true
5577-
schema:
5578-
type: string
5579-
responses:
5580-
"200":
5581-
content:
5582-
application/json:
5583-
schema:
5584-
$ref: '#/components/schemas/SuccessEnvelope'
5585-
description: OK
5586-
"401":
5587-
content:
5588-
application/json:
5589-
schema:
5590-
$ref: '#/components/schemas/ErrorEnvelope'
5591-
description: Unauthorized
5592-
security:
5593-
- bearerAuth: []
5594-
summary: Get resources scripts by id
5595-
tags:
5596-
- Resource
5597-
put:
5598-
operationId: put_api_ext_resources_scripts_id
5599-
parameters:
5600-
- in: path
5601-
name: id
5602-
required: true
5603-
schema:
5604-
type: string
5605-
requestBody:
5606-
content:
5607-
application/json:
5608-
schema:
5609-
$ref: '#/components/schemas/GenericRequest'
5610-
required: false
5611-
responses:
5612-
"200":
5613-
content:
5614-
application/json:
5615-
schema:
5616-
$ref: '#/components/schemas/SuccessEnvelope'
5617-
description: OK
5618-
"401":
5619-
content:
5620-
application/json:
5621-
schema:
5622-
$ref: '#/components/schemas/ErrorEnvelope'
5623-
description: Unauthorized
5624-
security:
5625-
- bearerAuth: []
5626-
summary: Update resources scripts by id
5627-
tags:
5628-
- Resource
56295497
/api/ext/setup/init:
56305498
post:
56315499
operationId: post_api_ext_setup_init

backend/docs/openapi/ext-api.yaml

Lines changed: 2 additions & 129 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,6 @@ tags:
4747
description: "Reverse proxy domain management and SSL automation endpoints."
4848
- name: Releases
4949
description: "Release inventory and app-scoped release inspection APIs."
50-
- name: Resource
51-
description: "Generic resource-store collection APIs for scripts only."
5250
- name: Secrets
5351
description: "Secret storage, rotation, resolve, and reveal APIs."
5452
- name: Servers
@@ -245,6 +243,8 @@ components:
245243
type: string
246244
language:
247245
type: string
246+
script_extension:
247+
type: string
248248
reference:
249249
type: string
250250
path:
@@ -4054,133 +4054,6 @@ paths:
40544054
schema:
40554055
type: object
40564056
additionalProperties: true
4057-
/api/ext/resources/scripts:
4058-
get:
4059-
tags: [Resource]
4060-
summary: Get resources scripts
4061-
operationId: get_api_ext_resources_scripts
4062-
security:
4063-
- bearerAuth: [] # superuser required
4064-
responses:
4065-
"200":
4066-
description: OK
4067-
content:
4068-
application/json:
4069-
schema:
4070-
$ref: '#/components/schemas/SuccessEnvelope'
4071-
"401":
4072-
description: Unauthorized
4073-
content:
4074-
application/json:
4075-
schema:
4076-
$ref: '#/components/schemas/ErrorEnvelope'
4077-
post:
4078-
tags: [Resource]
4079-
summary: Create or execute resources scripts
4080-
operationId: post_api_ext_resources_scripts
4081-
requestBody:
4082-
required: false
4083-
content:
4084-
application/json:
4085-
schema:
4086-
$ref: '#/components/schemas/GenericRequest'
4087-
security:
4088-
- bearerAuth: [] # superuser required
4089-
responses:
4090-
"200":
4091-
description: OK
4092-
content:
4093-
application/json:
4094-
schema:
4095-
$ref: '#/components/schemas/SuccessEnvelope'
4096-
"401":
4097-
description: Unauthorized
4098-
content:
4099-
application/json:
4100-
schema:
4101-
$ref: '#/components/schemas/ErrorEnvelope'
4102-
/api/ext/resources/scripts/{id}:
4103-
delete:
4104-
tags: [Resource]
4105-
summary: Delete resources scripts by id
4106-
operationId: delete_api_ext_resources_scripts_id
4107-
parameters:
4108-
- name: id
4109-
in: path
4110-
required: true
4111-
schema:
4112-
type: string
4113-
security:
4114-
- bearerAuth: [] # superuser required
4115-
responses:
4116-
"200":
4117-
description: OK
4118-
content:
4119-
application/json:
4120-
schema:
4121-
$ref: '#/components/schemas/SuccessEnvelope'
4122-
"401":
4123-
description: Unauthorized
4124-
content:
4125-
application/json:
4126-
schema:
4127-
$ref: '#/components/schemas/ErrorEnvelope'
4128-
get:
4129-
tags: [Resource]
4130-
summary: Get resources scripts by id
4131-
operationId: get_api_ext_resources_scripts_id
4132-
parameters:
4133-
- name: id
4134-
in: path
4135-
required: true
4136-
schema:
4137-
type: string
4138-
security:
4139-
- bearerAuth: [] # superuser required
4140-
responses:
4141-
"200":
4142-
description: OK
4143-
content:
4144-
application/json:
4145-
schema:
4146-
$ref: '#/components/schemas/SuccessEnvelope'
4147-
"401":
4148-
description: Unauthorized
4149-
content:
4150-
application/json:
4151-
schema:
4152-
$ref: '#/components/schemas/ErrorEnvelope'
4153-
put:
4154-
tags: [Resource]
4155-
summary: Update resources scripts by id
4156-
operationId: put_api_ext_resources_scripts_id
4157-
parameters:
4158-
- name: id
4159-
in: path
4160-
required: true
4161-
schema:
4162-
type: string
4163-
requestBody:
4164-
required: false
4165-
content:
4166-
application/json:
4167-
schema:
4168-
$ref: '#/components/schemas/GenericRequest'
4169-
security:
4170-
- bearerAuth: [] # superuser required
4171-
responses:
4172-
"200":
4173-
description: OK
4174-
content:
4175-
application/json:
4176-
schema:
4177-
$ref: '#/components/schemas/SuccessEnvelope'
4178-
"401":
4179-
description: Unauthorized
4180-
content:
4181-
application/json:
4182-
schema:
4183-
$ref: '#/components/schemas/ErrorEnvelope'
41844057
/api/ext/setup/init:
41854058
post:
41864059
tags: [Setup]

backend/docs/openapi/group-matrix.yaml

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -360,17 +360,6 @@ groups:
360360
- instances.go
361361
nativeRefs: []
362362

363-
- group: Resource
364-
description: Generic resource-store collection APIs for scripts only.
365-
apiType: Ext
366-
extSurface:
367-
- /api/ext/resources/scripts*
368-
nativeSurface: []
369-
sources:
370-
extRouteFiles:
371-
- resources.go
372-
nativeRefs: []
373-
374363
- group: Groups
375364
description: Group registry and group-item membership CRUD via PocketBase native records API.
376365
note: Native endpoints are tracked here; runtime OpenAPI merge still depends on native-api.yaml maintenance.

0 commit comments

Comments
 (0)