Skip to content

fix granian-compose.yml #207

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 8, 2025
Merged

fix granian-compose.yml #207

merged 2 commits into from
Jun 8, 2025

Conversation

grillazz
Copy link
Owner

@grillazz grillazz commented Jun 8, 2025

No description provided.

@grillazz grillazz requested a review from Copilot June 8, 2025 18:01
@grillazz grillazz self-assigned this Jun 8, 2025
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates the Granian-specific Docker Compose setup and corresponding Dockerfile to use host networking, set a custom PYTHONPATH, refine volume mounts, switch to an in-memory cache, and relocate Alembic and logging files.

  • Enable network_mode: host and add PYTHONPATH for the app service
  • Refactor the command field into a multi-line Bash invocation
  • Replace Redis with an inmemory service and adjust Dockerfile paths for Alembic and logging

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
granian-compose.yml Added host networking, environment var, volume remap, multi-line command, inmemory dependency
compose.yml Added PYTHONPATH=/panettone environment variable
Dockerfile Moved Alembic and logging files to /panettone paths for consistency
Comments suppressed due to low confidence (2)

granian-compose.yml:11

  • Multiline commands in YAML should use a block scalar (e.g., | or >) instead of embedding newlines inside quotes. Consider: command: |\n bash -c "granian --interface asgi --host 0.0.0.0 --port 8080 app.main:app --access-log --log-level debug --log-config ./logging-granian.json".
command: bash -c "

granian-compose.yml:4

  • [nitpick] Using network_mode: host exposes the service directly on the host network. Ensure this is necessary for performance and accept the security implications, or consider the default bridge mode.
network_mode: host

Co-authored-by: Copilot <[email protected]>
@grillazz grillazz merged commit 9cdc85a into main Jun 8, 2025
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