Skip to content

Fix/container build linux#56

Merged
asieduernest12 merged 27 commits intodamoahdominic:mainfrom
asieduernest12:fix/container-build-linux
Mar 30, 2026
Merged

Fix/container build linux#56
asieduernest12 merged 27 commits intodamoahdominic:mainfrom
asieduernest12:fix/container-build-linux

Conversation

@asieduernest12
Copy link
Copy Markdown
Collaborator

No description provided.

asieduernest12 and others added 27 commits March 30, 2026 07:53
…me.ts

- Add panel-bootstrap-choice: two-card setup choice (Docker Recommended / Local Advanced)
- Add panel-docker-path: configurable data directory with ~/Desktop/occ shortcut note
- Add panel-docker-doctor: live dependency checklist (OS, docker/podman, daemon, port, compose)
- Add panel-docker-provision: streaming log panel for docker compose up -d
- Add detectDockerEnvironment(): platform-aware check for docker/podman + daemon + port + compose
- Add runDockerProvision(): pulls images, runs compose up, polls /health, writes openclaw.json
- Add runDockerTeardown(): docker compose down for cancel/reset flows
- Add createDesktopShortcut(): symlink ~/Desktop/occ → data dir (win: .lnk via PowerShell)
- Add getDefaultOpenClawDataPath(): ~/.openclaw (mac/linux) or %APPDATA%\openclaw (win)
- Wire dockerGetDefaultPath, dockerRunDoctor, dockerProvision, dockerCancel message handlers

Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
…op/occ/.openclaw)

- getDefaultOpenClawDataPath() now returns ~/Desktop/occ/.openclaw on all platforms
  instead of platform-specific ~/.openclaw / %APPDATA%\openclaw
- HTML path input placeholder updated to ~/Desktop/occ/.openclaw
- docker-compose.full.yml: remove ~ fallback (extension always writes .env with expanded path)
- createDesktopShortcut(): skip symlink creation when dataPath is already inside
  ~/Desktop/occ/ (data is co-located, no symlink needed); fix lstat race on missing dir

Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
- Create docker-compose.test.yml with isolated test services (fnm, nvm, node-only, node-setup)
- Add system dependency packages (build-essential, libxkbfile-dev) to Dockerfiles for native module compilation
- Implement comprehensive test script (test-node-version-detection.sh) for all Node.js runtime scenarios
- Add Makefile targets for docker-compose based testing
- Add helper scripts: node-version.sh (shared version detection logic), activate_env.sh, help.awk
- Support for fnm, nvm, system node, and auto-install scenarios with proper environment setup
- All 4 test scenarios now pass successfully
- Remove invalid extends reference in main docker-compose.yml
- Fix docker-compose.test.yml volumes/networks section ordering
- Add explicit npm install for editor dependencies in main compose file
- Test services now use proper isolated volumes and networks
- Build test images from custom Dockerfiles with all required dependencies
- Add .dockerignore to reduce build context size (exclude node_modules, .git, etc.)
- Each service now builds from its corresponding Dockerfile with proper environment
- Comprehensive guide for Docker Compose test and dev environments
- Usage examples for running tests and development
- Troubleshooting section for common issues
- Reference for all Makefile targets and scripts
- Use build config instead of image name to avoid pull conflicts
- Change entrypoint to 'sh' (Alpine has no bash)
- Use proper shell command syntax for multi-line npm script
- Map port to 3001 (3000 was blocked by other services)
- Container now starts and runs npm ci + dev server
- Both docker-compose.yml and docker-compose.test.yml fully functional
- Development environment running on port 3001
- All test scenarios available and documented
- Complete troubleshooting guide included
- New web service for Next.js marketing site (apps/web)
- Runs on port 3002 with env var NEXT_PUBLIC_API_URL
- Separate node_modules volumes to avoid conflicts
- Depends on editor service
- Both services now run in dev-network together
- Service endpoints: editor:3001, web:3002
- Both services now extend test-nvm service from docker-compose.test.yml
- Inherits proper NVM setup with Node version management
- Fixes node engine compatibility issues (requires Node 20+)
- Includes all system dependencies (python3, build tools, libxkbfile-dev)
- Added test-network and node_modules_nvm volume to main compose
- Services properly source NVM scripts before npm operations
- Both editor and web services now running successfully on 3001 and 3002
Dockerfile.build-linux replicates the CI build-linux job environment
(Ubuntu 22.04, Node 20.18.2, system deps including xz-utils).

Makefile targets:
- build-linux-container: builds the Docker image
- build-linux: runs the full editor build pipeline inside the container
  producing a packaged app (apps/VSCode-linux-x64/) and .deb package
  (apps/editor/.build/linux/deb/).
Rename build-linux to container-build-linux, extract its inline bash
build steps into a standalone build-linux target usable both locally
and inside the container via make PROJECT_ROOT=...
Replace manual docker create/start/cp/rm with docker compose run
--rm --entrypoint make. Volume mounts handle artifact output directly,
eliminating the docker cp step.
Collapse 14 individual build steps + system deps install into a single
make container-build-linux call. The container handles all dependencies.
Extract the 13 shared compilation steps into a build-core Makefile
target. build-linux and build-windows now call build-core after their
platform-specific electron/rebuild, then do packaging.

Update Windows CI job to use make build-windows, keeping Azure Trusted
Signing and artifact steps as CI-only.
build-core now handles everything: cd, NODE_OPTIONS, electron/rebuild
(via ELECTRON_ARCH variable), npm ci, tsc, extensions, React, bundle,
minify, download Electron.

build-linux and build-windows are now packaging-only wrappers with no
duplicated setup code.
Avoid 401 errors from @vscode/ripgrep by adding --ignore-scripts
to the build dependencies npm ci command. Also add ripgrep
install and GitHub token config to Dockerfile.build-linux.
Update build-macos and build-macos-x64 jobs to use make build-macos-arm64
and make build-macos-x64 respectively, following the same pattern as Linux
and Windows builds. Add corresponding Makefile targets for macOS builds.
…sion from version.txt

Replace hardcoded VS Code descriptions, URLs, and maintainer info in
deb, rpm, snap, appdata, and desktop templates with placeholders sourced
from product.json. Version now reads from the repo-root version.txt
instead of the upstream package.json.
@asieduernest12 asieduernest12 merged commit 87a9f66 into damoahdominic:main Mar 30, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant