File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ target /
2+ node_modules /
3+ .git /
4+ api /target /
5+ cli /target /
6+ generator /target /
7+ docs /node_modules /
8+ cli /node_modules /
Original file line number Diff line number Diff line change @@ -2,11 +2,12 @@ FROM rust:1-alpine AS builder
22WORKDIR /usr/src/luna
33COPY . .
44# Install build tools and Node.js for npm dependencies required by cli/build.rs
5- RUN apk add --no-cache build-base nodejs npm
5+ RUN apk add --no-cache build-base nodejs npm pkgconfig openssl-dev openssl-libs-static
66# Install pnpm
77RUN npm install --global corepack@latest
88# Install package.json dependencies in cli directoy
99WORKDIR /usr/src/luna/cli
10+ ENV CI=true
1011RUN pnpm install
1112# Build and install the CLI
1213WORKDIR /usr/src/luna
Original file line number Diff line number Diff line change @@ -164,10 +164,8 @@ fn download_asset(
164164
165165 if target_path. exists ( ) {
166166 if let Some ( expected) = expected_sha256 {
167- if let Ok ( actual) = calculate_sha256 ( & target_path) {
168- if actual == expected {
169- return Ok ( rel_path. to_string ( ) ) ;
170- }
167+ if calculate_sha256 ( & target_path) . is_ok_and ( |actual| actual == expected) {
168+ return Ok ( rel_path. to_string ( ) ) ;
171169 }
172170 } else {
173171 // For images without explicit checksums, we assume they are correct if they exist
You can’t perform that action at this time.
0 commit comments