Skip to content

docs(docker): Describe current state of docker image security plus minor fixes#836

Merged
MaxymVlasov merged 7 commits intomasterfrom
fix/Point_Docker_build_workflow_to_correct_scripts_dir
Mar 21, 2025
Merged

docs(docker): Describe current state of docker image security plus minor fixes#836
MaxymVlasov merged 7 commits intomasterfrom
fix/Point_Docker_build_workflow_to_correct_scripts_dir

Conversation

@yermulnik
Copy link
Copy Markdown
Collaborator

@yermulnik yermulnik commented Mar 13, 2025

  • Point changed-files step to correct scripts dir
  • sort file alphabeticaly
  • Describe current state of docker security

Relates to #835 (this PR should trigger a one-off Docker image rebuild to bring it up-to-date as requested in linked issue)

@MaxymVlasov Maybe it might make sense to schedule Docker image rebuild every other week, biweekly, or so?

Copilot AI review requested due to automatic review settings March 13, 2025 20:39
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Mar 13, 2025

📝 Walkthrough

Summary by CodeRabbit

  • Chores
    • Enhanced the build workflow to more precisely detect changes and trigger updates.
  • Documentation
    • Introduced a new section on Docker image security that outlines best practices, including recommendations for using immutable tags and nightly builds.
    • Made minor formatting improvements for better readability.

Walkthrough

The pull request updates a CI workflow file by modifying the criteria for file monitoring in the "Get changed Docker related files" step. The workflow now explicitly includes the Dockerfile, tools/entrypoint.sh, and scripts from the tools/install/ directory, rather than excluding them. Additionally, a new section is added to the README.md that addresses security implications of using pre-built Docker images, emphasizing the need for immutable tags and careful management of dependencies. No changes were made to public or exported entities.

Changes

File(s) Change Summary
.github/workflows/build-image-test.yaml Updated file monitoring criteria: replaced exclusions for Dockerfile, tools/entrypoint.sh, and tools/*.sh with explicit inclusions, now focusing on tools/install/*.sh.
README.md Added a new section about Docker image security, emphasizing the use of immutable tags and addressing security concerns with mutable tags. Minor formatting adjustments made for readability.

Sequence Diagram(s)

sequenceDiagram
    participant Dev as Developer
    participant CI as CI Workflow
    participant Detector as File Detector
    participant Next as Subsequent Steps

    Dev->>CI: Push commit with changes
    CI->>Detector: Execute "Get changed Docker related files" step
    Detector-->>CI: Return list of explicitly included files
    CI->>Next: Trigger subsequent steps if matching files detected
Loading

Suggested reviewers

  • antonbabenko

📜 Recent review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Free

📥 Commits

Reviewing files that changed from the base of the PR and between 69d2025 and bb27cf1.

📒 Files selected for processing (1)
  • README.md (4 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • README.md

Note

🎁 Summarized by CodeRabbit Free

Your organization has reached its limit of developer seats under the Pro Plan. For new users, CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please add seats to your subscription by visiting https://app.coderabbit.ai/login.If you believe this is a mistake and have available seats, please assign one to the pull request author through the subscription management page using the link above.

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR fixes the Docker image build process by updating the file paths used by the "changed-files" step and reordering the list of watched files.

  • Replace "tools/.sh" with "tools/install/.sh" to target the correct scripts directory.
  • Adjust the file list order for consistency.
Comments suppressed due to low confidence (1)

.github/workflows/build-image-test.yaml:46

  • The updated files list does not appear to be sorted alphabetically as indicated by the commit message. Please reorder the file list to ensure consistent sorting.
Dockerfile

Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
.github/workflows/build-image-test.yaml (1)

1-127: Consider Scheduled Docker Image Rebuilds
The PR objectives mention scheduling a Docker image rebuild on a biweekly basis to ensure the image remains up-to-date. Although this change focuses on the “changed-files” step, it might be beneficial to add a scheduled trigger to this workflow. For example, adding a schedule key with an appropriate cron expression could automate periodic rebuilds.

Would you like assistance in drafting the necessary modifications?

🧰 Tools
🪛 actionlint (1.7.4)

29-29: label "ubuntu-24.04-arm" is unknown. available labels are "windows-latest", "windows-latest-8-cores", "windows-2022", "windows-2019", "ubuntu-latest", "ubuntu-latest-4-cores", "ubuntu-latest-8-cores", "ubuntu-latest-16-cores", "ubuntu-24.04", "ubuntu-22.04", "ubuntu-20.04", "macos-latest", "macos-latest-xl", "macos-latest-xlarge", "macos-latest-large", "macos-15-xlarge", "macos-15-large", "macos-15", "macos-14-xl", "macos-14-xlarge", "macos-14-large", "macos-14", "macos-13-xl", "macos-13-xlarge", "macos-13-large", "macos-13", "macos-12-xl", "macos-12-xlarge", "macos-12-large", "macos-12", "self-hosted", "x64", "arm", "arm64", "linux", "macos", "windows". if it is a custom label for self-hosted runner, set list of labels in actionlint.yaml config file

(runner-label)

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c949dd2 and 857e768.

📒 Files selected for processing (1)
  • .github/workflows/build-image-test.yaml (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (4)
  • GitHub Check: 🧪 Tests / pytest@🐍3.9@macos-14
  • GitHub Check: Ubuntu ARM
  • GitHub Check: pre-commit
  • GitHub Check: Ubuntu x64
🔇 Additional comments (1)
.github/workflows/build-image-test.yaml (1)

44-48: Clarify and Confirm the File Inclusion and Sorting Logic
The updated list now explicitly includes the Docker-related files (“Dockerfile”, “tools/entrypoint.sh”, and “tools/install/*.sh”) instead of using more generic patterns. This improves clarity about which files trigger a rebuild and appears to be sorted in a logical order. Please confirm that this change correctly reflects the intended monitored files and that no critical file is being accidentally omitted.

@yermulnik yermulnik requested a review from Copilot March 13, 2025 20:44
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR updates the Docker image build process by correcting the scripts directory used in the changed-files step and reordering the list of files.

  • Corrects the scripts path from tools/.sh to tools/install/.sh
  • Updates the file list ordering in the GitHub Actions workflow
Comments suppressed due to low confidence (2)

.github/workflows/build-image-test.yaml:48

  • Verify that the updated path 'tools/install/.sh' correctly reflects the intended directory structure for the Docker image build process compared to the previous 'tools/.sh'.
tools/install/*.sh

.github/workflows/build-image-test.yaml:46

  • [nitpick] The file list appears intended to be sorted but is not in strict alphabetical order. Consider sorting all file paths alphabetically for consistency and clarity.
Dockerfile

@MaxymVlasov
Copy link
Copy Markdown
Collaborator

@MaxymVlasov Maybe it might make sense to schedule Docker image rebuild every other week, biweekly, or so?

We already have it in nightly builds.

@yermulnik
Copy link
Copy Markdown
Collaborator Author

@MaxymVlasov Maybe it might make sense to schedule Docker image rebuild every other week, biweekly, or so?

We already have it in nightly builds.

Ah, thanks. Apologies I didn't double check it thoroughly enough 🤦🏻

Comment thread .github/workflows/build-image-test.yaml
@MaxymVlasov MaxymVlasov changed the title fix(docker image build): Point changed-files step to correct scripts dir (and sort list) docs(docker): Describe current state of docker image security plus minor fixes Mar 20, 2025
@MaxymVlasov MaxymVlasov merged commit 2044f1b into master Mar 21, 2025
47 checks passed
@MaxymVlasov MaxymVlasov deleted the fix/Point_Docker_build_workflow_to_correct_scripts_dir branch March 21, 2025 20:41
@antonbabenko
Copy link
Copy Markdown
Owner

This PR is included in version 1.98.0 🎉

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.

4 participants