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 command options and documentation to Docker Compose #1645

Merged
merged 9 commits into from
Jan 12, 2024
Merged

Add command options and documentation to Docker Compose #1645

merged 9 commits into from
Jan 12, 2024

Conversation

benjisho
Copy link
Contributor

@benjisho benjisho commented Jan 10, 2024

This PR introduces the command configuration for the bandersnatch service in Docker Compose setup. It includes the default 'mirror' command and adds commented options for 'verify' and 'once' to provide alternatives for running bandersnatch.

The 'command' section is now clearly documented, making it easier for developers and sysadmins to understand and modify the behavior of the bandersnatch service.

Changes:

  • Added 'command' directive to bandersnatch service with the default 'mirror' option.
  • Included comments explaining how to use the 'verify' and 'once' commands.
  • Explained the purpose of additional flags for the 'mirror' command.
  • Provided documentation for the build context of the bandersnatch_nginx image.

This commit introduces the command configuration for the bandersnatch service in Docker Compose setup.
It includes the default 'mirror' command and adds commented options for 'verify' and 'once' to provide alternatives for running bandersnatch.

The 'command' section is now clearly documented, making it easier for developers and sysadmins to understand and modify the behavior of the bandersnatch service.

Changes:
- Added 'command' directive to bandersnatch service with the default 'mirror' option.
- Included comments explaining how to use the 'verify' and 'once' commands.
- Explained the purpose of additional flags for the 'mirror' command.
- Provided documentation for the build context of the bandersnatch_nginx image.
Copy link

codecov bot commented Jan 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (38a9166) 83.55% compared to head (89331b5) 83.55%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1645   +/-   ##
=======================================
  Coverage   83.55%   83.55%           
=======================================
  Files          31       31           
  Lines        4324     4324           
  Branches      780      780           
=======================================
  Hits         3613     3613           
  Misses        524      524           
  Partials      187      187           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@cooperlees cooperlees left a comment

Choose a reason for hiding this comment

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

Sounds good - Can you add some examples of how to use this into the Docker compose readme please?

https://github.com/pypa/bandersnatch/blob/main/src/bandersnatch_docker_compose/README.md

Might help someone like me who's never ran docker-compose before :)

  • And add a changelog entry please.

Added multiple command options for the bandersnatch service in the docker-compose.yml file. These options include mirror, force, debug, verbose, verify, and once modes. Each mode is explained in the comments and can be uncommented to use. This provides flexibility in running the bandersnatch service based on the user's needs.
- Added the missing step for removing Bandersnatch configuration files.
- Included a step for cleaning up Docker artifacts with `docker system prune`.
- Improved clarity and completeness of the repository removal instructions.
Add docker compose link in the main README.md
@benjisho
Copy link
Contributor Author

Changes:

  • Added command options for bandersnatch service in docker-compose.yml
  • Added "Removing the Repository" section in Docker Compose README.md
  • Added link in the main README.md to the Docker Compose section

Users can now choose from several modes by uncommenting the corresponding command in the docker-compose.yml file.

Please review and let me know if any changes are required.
Users can now choose from several modes by uncommenting the corresponding command in the docker-compose.yml file.

@cooperlees
Copy link
Contributor

Can you just run pre-commit and format the .md files please.

@benjisho
Copy link
Contributor Author

Can you just run pre-commit and format the .md files please.

pre-commit done

Copy link
Contributor

@cooperlees cooperlees left a comment

Choose a reason for hiding this comment

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

Awesome. Many thanks for this and battling through our CI :)

It's always a learning curve with each project one contributes too.

@cooperlees cooperlees merged commit bfd1a4c into pypa:main Jan 12, 2024
11 checks passed
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