Generates default.vrd, configures httpd.conf and starts Apache HTTP Server for web access to the information base. Downloads portable Apache if necessary. Idempotent — a repeated call updates the configuration.
Usage
/web-publish [database]
/web-publish dev
/web-publish dev --manual
/web-publish dev --port 9090
Connection parameters
Read .v8-project.json from the project root and resolve the base:
- If the user specified connection parameters (path, server) — use them directly
- If they specified the base by name — search by id / alias / name in
.v8-project.json - If they did not specify — match the current Git branch with
databases[].branches - If the branch did not match — use
default
ALWAYS pass all found parameters:
-V8Path—v8pathof the found base record, otherwise the rootv8path. Not set in either place — do not pass it, but then the platform version will be selected automatically and may turn out to be the wrong one-UserName— from the fielduserof the found base record (if present)-Password— from the fieldpasswordof the found base record (if present)-ApachePath— fromwebPathв.v8-project.json(if present)
If the file .v8-project.json is absent — suggest /db-list add.
Command
powershell.exe -NoProfile -File "${CLAUDE_SKILL_DIR}/scripts/web-publish.ps1" <параметры>
Script parameters
| Parameter | Required | Description |
|---|---|---|
-V8Path <путь> |
no | Platform bin directory (for wsap24.dll) |
-InfoBasePath <путь> |
* | File base |
-InfoBaseServer <сервер> |
* | 1C server (for a server base) |
-InfoBaseRef <имя> |
* | Base name on the server |
-UserName <имя> |
no | User name |
-Password <пароль> |
no | Password |
-AppName <имя> |
no | Publication name (by default from the base directory name) |
-ApachePath <путь> |
no | Apache root (by default tools/apache24) |
-Port <порт> |
no | Port (by default 8081) |
-Manual |
no | Do not download — only check and provide instructions |
*— either-InfoBasePathis required, or the pair-InfoBaseServer+-InfoBaseRef
Multiple users of one base
Repeated call with the same AppName replaces the publication (idempotency). This is used for:
- changing the user: "publish under Ivanov" → same AppName, new
-UserName - restart after
/web-stop: the same call brings Apache back up
If the user asks for parallel publication under a different user (to test different permission sets), add a suffix to AppName:
- base
bpdemo, userИванов→-AppName bpdemo-ivanov - base
bpdemo, userAdmin→-AppName bpdemo-admin(or simplybpdemo)
Keywords: "one more publication", "additionally", "in parallel", "under a different user without removing the current one".
After execution
- Report the URLs:
- Web client:
http://localhost:{Port}/{AppName} - OData:
http://localhost:{Port}/{AppName}/odata/standard.odata - HTTP services:
http://localhost:{Port}/{AppName}/hs/<RootUrl>/... - Web services:
http://localhost:{Port}/{AppName}/ws/<Имя>?wsdl
- Web client:
- Suggest opening in the browser
- If you need to test the service — help compose a request
- If the base is not registered — suggest
/db-list add
Extension services are published on par with configuration services. If an extension service still
returns 404 (HTTP) or 500 "Service not found" (SOAP) — the extension is not applied to the database:
/db-update -Extension <имя>.
Examples
# Файловая база
powershell.exe -NoProfile -File "${CLAUDE_SKILL_DIR}/scripts/web-publish.ps1" -InfoBasePath "C:\Bases\MyDB" -UserName "Admin"
# С явным именем публикации и портом
powershell.exe -NoProfile -File "${CLAUDE_SKILL_DIR}/scripts/web-publish.ps1" -InfoBasePath "C:\Bases\MyDB" -AppName "mydb" -Port 9090
# Серверная база
powershell.exe -NoProfile -File "${CLAUDE_SKILL_DIR}/scripts/web-publish.ps1" -InfoBaseServer "srv01" -InfoBaseRef "MyDB" -UserName "Admin" -Password "secret"
# Ручной режим (только инструкция)
powershell.exe -NoProfile -File "${CLAUDE_SKILL_DIR}/scripts/web-publish.ps1" -InfoBasePath "C:\Bases\MyDB" -Manual