Skip to content

Conversation

kovacova
Copy link
Collaborator

@kovacova kovacova commented Dec 4, 2024

Summary by Sourcery

Update Docker scripts to use dynamic user names and streamline commands, adjust requirements, and enhance documentation with MacOS instructions.

Build:

  • Update Docker scripts to use the current user's name for Docker operations and streamline the Docker run command.

Documentation:

  • Add MacOS installation instructions for Ollama in the README.

Copy link
Contributor

sourcery-ai bot commented Dec 4, 2024

Reviewer's Guide by Sourcery

This PR updates Docker configuration scripts, dependencies, and documentation. The main changes focus on making the Docker setup more flexible by using dynamic user names, updating package versions, and improving the documentation. The Docker scripts have been refactored to be more maintainable and configurable.

Class diagram for Docker script updates

classDiagram
    class DockerScript {
        - DOCKER_USER_NAME: String
        - FULL_DOCKER_TAG_NAME: String
        + runDockerContainer()
        + buildDockerImage()
    }
    note for DockerScript "Updated to use dynamic user names and refactored for maintainability"

    class DockerRun {
        + run()
    }
    DockerScript --> DockerRun : uses

    class DockerBuild {
        + build()
    }
    DockerScript --> DockerBuild : uses

    class DockerConfig {
        + setEnvironment()
        + setVolumes()
    }
    DockerScript --> DockerConfig : uses

    note for DockerConfig "Handles environment and volume settings"
Loading

File-Level Changes

Change Details Files
Refactored Docker run script for better configurability and maintainability
  • Changed hardcoded username to dynamic whoami command
  • Added default tag name with latest suffix
  • Removed platform-specific flag
  • Improved Docker run command formatting
  • Commented out unused pullImage function
app/llm-poc-variant-01/docker/run-docker-container.sh
Updated Docker build script configuration
  • Changed default username from hardcoded value to dynamic whoami command
  • Commented out pushImageToHub function call
app/llm-poc-variant-01/docker/build-docker-image.sh
Updated dependencies and documentation
  • Downgraded chromadb from 0.5.20 to 0.3.26
  • Added brew installation instructions for Ollama on MacOS
app/llm-poc-variant-01/requirements.txt
app/llm-poc-variant-01/README.md
Added Docker ignore file
  • Created new .Dockerignore file
app/llm-poc-variant-01/docker/.Dockerignore

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time. You can also use
    this command to specify where the summary should be inserted.

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

Hey @kovacova - I've reviewed your changes - here's some feedback:

Overall Comments:

  • There are large blocks of commented-out code in run-docker-container.sh. Please either remove this code if it's no longer needed or document why it needs to be preserved.
  • The chromadb downgrade from 0.5.20 to 0.3.26 is a significant version change. Please explain the reasoning behind this downgrade and confirm it doesn't introduce compatibility issues.
Here's what I looked at during the review
  • 🟢 General issues: all looks good
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

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