使用其他端口号,避免端口占用

This commit is contained in:
Krcia 2025-12-03 10:45:54 +08:00
parent 6d49237a52
commit c68aa6fc8f
6 changed files with 27 additions and 55 deletions

View File

@ -1,11 +1,11 @@
{ {
".url": { ".url": {
"certimate.Application": { "Certimate.Application": {
"title": "Certimate", "title": "Certimate",
"icon": "images/icon_{0}.png", "icon": "images/icon_{0}.png",
"protocol": "http", "protocol": "http",
"type": "iframe", "type": "iframe",
"port": "8090", "port": "8091",
"url": "/", "url": "/",
"allUsers": false "allUsers": false
} }

View File

@ -7,18 +7,13 @@ CREATE_CMD="${TRIM_APPDEST}/certimate superuser add ${cer_user} ${cer_pwd}"
echo "正在创建新的管理员账户..." echo "正在创建新的管理员账户..."
$DELETE_CMD $DELETE_CMD
if [ $? -eq 0 ]; then
echo "新管理员创建成功"
else
echo "错误:创建新管理员失败"
exit 1 # 如果创建失败,退出并返回错误码
fi
$CREATE_CMD $CREATE_CMD
if [ $? -eq 0 ]; then if [ $? -eq 0 ]; then
echo "新管理员创建成功" echo "新管理员创建成功"
else else
echo "错误:创建新管理员失败" echo "错误:创建新管理员失败"
exit 1 # 如果创建失败,退出并返回错误码 exit 1
fi fi
exit 0 exit 0

View File

@ -4,7 +4,7 @@ LOG_FILE="${TRIM_PKGVAR}/info.log"
PID_FILE="${TRIM_PKGVAR}/app.pid" PID_FILE="${TRIM_PKGVAR}/app.pid"
# write the command to start your program here # write the command to start your program here
CMD="${TRIM_APPDEST}/certimate -serve ${server_address}:8090 --dir ./pb_data" CMD="${TRIM_APPDEST}/certimate serve --http ${server_address}:8091 --dir ${TRIM_APPDEST}/pb_data"
log_msg() { log_msg() {
echo "$(date '+%Y-%m-%d %H:%M:%S') - $1" >> ${LOG_FILE} echo "$(date '+%Y-%m-%d %H:%M:%S') - $1" >> ${LOG_FILE}

View File

@ -1,28 +1,2 @@
{ {
"data-share":
{
"shares":
[
{
"name": "certimate",
"permission":
{
"rw":
[
"certimate"
]
}
},
{
"name": "certimate/data",
"permission":
{
"rw":
[
"certimate"
]
}
}
]
}
} }

View File

@ -7,4 +7,4 @@ source = thirdparty
maintainer = certimate maintainer = certimate
distributor = Krcia distributor = Krcia
desktop_uidir = ui desktop_uidir = ui
desktop_applaunchname = certimate.Application desktop_applaunchname = Certimate.Application

View File

@ -6,7 +6,6 @@
"type": "text", "type": "text",
"field": "cer_user", "field": "cer_user",
"label": "邮箱", "label": "邮箱",
"initValue": "admin",
"rules": [ "rules": [
{ {
"required": true, "required": true,
@ -48,24 +47,28 @@
}, },
{ {
"stepTitle": "请选择访问范围", "stepTitle": "请选择访问范围",
"type": "select", "items": [
"field": "server_address",
"label": "访问范围",
"initValue": "127.0.0.1",
"options": [
{ {
"label": "127.0.0.1", "type": "select",
"value": "127.0.0.1" "field": "server_address",
}, "label": "访问范围",
{ "initValue": "127.0.0.1",
"label": "0.0.0.0", "options": [
"value": "0.0.0.0" {
} "label": "127.0.0.1",
], "value": "127.0.0.1"
"rules": [ },
{ {
"required": true, "label": "0.0.0.0",
"message": "请选择访问范围" "value": "0.0.0.0"
}
],
"rules": [
{
"required": true,
"message": "请选择访问范围"
}
]
} }
] ]
} }