Skip to content
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

Build docker image #56

Merged
merged 3 commits into from
Apr 25, 2024
Merged

Build docker image #56

merged 3 commits into from
Apr 25, 2024

Conversation

lenguyenthanh
Copy link
Owner

@lenguyenthanh lenguyenthanh commented Apr 25, 2024

Fix #48, thanks @SergioGlorias for the idea and the action file <3, I stole most of it!

@fitztrev, pls help me review this, as you're my docker hero 💪 thanks!

Now everyone can try this with a docker-compose file like:

name: fide

services:

  api:
    container_name: fide_api
    image: ghcr.io/lenguyenthanh/fide:0.1.0-snapshot
    env_file: .env.docker
    ports:
      - 9669:9669
    networks:
      - fide_api

  db:
    image: postgres:16.2-alpine3.19
    container_name: fide_postgres_api
    ports:
      - 5432:5432
    networks:
      - fide_api
    restart: unless-stopped

networks:
  fide_api:
    driver: bridge

TODO

  • add docs
  • move only build docker image in main (or maybe tag)

@lenguyenthanh lenguyenthanh marked this pull request as ready for review April 25, 2024 10:25
@fitztrev
Copy link
Contributor

👍 I think this is a great idea

How would you feel about including Postgres on the image directly? For this use case, it might make sense to just bundle everything together so only 1 container needs to be running.

Then it could be run using a single command too:

docker run -p 9669:9669 ghcr.io/lenguyenthanh/fide:0.1.0-snapshot

@lenguyenthanh
Copy link
Owner Author

How would you feel about including Postgres on the image directly? For this use case, it might make sense to just bundle everything together so only 1 container needs to be running.

Then it could be run using a single command too:

docker run -p 9669:9669 ghcr.io/lenguyenthanh/fide:0.1.0-snapshot

Thanks for looking!

I prefer to keep it this way, because it is more flexible than including postgres directly. And it is just a docker compose file away (which We also provide) from a single command run too.

@lenguyenthanh lenguyenthanh merged commit d870f50 into main Apr 25, 2024
3 checks passed
@lenguyenthanh lenguyenthanh deleted the build-docker-image branch April 25, 2024 13:31
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.

2 participants