-
-
Notifications
You must be signed in to change notification settings - Fork 137
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
adding local docker compose with local postgres #39
Open
webcoderz
wants to merge
5
commits into
main
Choose a base branch
from
local-dev-mode
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
a56ef1b
adding local docker compose with local postgres
webcoderz 9484cb9
Update docker-compose.yaml
webcoderz 2bcc71d
various fixes and getting closer to parity with main
webcoderz 12175b3
remove apt deletion
webcoderz 4d53aa7
Update Dockerfile
webcoderz File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
version: '3.9' | ||
services: | ||
|
||
comfy-deploy: | ||
build: | ||
context: . | ||
dockerfile: ./local/Dockerfile | ||
restart: unless-stopped | ||
volumes: | ||
- ./local/scripts/entrypoint.sh:/comfyui-deploy/web/deploy_entrypoint.sh | ||
entrypoint: /comfyui-deploy/web/deploy_entrypoint.sh | ||
ports: | ||
- 3000:3000 | ||
depends_on: | ||
- postgres | ||
- pg_proxy | ||
- localstack | ||
environment: | ||
VSCODE_DEV_CONTAINER: true | ||
|
||
|
||
### comfy-deploy services | ||
|
||
postgres: | ||
image: "postgres:15.2-alpine" | ||
environment: | ||
POSTGRES_USER: postgres | ||
POSTGRES_PASSWORD: postgres | ||
POSTGRES_DB: verceldb | ||
expose: | ||
- 5432 | ||
|
||
|
||
pg_proxy: | ||
image: ghcr.io/neondatabase/wsproxy:latest | ||
environment: | ||
APPEND_PORT: "postgres:5432" | ||
ALLOW_ADDR_REGEX: ".*" | ||
LOG_TRAFFIC: "true" | ||
expose: | ||
- 80 | ||
depends_on: | ||
- postgres | ||
|
||
|
||
localstack: | ||
image: localstack/localstack:latest | ||
environment: | ||
SERVICES: s3 | ||
ports: | ||
- 4566:4566 | ||
volumes: | ||
- ../localstack/aws:/etc/localstack/init/ready.d | ||
- ../localstack/aws:/app/web/aws |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
FROM node:21-bullseye AS comfy_deploy | ||
|
||
|
||
|
||
RUN npm install -g bun | ||
|
||
COPY ./web /web | ||
|
||
|
||
WORKDIR /web | ||
|
||
RUN cp .env.local.example .env.local | ||
|
||
RUN bun i | ||
|
||
ENTRYPOINT [ "bun", "dev" ] |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#!/bin/bash | ||
|
||
echo "comfy deploy container starting.." | ||
|
||
echo "Running migrations.." | ||
bun migrate-local | ||
|
||
echo "Starting comfy deploy.." | ||
bun dev |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
POSTGRES_SSL="false" | ||
POSTGRES_URL="postgres://postgres:postgres@postgres:5432/verceldb" | ||
|
||
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY= | ||
CLERK_SECRET_KEY= | ||
|
||
SPACES_ENDPOINT="http://localhost:4566" | ||
SPACES_ENDPOINT_CDN="http://localhost:4566" | ||
SPACES_REGION="nyc3" | ||
SPACES_BUCKET="comfyui-deploy" | ||
SPACES_KEY="xyz" | ||
SPACES_SECRET="aaa" | ||
SPACES_CDN_DONT_INCLUDE_BUCKET="false" | ||
SPACES_CDN_FORCE_PATH_STYLE="true" | ||
|
||
MODAL_BUILDER_URL= | ||
|
||
JWT_SECRET="openssl rand -hex 32" | ||
PLAUSIBLE_DOMAIN= | ||
|
||
NEXT_PUBLIC_POSTHOG_KEY="your-api-key" | ||
NEXT_PUBLIC_POSTHOG_HOST="your-ph-address" |
This file contains 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
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could your references just use the existing
web/.env.example
https://github.com/BennyKok/comfyui-deploy/blob/main/web/.env.exampleThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yea can just change the POSTGRES_PORT env of the local Postgres to reflect 5480 , the reason it’s different is because I’m not exposing Postgres to host network it’s only exposed internally
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also since it’s on internal network you can use the service name instead of localhost:5480.. eg. postgres:5480
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The docker file copies in the env.local env vars should I get rid of that also?