Skip to content

chore: add localstack S3 to docker compose#145

Merged
arrocke merged 2 commits intoglobalbibletools:mainfrom
delgado-jacob:pdf_export/localstack
Jan 17, 2026
Merged

chore: add localstack S3 to docker compose#145
arrocke merged 2 commits intoglobalbibletools:mainfrom
delgado-jacob:pdf_export/localstack

Conversation

@delgado-jacob
Copy link
Copy Markdown
Contributor

Split from: #134

Adds a LocalStack S3 service to docker compose so export storage can be exercised locally; this is purely infrastructure wiring.

Copy link
Copy Markdown
Member

@arrocke arrocke left a comment

Choose a reason for hiding this comment

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

Thanks so much for working on this! I left a couple of suggestions to streamline the config and setup

env_file:
- path: .env
required: false
localstack:
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks like when using docker compose, we need to mount a volume for all localstack data otherwise the system state will be lost. Let's mount ./localstack/data to /var/lib/localstack and add that file to gitignore.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

added a volume 7d03ffd

compose.yaml Outdated
- path: .env
required: false
localstack:
image: localstack/localstack:latest
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

If there is a way to pin this to at least a major version, that would prevent changes to localstack from accidentally breaking our dev environements

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Locked to major 4 7d03ffd

compose.yaml Outdated
timeout: 5s
retries: 5

localstack-init:
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We should be able to avoid an additional container just for running scripts by useing initialization hooks. We can mount "./localstack/init/" to "/etc/localstack/init/" and then add the init script to ./localstack/init/ready.d/init.sh. That script can use awslocal instead of aws since that's loaded on the container already.

We will likely need to add more things to the init script, so having that as its own file makes that easier to edit and review.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Moved to dedicated init script 7d03ffd

@delgado-jacob delgado-jacob requested a review from arrocke January 17, 2026 16:51
Copy link
Copy Markdown
Member

@arrocke arrocke left a comment

Choose a reason for hiding this comment

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

🎉 Looks great! Thanks for working on this!

@arrocke arrocke merged commit cfe608a into globalbibletools:main Jan 17, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: ✅ Done

Development

Successfully merging this pull request may close these issues.

2 participants