Refactor: Use @simpleworkjs/conf for configuration

- Replace ENV vars with proper config system
- Add conf/ directory with base, development, production, secrets
- Add secrets.example.js template
- Update .gitignore for secrets.js
- Show environment in startup banner
This commit is contained in:
2026-02-25 03:22:33 +00:00
parent 56933f59d1
commit 748636591b
8 changed files with 153 additions and 37 deletions

19
package-lock.json generated
View File

@@ -8,6 +8,7 @@
"name": "openclaw-webui",
"version": "1.0.0",
"dependencies": {
"@simpleworkjs/conf": "^1.0.0",
"eventsource": "^2.0.2",
"express": "^4.18.2",
"express-session": "^1.17.3",
@@ -870,6 +871,18 @@
"win32"
]
},
"node_modules/@simpleworkjs/conf": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/@simpleworkjs/conf/-/conf-1.0.0.tgz",
"integrity": "sha512-p1dQAELW0oUBRpDoz260TYw18IMI/Y11xYAb17P1MEPjsTAUB0LWE/6ZeA2VQmpU/LXoRnDysg0G/oASGILyUA==",
"license": "MIT",
"dependencies": {
"extend": "^3.0.2"
},
"engines": {
"node": ">=16.0.0"
}
},
"node_modules/@types/estree": {
"version": "1.0.8",
"resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.8.tgz",
@@ -1435,6 +1448,12 @@
"url": "https://opencollective.com/express"
}
},
"node_modules/extend": {
"version": "3.0.2",
"resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz",
"integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==",
"license": "MIT"
},
"node_modules/extsprintf": {
"version": "1.4.1",
"resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.4.1.tgz",