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

Add configuration of mongodb and rabbotmq hosts #255

Merged
merged 3 commits into from
Jul 19, 2024
Merged

Conversation

lvarin
Copy link
Contributor

@lvarin lvarin commented Jul 18, 2024

IMPORTANT: Please create an issue before filing a pull request! Changes need to be discussed before proceeding. Please read the contribution guidelines.

Details

Please provide enough information so that others can review your pull request. Give a brief summary of the motivation. Refer to the corresponding issue/s with #XXXX for more information.

Testing

Write the appropriate unit and integration tests, if applicable. Make sure these and all other tests pass.

Documentation

Please document your changes and test cases in the appropriate places, if applicable.

Style

Make sure your changes adhere to the coding/documentation style used throughout the project.

Closing issues

If your changes fix any issue/s, put closes #XXXX in your comment to auto-close it/them.

Credit

Add your credentials to the list of contributors once your pull request was merged.

Summary by Sourcery

Added configuration options for MongoDB and RabbitMQ hosts in the update-config-map.sh script. Default values are set to 'mongodb' and 'rabbitmq' respectively if not provided.

Copy link

sourcery-ai bot commented Jul 18, 2024

Reviewer's Guide by Sourcery

This pull request adds the configuration of MongoDB and RabbitMQ hosts to the update-config-map.sh script. The changes ensure that the script can dynamically set the MongoDB and RabbitMQ hosts based on environment variables, with default values if the variables are not set.

File-Level Changes

Files Changes
update-config-map.sh Added dynamic configuration for MongoDB and RabbitMQ hosts using environment variables and updated the script to reflect these changes.

Tips
  • Trigger a new Sourcery review by commenting @sourcery-ai review on the pull request.
  • Continue your discussion with Sourcery by replying directly to review comments.
  • You can change your review settings at any time by accessing your dashboard:
    • Enable or disable the Sourcery-generated pull request summary or reviewer's guide;
    • Change the review language;
  • You can always contact us if you have any questions or feedback.

Copy link

@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 @lvarin - I've reviewed your changes and they look great!

Here's what I looked at during the review
  • 🟡 General issues: 2 issues found
  • 🟢 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 to tell me if it was helpful.

update-config-map.sh Show resolved Hide resolved
Comment on lines 45 to 49
APP_CONFIG=$(yq --arg MONGO_HOST "$MONGO_HOST" \
--arg RABBIT_HOST "$RABBIT_HOST" \
'.db.host = $MONGO_HOST |
.jobs.host = $RABBIT_HOST' \
"$APP_CONFIG_PATH")
Copy link

Choose a reason for hiding this comment

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

issue (bug_risk): Check for yq command availability.

Ensure that the script checks for the availability of the yq command before attempting to use it. This can prevent runtime errors if yq is not installed or not in the PATH.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

added

Copy link

Choose a reason for hiding this comment

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

Great, thanks for adding the check for the yq command availability! This will help prevent any runtime issues. If you encounter any further issues or need additional feedback, feel free to ask. Keep up the good work!

Copy link

@jemaltahir jemaltahir left a comment

Choose a reason for hiding this comment

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

LGTM

@jemaltahir jemaltahir merged commit eecceb3 into dev Jul 19, 2024
3 checks passed
@jemaltahir jemaltahir deleted the update-config branch July 19, 2024 05:51
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