blackfyre / wga

Jumping forward ~30 years
https://wga-uat.blackfyre.ninja/
MIT License
118 stars 10 forks source link

DX: Image seeder #70

Closed blackfyre closed 8 months ago

blackfyre commented 8 months ago

A new dev support tool was added.

The docker-composer feeds from the .env file, be sure to have it before running the initial migrations. Minio access will be set-up based on the S3_ACCESS_KEY/SECRET values.

:exclamation: Start from a blank slate!

Fixes #69 Inspired by #54

Summary by CodeRabbit

coderabbitai[bot] commented 8 months ago

It seems like you've provided a detailed summary of changes and a request to validate whether the code changes meet the primary objectives and requirements in the linked issues. Based on the provided information, I've updated the content as per your instructions. Here's the updated content:

Walkthrough

The changes involve setting up the application to work with an S3-compatible storage system (Minio) for image handling, updating environment variables, and adding new functionality to seed images into the S3 storage. The .env.example and README.md files have been updated to reflect the new configurations required for S3. New functions have been added to the assets/internals.go file to handle render data and caching of analytics. Additionally, the main.go file has been updated to include a new command for seeding images in a development environment. Various migrations have been updated to reflect changes in table naming conventions and schema adjustments. The models/artworks.go file introduces a new Artwork model and associated query functions, while the utils/seed/images.go file includes functions for seeding images into S3 storage.

Changes

File(s) Change Summary
.env.example, README.md Updated with new S3 configuration and instructions.
assets/internals.go Added new functionality for handling render data and caching of analytics.
main.go Updated to include a new command for seeding images in a development environment.
migrations/* Updated naming conventions and schemas for various tables.
models/artworks.go Added new Artwork model and associated query functions.
utils/seed/images.go Introduced functions for seeding images into S3 storage.

Assessment against linked issues

Objective Addressed Explanation
#69: DX: Seed the associated S3 storage with images The utils/seed/images.go file includes a SeedImages function that seeds images into S3 storage, addressing the primary objective of the linked issue.

The changes made in the codebase align with the objective of the linked issue, which is to seed images into the associated S3 storage. The SeedImages function in utils/seed/images.go is specifically designed to handle this task, suggesting that the objective has been met.


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`
what-the-diff[bot] commented 8 months ago

PR Summary