autolab / Tango

Standalone RESTful autograding service
http://www.autolabproject.com/
Apache License 2.0
48 stars 60 forks source link

Add endpoint for uploading docker image #232

Closed evanyeyeye closed 9 months ago

evanyeyeye commented 1 year ago

Description

Testing

evanyeyeye commented 10 months ago

This PR is updated and ready for review.

damianhxy commented 9 months ago

@coderabbit review

cg2v commented 9 months ago

At the very least, this operation should verify that it's using the localDocker backend, since it can only possibly work with that backend.

coderabbitai[bot] commented 9 months ago
Walkthrough ## Walkthrough The recent updates involve enhancing a system with Docker capabilities, including building Docker images and handling larger input files. A new `.gitignore` entry ensures temporary Docker files are excluded. The `tango-cli` script now supports a build command, and the server-side code has been updated to handle build requests and manage Docker operations. Additionally, the Python environment has been adjusted with package version changes, including a downgrade of the `requests` package and the addition of the `docker` package. ## Changes | File(s) | Summary | | --- | --- | | `.gitignore` | Excluded `dockerTmp/*` to prevent tracking temporary Docker files. | | `clients/.../tango-cli.py` | Added `--build` argument and `tango_build` function for Docker image building. | | `config.template.py` | Increased `MAX_INPUT_FILE_SIZE` from 250MB to 10GB. | | `requirements.txt` | Downgraded `requests` to 2.28.0 and added `docker` 5.0.3. | | `restful_tango/server.py` | Added `BuildHandler` class for handling Docker build requests. | | `restful_tango/tangoREST.py` (3 entries) | Imported `docker` module, added Docker-related status codes, and a new `build` method for image building. |

Tips ### Chat with CodeRabbit Bot (`@coderabbitai`) - If you reply to a *review comment* from CodeRabbit, the bot will automatically respond. - To engage with CodeRabbit bot directly around the specific lines of code in the PR, mention @coderabbitai in your review comment - Note: Review comments are made on code diffs or files, not on the PR overview. - Add `@coderabbitai ignore` anywhere in the PR description to prevent this PR from being reviewed. ### CodeRabbit Commands (invoked as PR comments) - `@coderabbitai pause` to pause the reviews on a PR. - `@coderabbitai resume` to resume the paused reviews. - `@coderabbitai review` to trigger a review. This is useful when automatic reviews are disabled for the repository. - `@coderabbitai resolve` resolve all the CodeRabbit review comments. - `@coderabbitai help` to get help. Note: For conversation with the bot, please use the review comments on code diffs or files. ### CodeRabbit Configration File (`.coderabbit.yaml`) - You can programmatically configure CodeRabbit by adding a `.coderabbit.yaml` file to the root of your repository. - The JSON schema for the configuration file is available [here](https://coderabbit.ai/integrations/coderabbit-overrides.v2.json). - If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: `# yaml-language-server: $schema=https://coderabbit.ai/integrations/coderabbit-overrides.v2.json`