Исправления в ветке main

This commit is contained in:
2025-10-28 14:33:40 +06:00
parent 5b78e775c1
commit 3c95eb85db
9 changed files with 23 additions and 11 deletions

View File

@@ -1 +1 @@
v2.0.5 v2.0.6

View File

@@ -68,6 +68,15 @@ type ValidationConfig struct {
MaxExplanationLength int MaxExplanationLength int
} }
func GetEnvBool(key string, defaultValue bool) bool {
if value, exists := os.LookupEnv(key); exists {
if boolValue, err := strconv.ParseBool(value); err == nil {
return boolValue
}
}
return defaultValue
}
func getEnv(key, defaultValue string) string { func getEnv(key, defaultValue string) string {
if value, exists := os.LookupEnv(key); exists { if value, exists := os.LookupEnv(key); exists {
return value return value

View File

@@ -1 +1 @@
v2.0.5 v2.0.6

View File

@@ -5,7 +5,7 @@ metadata:
namespace: lcg namespace: lcg
data: data:
# Основные настройки # Основные настройки
LCG_VERSION: "v2.0.5" LCG_VERSION: "v2.0.6"
LCG_BASE_PATH: "/lcg" LCG_BASE_PATH: "/lcg"
LCG_SERVER_HOST: "0.0.0.0" LCG_SERVER_HOST: "0.0.0.0"
LCG_SERVER_PORT: "8080" LCG_SERVER_PORT: "8080"

View File

@@ -5,7 +5,7 @@ metadata:
namespace: lcg namespace: lcg
labels: labels:
app: lcg app: lcg
version: v2.0.5 version: v2.0.6
spec: spec:
replicas: 1 replicas: 1
selector: selector:
@@ -15,11 +15,11 @@ spec:
metadata: metadata:
labels: labels:
app: lcg app: lcg
version: v2.0.5 version: v2.0.6
spec: spec:
containers: containers:
- name: lcg - name: lcg
image: kuznetcovay/lcg:v2.0.5 image: kuznetcovay/lcg:v2.0.6
imagePullPolicy: Always imagePullPolicy: Always
ports: ports:
- containerPort: 8080 - containerPort: 8080

View File

@@ -5,7 +5,7 @@ metadata:
namespace: lcg namespace: lcg
labels: labels:
app: lcg app: lcg
version: v2.0.5 version: v2.0.6
spec: spec:
entryPoints: entryPoints:
- websecure - websecure

View File

@@ -15,11 +15,11 @@ resources:
# Common labels # Common labels
commonLabels: commonLabels:
app: lcg app: lcg
version: v2.0.5 version: v2.0.6
managed-by: kustomize managed-by: kustomize
# Images # Images
images: images:
- name: lcg - name: lcg
newName: kuznetcovay/lcg newName: kuznetcovay/lcg
newTag: v2.0.5 newTag: v2.0.6

View File

@@ -5,7 +5,7 @@ metadata:
namespace: lcg namespace: lcg
labels: labels:
app: lcg app: lcg
version: v2.0.5 version: v2.0.6
spec: spec:
type: ClusterIP type: ClusterIP
ports: ports:
@@ -15,4 +15,4 @@ spec:
name: http name: http
selector: selector:
app: lcg app: lcg
version: v2.0.5 version: v2.0.6

View File

@@ -156,6 +156,9 @@ lcg [опции] <описание команды>
Debug: c.Bool("debug"), Debug: c.Bool("debug"),
} }
disableHistory = config.AppConfig.MainFlags.NoHistory || config.AppConfig.IsNoHistoryEnabled() disableHistory = config.AppConfig.MainFlags.NoHistory || config.AppConfig.IsNoHistoryEnabled()
config.AppConfig.MainFlags.Debug = config.AppConfig.MainFlags.Debug || config.GetEnvBool("LCG_DEBUG", false)
args := c.Args().Slice() args := c.Args().Slice()
if len(args) == 0 { if len(args) == 0 {