diff --git a/agent/utils/env/env.go b/agent/utils/env/env.go index 630511618..22dd430a5 100644 --- a/agent/utils/env/env.go +++ b/agent/utils/env/env.go @@ -10,7 +10,7 @@ import ( ) func Write(envMap map[string]string, filename string) error { - content, err := Marshal(envMap) + content, err := marshal(envMap) if err != nil { return err } @@ -26,10 +26,10 @@ func Write(envMap map[string]string, filename string) error { return file.Sync() } -func Marshal(envMap map[string]string) (string, error) { +func marshal(envMap map[string]string) (string, error) { lines := make([]string, 0, len(envMap)) for k, v := range envMap { - if d, err := strconv.Atoi(v); err == nil { + if d, err := strconv.Atoi(v); err == nil && !isStartWithZero(v) { lines = append(lines, fmt.Sprintf(`%s=%d`, k, d)) } else { lines = append(lines, fmt.Sprintf(`%s="%s"`, k, v)) @@ -50,3 +50,10 @@ func GetEnvValueByKey(envPath, key string) (string, error) { } return value, nil } + +func isStartWithZero(value string) bool { + if strings.HasPrefix(value, "0") && len(value) > 1 { + return true + } + return false +} diff --git a/frontend/src/components/complex-table/index.vue b/frontend/src/components/complex-table/index.vue index 7026ec2ad..9f10ae52f 100644 --- a/frontend/src/components/complex-table/index.vue +++ b/frontend/src/components/complex-table/index.vue @@ -51,7 +51,7 @@ const props = defineProps({ }, heightDiff: { type: Number, - default: 0, + default: 320, }, height: { type: Number, diff --git a/frontend/src/lang/modules/en.ts b/frontend/src/lang/modules/en.ts index 00a99f2dd..798d988c3 100644 --- a/frontend/src/lang/modules/en.ts +++ b/frontend/src/lang/modules/en.ts @@ -2094,7 +2094,8 @@ const message = { ignoreAll: 'Ignore all subsequent versions', ignoreVersion: 'Ignore specified version', specifyIP: 'Bind Host IP', - specifyIPHelper: 'Set the host address to bind the port, usually the local machine IP', + specifyIPHelper: + 'Set the host address/network interface to bind the port (if you are not sure about this, please do not fill it in)', }, website: { primaryDomain: 'Primary Domain', diff --git a/frontend/src/lang/modules/ja.ts b/frontend/src/lang/modules/ja.ts index 293edd159..4ea61bf9f 100644 --- a/frontend/src/lang/modules/ja.ts +++ b/frontend/src/lang/modules/ja.ts @@ -1997,7 +1997,8 @@ const message = { ignoreAll: '後続のすべてのバージョンを無視', ignoreVersion: '指定されたバージョンを無視', specifyIP: 'ホスト IP をバインド', - specifyIPHelper: 'ポートにバインドするホストアドレスを設定します、通常はローカルマシンの IP です', + specifyIPHelper: + 'ポートにバインドするホストアドレス/ネットワークインターフェースを設定します(この機能がわからない場合は、入力しないでください)', }, website: { primaryDomain: 'プライマリドメイン', diff --git a/frontend/src/lang/modules/ko.ts b/frontend/src/lang/modules/ko.ts index a41793de8..26dd63c99 100644 --- a/frontend/src/lang/modules/ko.ts +++ b/frontend/src/lang/modules/ko.ts @@ -1965,7 +1965,8 @@ const message = { ignoreAll: '후속 모든 버전 무시', ignoreVersion: '지정된 버전 무시', specifyIP: '호스트 IP 바인딩', - specifyIPHelper: '포트 바인딩을 위한 호스트 주소를 설정합니다. 일반적으로 로컬 머신의 IP입니다', + specifyIPHelper: + '포트 바인딩을 위한 호스트 주소/네트워크 인터페이스를 설정합니다 (이 기능을 잘 모를 경우, 입력하지 마십시오)', }, website: { primaryDomain: '기본 도메인', diff --git a/frontend/src/lang/modules/ms.ts b/frontend/src/lang/modules/ms.ts index 2c83d1655..a9b8ae026 100644 --- a/frontend/src/lang/modules/ms.ts +++ b/frontend/src/lang/modules/ms.ts @@ -2051,7 +2051,8 @@ const message = { ignoreAll: 'Abaikan semua versi berikutnya', ignoreVersion: 'Abaikan versi yang ditentukan', specifyIP: 'Bind IP Hos', - specifyIPHelper: 'Tetapkan alamat hos untuk mengikat port, biasanya IP mesin tempatan', + specifyIPHelper: + 'Tetapkan alamat hos/antara muka rangkaian untuk mengikat port (jika anda tidak pasti mengenai ini, jangan isi)', }, website: { primaryDomain: 'Domain Utama', diff --git a/frontend/src/lang/modules/pt-br.ts b/frontend/src/lang/modules/pt-br.ts index 69ccdbe00..0434f1ee7 100644 --- a/frontend/src/lang/modules/pt-br.ts +++ b/frontend/src/lang/modules/pt-br.ts @@ -2043,7 +2043,8 @@ const message = { ignoreAll: 'Ignorar todas as versões subsequentes', ignoreVersion: 'Ignorar versão especificada', specifyIP: 'Vincular IP do Host', - specifyIPHelper: 'Defina o endereço do host para vincular a porta, geralmente o IP da máquina local', + specifyIPHelper: + 'Defina o endereço do host/interface de rede para vincular a porta (se você não tiver certeza sobre isso, por favor, não preencha)', }, website: { primaryDomain: 'Domínio principal', diff --git a/frontend/src/lang/modules/ru.ts b/frontend/src/lang/modules/ru.ts index c11f55f1a..fa00c191f 100644 --- a/frontend/src/lang/modules/ru.ts +++ b/frontend/src/lang/modules/ru.ts @@ -2043,7 +2043,8 @@ const message = { ignoreAll: 'Игнорировать все последующие версии', ignoreVersion: 'Игнорировать указанную версию', specifyIP: 'Привязать IP хоста', - specifyIPHelper: 'Установите адрес хоста для привязки порта, обычно IP локального компьютера', + specifyIPHelper: + 'Установите адрес хоста/сетевого интерфейса для привязки порта (если вы не уверены в этом, пожалуйста, не заполняйте)', }, website: { primaryDomain: 'Основной домен', diff --git a/frontend/src/lang/modules/zh-Hant.ts b/frontend/src/lang/modules/zh-Hant.ts index 90834ba30..7a97a19ec 100644 --- a/frontend/src/lang/modules/zh-Hant.ts +++ b/frontend/src/lang/modules/zh-Hant.ts @@ -1939,7 +1939,7 @@ const message = { ignoreAll: '忽略後續所有版本', ignoreVersion: '忽略指定版本', specifyIP: '綁定主機 IP', - specifyIPHelper: '設置端口綁定的主機地址,一般為本機 IP', + specifyIPHelper: '設置端口綁定的主機地址/網卡(如果你不清楚這個的作用,請不要填寫)', }, website: { primaryDomain: '主域名', diff --git a/frontend/src/lang/modules/zh.ts b/frontend/src/lang/modules/zh.ts index cd521898f..2ff47661a 100644 --- a/frontend/src/lang/modules/zh.ts +++ b/frontend/src/lang/modules/zh.ts @@ -1929,7 +1929,7 @@ const message = { ignoreAll: '忽略后续所有版本', ignoreVersion: '忽略指定版本', specifyIP: '绑定主机 IP', - specifyIPHelper: '设置端口绑定的主机地址,一般为本机 IP', + specifyIPHelper: '设置端口绑定的主机地址/网卡(如果你不清楚这个的作用,请不要填写)', }, website: { primaryDomain: '主域名',