-
Notifications
You must be signed in to change notification settings - Fork 7
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
MCU Workflow example with RP2350 #305
base: main
Are you sure you want to change the base?
Conversation
WalkthroughThree new configuration files have been added under the Changes
Sequence Diagram(s)sequenceDiagram
participant U as User
participant C as Container Build
participant D as DNF Package Manager
participant R as Rust Setup
U->>C: Initiate build (Containerfile)
C->>D: Install gcc, systemd-devel
D-->>C: Packages installed
C->>R: Run rustup install & update PATH
R-->>C: Rust installed
C->>R: Add target thumbv8m.main-none-eabihf
C->>R: Install probe-rs-tools via Cargo
sequenceDiagram
participant U as User
participant C as Container Build
participant D as DNF Package Manager
participant S as User Switch
participant R as Rust Setup
U->>C: Initiate build (Containerfile.devspace)
C->>D: Install gcc, systemd-devel, gdb as root
D-->>C: Packages installed
C->>S: Switch to UID 10001
S-->>C: User switched
C->>R: Run rust installation script & update PATH
R-->>C: Rust installed
C->>R: Add target thumbv8m.main-none-eabihf
C->>R: Install probe-rs-tools (locked)
Possibly related PRs
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
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)
Other keywords and placeholders
CodeRabbit Configuration File (
|
✅ Deploy Preview for jumpstarter-docs ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (4)
examples/mcu-rp2350/Containerfile (2)
1-3
: Add package cleanup after installation.To reduce the container image size, consider cleaning up the DNF cache after package installation.
-RUN dnf install -y rustup gcc systemd-devel +RUN dnf install -y rustup gcc systemd-devel && \ + dnf clean all && \ + rm -rf /var/cache/dnf
4-7
: Optimize Dockerfile by chaining commands.Multiple RUN commands create unnecessary layers in the container image. Consider chaining these commands to reduce the image size.
-RUN rustup-init -y -ENV PATH="$PATH:$HOME/.cargo/bin" -RUN ~/.cargo/bin/rustup target add thumbv8m.main-none-eabihf -RUN ~/.cargo/bin/cargo install --locked probe-rs-tools +RUN rustup-init -y && \ + source $HOME/.cargo/env && \ + rustup target add thumbv8m.main-none-eabihf && \ + cargo install --locked probe-rs-tools +ENV PATH="$PATH:$HOME/.cargo/bin"examples/mcu-rp2350/Containerfile.devspace (2)
1-5
: Add package cleanup after installation.To reduce the container image size, consider cleaning up the DNF cache after package installation while running as root.
USER root -RUN dnf install -y gcc systemd-devel gdb +RUN dnf install -y gcc systemd-devel gdb && \ + dnf clean all && \ + rm -rf /var/cache/dnf USER 10001
7-9
: Optimize Dockerfile by chaining commands.Multiple RUN commands create unnecessary layers in the container image. Consider chaining these commands to reduce the image size.
-ENV PATH="$PATH:$HOME/.cargo/bin" -RUN ~/.cargo/bin/rustup target add thumbv8m.main-none-eabihf -RUN ~/.cargo/bin/cargo install --locked probe-rs-tools +RUN source $HOME/.cargo/env && \ + rustup target add thumbv8m.main-none-eabihf && \ + cargo install --locked probe-rs-tools +ENV PATH="$PATH:$HOME/.cargo/bin"
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
examples/mcu-rp2350/Containerfile
(1 hunks)examples/mcu-rp2350/Containerfile.devspace
(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (1)
- GitHub Check: e2e
USER root | ||
RUN dnf install -y gcc systemd-devel gdb | ||
USER 10001 | ||
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or also use dnf as above?
58df77e
to
d6d2b6b
Compare
There was a problem hiding this 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)
pyproject.toml (1)
6-6
: New Workspace Source Entry:jumpstarter-all
A new source entry
jumpstarter-all = { workspace = true }
has been added. This entry will allow the workspace to treat thejumpstarter-all
package consistently with the other jumpstarter components. Ensure that downstream projects or configuration files (e.g., the newpyproject.toml
inexamples/mcu-rp2350
) reference this entry correctly.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
uv.lock
is excluded by!**/*.lock
📒 Files selected for processing (4)
examples/mcu-rp2350/Containerfile
(1 hunks)examples/mcu-rp2350/Containerfile.devspace
(1 hunks)examples/mcu-rp2350/pyproject.toml
(1 hunks)pyproject.toml
(1 hunks)
✅ Files skipped from review due to trivial changes (1)
- examples/mcu-rp2350/pyproject.toml
🚧 Files skipped from review as they are similar to previous changes (2)
- examples/mcu-rp2350/Containerfile
- examples/mcu-rp2350/Containerfile.devspace
⏰ Context from checks skipped due to timeout of 90000ms (7)
- GitHub Check: pytest-matrix (3.13)
- GitHub Check: pytest-matrix (3.12)
- GitHub Check: pytest-matrix (3.11)
- GitHub Check: e2e
- GitHub Check: build-and-push-image (jumpstarter-dev/jumpstarter-devspace .devfile/Containerfile.client)
- GitHub Check: build-and-push-image (jumpstarter-dev/jumpstarter-dev .devfile/Containerfile)
- GitHub Check: build-and-push-image (jumpstarter-dev/jumpstarter Dockerfile)
Summary by CodeRabbit
New Features
Bug Fixes