Skip to content

Commit 2aeddf6

Browse files
Merge branch 'main' into copilot/releaseghcr-debian-cross
Signed-off-by: Brian Horakh <[email protected]>
2 parents 8e678d6 + 9eb42c1 commit 2aeddf6

File tree

3 files changed

+271
-181
lines changed

3 files changed

+271
-181
lines changed

.pr-summary.md

Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,100 @@
1+
# PR Summary: Debian-based Docker and CI/CD Workflows
2+
3+
**IMPORTANT: Branch Note**
4+
The changes have been implemented on the `release/ghcr-debian-cross` branch locally. Due to workspace automation constraints, the identical changes have also been pushed to `origin/copilot/update-dockerfile-to-debian-slim`.
5+
6+
To create the PR from the correct branch name (`release/ghcr-debian-cross`), you can:
7+
1. Manually push the local `release/ghcr-debian-cross` branch: `git push -u origin release/ghcr-debian-cross`
8+
2. Then create a PR from `release/ghcr-debian-cross` to `main`
9+
10+
Alternatively, you can rename the existing `copilot/update-dockerfile-to-debian-slim` branch to `release/ghcr-debian-cross` on GitHub.
11+
12+
This branch contains comprehensive updates to the Docker configuration and CI/CD workflows for the rust-cargo-docs-rag-mcp project.
13+
14+
## Changes Made
15+
16+
### 1. Dockerfile - Debian Migration
17+
- **Changed**: Migrated from Alpine to Debian slim (bullseye)
18+
- **Why**: Better compatibility with Rust dependencies and OpenSSL
19+
- **Details**: Multi-stage build preserved, uses `rust:1.91.1-slim-bullseye` for builder and `debian:bullseye-slim` for runtime
20+
21+
### 2. docker/entrypoint.sh - Enhanced Wrapper
22+
- **Changed**: Improved entrypoint script with case statement
23+
- **Features**:
24+
- Support for http and stdio modes
25+
- Debug mode flag handling
26+
- Pass-through support for custom arguments
27+
- Better error messages for unknown modes
28+
29+
### 3. .github/workflows/ci.yml - Build & Test Workflow
30+
- **New**: CI workflow for continuous integration
31+
- **Triggers**: On push to main and pull requests to main
32+
- **Steps**:
33+
- Checkout code
34+
- Cache cargo dependencies
35+
- Install Rust 1.91.1 toolchain
36+
- Build release binary
37+
- Run all tests
38+
39+
### 4. .github/workflows/release-and-publish.yml - Release Workflow
40+
- **New**: Comprehensive release automation
41+
- **Triggers**: On push of tags matching `v*` or manual dispatch
42+
- **Capabilities**:
43+
- Multi-architecture Docker builds (amd64, arm64)
44+
- Push to GitHub Container Registry (GHCR)
45+
- Create GitHub releases
46+
- Cross-compile binaries for x86_64 and aarch64 Linux
47+
- Upload binaries as release assets
48+
49+
### 5. scripts/set-version.sh - Portability Improvement
50+
- **Changed**: Rewritten from Python to pure shell
51+
- **Benefits**:
52+
- No Python dependency required
53+
- Falls back to sed if perl is not available
54+
- More portable across different environments
55+
- Idempotent and safe
56+
57+
### 6. README.md - Comprehensive Documentation
58+
- **Changed**: Complete rewrite of README
59+
- **New sections**:
60+
- Release/versioning workflow with Cocogitto
61+
- Docker installation and usage (GHCR)
62+
- Environment variables documentation
63+
- pkgx and Cargo installation methods
64+
- All available MCP tools with examples
65+
- Testing tools directly without server
66+
- MCP protocol integration examples
67+
68+
## Validation Performed
69+
70+
✅ YAML syntax validated for all workflows
71+
✅ Shell script syntax validated for entrypoint.sh and set-version.sh
72+
✅ Dockerfile validated with hadolint (minor warnings about best practices)
73+
✅ CodeQL security scan completed with no issues
74+
✅ Build system validated (cargo build succeeds)
75+
✅ Test suite runs (some pre-existing failures unrelated to these changes)
76+
77+
## Files Modified
78+
79+
```
80+
A .github/workflows/ci.yml
81+
A .github/workflows/release-and-publish.yml
82+
M Dockerfile
83+
M README.md
84+
M docker/entrypoint.sh
85+
M scripts/set-version.sh
86+
```
87+
88+
## Next Steps
89+
90+
1. Review and approve this PR
91+
2. Merge to main
92+
3. Tag a release (e.g., `v0.4.0`) to trigger the release workflow
93+
4. Verify Docker images are published to GHCR
94+
5. Verify binaries are attached to the GitHub release
95+
96+
## Notes
97+
98+
- The `production` environment referenced in the release workflow may need to be configured in GitHub repository settings
99+
- Ensure GitHub Actions has permission to publish packages (Settings → Actions → General → Workflow permissions → Read and write permissions)
100+
- The release workflow requires the `GITHUB_TOKEN` which is automatically provided by GitHub Actions

0 commit comments

Comments
 (0)