add miner commit example with Docker support and FastAPI integr…#2
Open
abdibekbolot wants to merge 1 commit intomainfrom
Open
add miner commit example with Docker support and FastAPI integr…#2abdibekbolot wants to merge 1 commit intomainfrom
abdibekbolot wants to merge 1 commit intomainfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a new “miner commit” example service and supporting FastAPI + Docker assets, and wires it into the dev docker-compose override so it can be run locally as a containerized API.
Changes:
- Added
miner-commit-apiservice to the dev compose override, including build context, volumes, ports, and uvicorn command. - Introduced a new
examples/miner_commitFastAPI app that serves a fingerprinter script, plus Dockerfile/compose/scripts/docs for running it. - Added basic JS fingerprinter source and Pydantic models for request/response typing.
Reviewed changes
Copilot reviewed 1 out of 11 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| templates/compose/compose.override.dev.yml | Adds miner-commit-api service definition for dev compose. |
| examples/miner_commit/src/fingerprinter/fingerprinter.js | Adds browser-side fingerprinter script used by the example. |
| examples/miner_commit/src/data_types.py | Adds Pydantic request/response models for the example API. |
| examples/miner_commit/src/app.py | Adds FastAPI app with /health and /solve endpoints. |
| examples/miner_commit/scripts/start.sh | Adds helper script to start the example via docker compose. |
| examples/miner_commit/scripts/build.sh | Adds helper script to build the example image. |
| examples/miner_commit/requirements.txt | Adds Python dependencies for the example app. |
| examples/miner_commit/compose.yml | Adds standalone compose definition to run the example service. |
| examples/miner_commit/README.md | Adds setup/run/build documentation for the example. |
| examples/miner_commit/Dockerfile | Adds container build instructions for the example app. |
| examples/miner_commit/.dockerignore | Adds dockerignore to reduce build context and avoid copying local artifacts. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
| # timeout: 5s | ||
| # retries: 3 | ||
| miner-commit-api: | ||
| image: myhub/rest-myc-commit:latest |
| volumes: | ||
| - "./examples/miner_commit/src:/app" | ||
| ports: | ||
| - ${MYC_MINER_COMMIT_API_PORT:-10002}:${MYC_MINER_COMMIT_API_PORT:-10002} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request adds a new service definition to the development Docker Compose override configuration. The new service,
miner-commit-api, is set up to run a REST API for commit operations using a containerized FastAPI application.Docker Compose service addition:
miner-commit-apiservice tocompose.override.dev.yml, including image, build context, environment variables, volume mapping for source code, port configuration, and a command to run the FastAPI app with live reload.…ation