mirror of
https://github.com/edera-dev/sprout.git
synced 2026-03-22 11:20:17 +00:00
Compare commits
9 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| c70d1e4d80 | |||
|
|
1f6fc237c6 | ||
|
c86215f196
|
|||
|
|
425ce8ede4 | ||
|
|
656fde2044 | ||
|
|
5740c14e31 | ||
|
c295de4951
|
|||
|
|
95e0360721 | ||
|
|
1370e1b39b |
6
.github/workflows/ci-actions.yml
vendored
6
.github/workflows/ci-actions.yml
vendored
@@ -25,17 +25,17 @@ jobs:
|
||||
actions: read # Needed to analyze action metadata.
|
||||
steps:
|
||||
- name: harden runner
|
||||
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||
uses: step-security/harden-runner@e3f713f2d8f53843e71c69a996d56f51aa9adfb9 # v2.14.1
|
||||
with:
|
||||
egress-policy: audit
|
||||
|
||||
- name: checkout
|
||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
- name: setup uv
|
||||
uses: astral-sh/setup-uv@681c641aba71e4a1c380be3ab5e12ad51f415867 # v7.1.6
|
||||
uses: astral-sh/setup-uv@61cb8a9741eeb8a550a1b8544337180c0fc8476b # v7.2.0
|
||||
|
||||
- name: zizmor
|
||||
run: uvx zizmor --pedantic --format sarif . > results.sarif
|
||||
|
||||
12
.github/workflows/ci-code.yml
vendored
12
.github/workflows/ci-code.yml
vendored
@@ -21,12 +21,12 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: harden runner
|
||||
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||
uses: step-security/harden-runner@e3f713f2d8f53843e71c69a996d56f51aa9adfb9 # v2.14.1
|
||||
with:
|
||||
egress-policy: audit
|
||||
|
||||
- name: checkout
|
||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
@@ -51,12 +51,12 @@ jobs:
|
||||
name: 'build ${{ matrix.arch }}'
|
||||
steps:
|
||||
- name: harden runner
|
||||
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||
uses: step-security/harden-runner@e3f713f2d8f53843e71c69a996d56f51aa9adfb9 # v2.14.1
|
||||
with:
|
||||
egress-policy: audit
|
||||
|
||||
- name: checkout
|
||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
@@ -80,12 +80,12 @@ jobs:
|
||||
name: 'clippy ${{ matrix.arch }}'
|
||||
steps:
|
||||
- name: harden runner
|
||||
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||
uses: step-security/harden-runner@e3f713f2d8f53843e71c69a996d56f51aa9adfb9 # v2.14.1
|
||||
with:
|
||||
egress-policy: audit
|
||||
|
||||
- name: checkout
|
||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
|
||||
4
.github/workflows/codeql.yml
vendored
4
.github/workflows/codeql.yml
vendored
@@ -37,12 +37,12 @@ jobs:
|
||||
build-mode: none
|
||||
steps:
|
||||
- name: harden runner
|
||||
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||
uses: step-security/harden-runner@e3f713f2d8f53843e71c69a996d56f51aa9adfb9 # v2.14.1
|
||||
with:
|
||||
egress-policy: audit
|
||||
|
||||
- name: checkout
|
||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
|
||||
6
.github/workflows/publish.yml
vendored
6
.github/workflows/publish.yml
vendored
@@ -25,12 +25,12 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: harden runner
|
||||
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||
uses: step-security/harden-runner@e3f713f2d8f53843e71c69a996d56f51aa9adfb9 # v2.14.1
|
||||
with:
|
||||
egress-policy: audit
|
||||
|
||||
- name: checkout
|
||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
@@ -49,7 +49,7 @@ jobs:
|
||||
path: target/assemble/*
|
||||
|
||||
- name: 'attest artifacts'
|
||||
uses: actions/attest-build-provenance@977bb373ede98d70efdf65b84cb5f73e068dcc2a # v3.0.0
|
||||
uses: actions/attest-build-provenance@96278af6caaf10aea03fd8d33a09a777ca52d62f # v3.2.0
|
||||
with:
|
||||
subject-name: artifacts.zip
|
||||
subject-digest: "sha256:${{ steps.upload.outputs.artifact-digest }}"
|
||||
|
||||
6
.github/workflows/release.yml
vendored
6
.github/workflows/release.yml
vendored
@@ -25,12 +25,12 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: harden runner
|
||||
uses: step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
|
||||
uses: step-security/harden-runner@e3f713f2d8f53843e71c69a996d56f51aa9adfb9 # v2.14.1
|
||||
with:
|
||||
egress-policy: audit
|
||||
|
||||
- name: checkout
|
||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
@@ -42,7 +42,7 @@ jobs:
|
||||
run: ./hack/assemble.sh
|
||||
|
||||
- name: 'attest release artifacts'
|
||||
uses: actions/attest-build-provenance@977bb373ede98d70efdf65b84cb5f73e068dcc2a # v3.0.0
|
||||
uses: actions/attest-build-provenance@96278af6caaf10aea03fd8d33a09a777ca52d62f # v3.2.0
|
||||
with:
|
||||
subject-path: target/assemble/*
|
||||
|
||||
|
||||
36
Cargo.lock
generated
36
Cargo.lock
generated
@@ -4,9 +4,9 @@ version = 4
|
||||
|
||||
[[package]]
|
||||
name = "anyhow"
|
||||
version = "1.0.100"
|
||||
version = "1.0.101"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "a23eb6b1614318a8071c9b2521f36b424b2c83db5eb3a0fead4a6c0809af6e61"
|
||||
checksum = "5f0e0fee31ef5ed1ba1316088939cea399010ed7731dba877ed44aeb407a75ea"
|
||||
|
||||
[[package]]
|
||||
name = "bit_field"
|
||||
@@ -66,7 +66,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "edera-sprout-boot"
|
||||
version = "0.0.27"
|
||||
version = "0.0.28"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"edera-sprout-build",
|
||||
@@ -83,18 +83,18 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "edera-sprout-build"
|
||||
version = "0.0.27"
|
||||
version = "0.0.28"
|
||||
|
||||
[[package]]
|
||||
name = "edera-sprout-config"
|
||||
version = "0.0.27"
|
||||
version = "0.0.28"
|
||||
dependencies = [
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "edera-sprout-eficore"
|
||||
version = "0.0.27"
|
||||
version = "0.0.28"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"bitflags",
|
||||
@@ -129,9 +129,9 @@ checksum = "534d589df1ef528a238f4bc4b1db081a1280f3aedf2695fd8971e9853a7fa4f6"
|
||||
|
||||
[[package]]
|
||||
name = "libc"
|
||||
version = "0.2.178"
|
||||
version = "0.2.180"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "37c93d8daa9d8a012fd8ab92f088405fb202ea0b6ab73ee2482ae66af4f42091"
|
||||
checksum = "bcc35a38544a891a5f7c865aca548a982ccb3b8650a5b06d0fd33a10283c56fc"
|
||||
|
||||
[[package]]
|
||||
name = "lock_api"
|
||||
@@ -150,9 +150,9 @@ checksum = "5e5032e24019045c762d3c0f28f5b6b8bbf38563a65908389bf7978758920897"
|
||||
|
||||
[[package]]
|
||||
name = "proc-macro2"
|
||||
version = "1.0.103"
|
||||
version = "1.0.106"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "5ee95bc4ef87b8d5ba32e8b7714ccc834865276eab0aed5c9958d00ec45f49e8"
|
||||
checksum = "8fd00f0bb2e90d81d1044c2b32617f68fcb9fa3bb7640c23e9c748e53fb30934"
|
||||
dependencies = [
|
||||
"unicode-ident",
|
||||
]
|
||||
@@ -179,9 +179,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "quote"
|
||||
version = "1.0.42"
|
||||
version = "1.0.44"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "a338cc41d27e6cc6dce6cefc13a0729dfbb81c262b1f519331575dd80ef3067f"
|
||||
checksum = "21b2ebcf727b7760c461f091f9f0f539b77b8e87f2fd88131e7f1b433b3cece4"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
]
|
||||
@@ -259,9 +259,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "syn"
|
||||
version = "2.0.111"
|
||||
version = "2.0.114"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "390cc9a294ab71bdb1aa2e99d13be9c753cd2d7bd6560c77118597410c4d2e87"
|
||||
checksum = "d4d107df263a3013ef9b1879b0df87d706ff80f65a86ea879bd9c31f9b307c2a"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
@@ -270,9 +270,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "toml"
|
||||
version = "0.9.10+spec-1.1.0"
|
||||
version = "0.9.11+spec-1.1.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "0825052159284a1a8b4d6c0c86cbc801f2da5afd2b225fa548c72f2e74002f48"
|
||||
checksum = "f3afc9a848309fe1aaffaed6e1546a7a14de1f935dc9d89d32afd9a44bab7c46"
|
||||
dependencies = [
|
||||
"serde_core",
|
||||
"serde_spanned",
|
||||
@@ -359,9 +359,9 @@ checksum = "0c8352f8c05e47892e7eaf13b34abd76a7f4aeaf817b716e88789381927f199c"
|
||||
|
||||
[[package]]
|
||||
name = "unicode-ident"
|
||||
version = "1.0.22"
|
||||
version = "1.0.23"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9312f7c4f6ff9069b165498234ce8be658059c6728633667c526e27dc2cf1df5"
|
||||
checksum = "537dd038a89878be9b64dd4bd1b260315c1bb94f4d784956b81e27a088d9a09e"
|
||||
|
||||
[[package]]
|
||||
name = "version_check"
|
||||
|
||||
@@ -9,7 +9,7 @@ resolver = "3"
|
||||
|
||||
[workspace.package]
|
||||
license = "Apache-2.0"
|
||||
version = "0.0.27"
|
||||
version = "0.0.28"
|
||||
homepage = "https://sprout.edera.dev"
|
||||
repository = "https://github.com/edera-dev/sprout"
|
||||
edition = "2024"
|
||||
@@ -48,7 +48,7 @@ version = "1.3.0"
|
||||
default-features = false
|
||||
|
||||
[workspace.dependencies.toml]
|
||||
version = "0.9.10"
|
||||
version = "0.9.11"
|
||||
default-features = false
|
||||
features = ["serde", "parse"]
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
ARG RUST_PROFILE=release
|
||||
ARG RUST_TARGET_SUBDIR=release
|
||||
|
||||
FROM --platform=$BUILDPLATFORM rust:1.92.0-alpine@sha256:f6c22e0a256c05d44fca23bf530120b5d4a6249a393734884281ca80782329bc AS build
|
||||
FROM --platform=$BUILDPLATFORM rust:1.93.0-alpine@sha256:69d7b9d9aeaf108a1419d9a7fcf7860dcc043e9dbd1ab7ce88e44228774d99e9 AS build
|
||||
RUN apk --no-cache add musl-dev busybox-static
|
||||
ARG RUST_PROFILE
|
||||
RUN adduser -S -s /bin/sh build
|
||||
|
||||
@@ -21,7 +21,7 @@ pub fn chainload(context: Rc<SproutContext>, configuration: &ChainloadConfigurat
|
||||
// Resolve the path to the image to chainload.
|
||||
let resolved = eficore::path::resolve_path(
|
||||
Some(context.root().loaded_image_path()?),
|
||||
&context.stamp(&configuration.path),
|
||||
context.stamp(&configuration.path),
|
||||
)
|
||||
.context("unable to resolve chainload path")?;
|
||||
|
||||
@@ -38,8 +38,7 @@ pub fn chainload(context: Rc<SproutContext>, configuration: &ChainloadConfigurat
|
||||
.context("unable to open loaded image protocol")?;
|
||||
|
||||
// Stamp and combine the options to pass to the image.
|
||||
let options =
|
||||
utils::combine_options(configuration.options.iter().map(|item| context.stamp(item)));
|
||||
let options = utils::combine_options(context.stamp_iter(configuration.options.iter()));
|
||||
|
||||
// Pass the load options to the image.
|
||||
// If no options are provided, the resulting string will be empty.
|
||||
@@ -50,6 +49,7 @@ pub fn chainload(context: Rc<SproutContext>, configuration: &ChainloadConfigurat
|
||||
.context("unable to convert chainloader options to CString16")?,
|
||||
);
|
||||
|
||||
// Ensure the chainloader options limit is not exceeded.
|
||||
if options.num_bytes() > u32::MAX as usize {
|
||||
bail!("chainloader options too large");
|
||||
}
|
||||
|
||||
@@ -20,20 +20,11 @@ use uefi::Guid;
|
||||
/// Builds a configuration string for the Xen EFI stub using the specified `configuration`.
|
||||
fn build_xen_config(context: Rc<SproutContext>, configuration: &EderaConfiguration) -> String {
|
||||
// Stamp xen options and combine them.
|
||||
let xen_options = utils::combine_options(
|
||||
configuration
|
||||
.xen_options
|
||||
.iter()
|
||||
.map(|item| context.stamp(item)),
|
||||
);
|
||||
let xen_options = utils::combine_options(context.stamp_iter(configuration.xen_options.iter()));
|
||||
|
||||
// Stamp kernel options and combine them.
|
||||
let kernel_options = utils::combine_options(
|
||||
configuration
|
||||
.kernel_options
|
||||
.iter()
|
||||
.map(|item| context.stamp(item)),
|
||||
);
|
||||
let kernel_options =
|
||||
utils::combine_options(context.stamp_iter(configuration.kernel_options.iter()));
|
||||
|
||||
// xen config file format is ini-like
|
||||
[
|
||||
|
||||
@@ -269,6 +269,15 @@ impl SproutContext {
|
||||
Self::stamp_values(&self.all_values(), text.as_ref()).1
|
||||
}
|
||||
|
||||
/// Stamps all the items from the iterator `input` with all the values in this [SproutContext]
|
||||
/// and it's parents. This calls [self.stamp] on each item.
|
||||
pub fn stamp_iter(
|
||||
&self,
|
||||
input: impl Iterator<Item = impl AsRef<str>>,
|
||||
) -> impl Iterator<Item = String> {
|
||||
input.map(|item| self.stamp(item))
|
||||
}
|
||||
|
||||
/// Unloads a [SproutContext] back into an owned context. This
|
||||
/// may not succeed if something else is holding onto the value.
|
||||
pub fn unload(self: Rc<SproutContext>) -> Option<SproutContext> {
|
||||
|
||||
@@ -18,7 +18,7 @@ fn load_driver(context: Rc<SproutContext>, driver: &DriverDeclaration) -> Result
|
||||
// Resolve the path to the driver image.
|
||||
let resolved = eficore::path::resolve_path(
|
||||
Some(context.root().loaded_image_path()?),
|
||||
&context.stamp(&driver.path),
|
||||
context.stamp(&driver.path),
|
||||
)
|
||||
.context("unable to resolve path to driver")?;
|
||||
|
||||
|
||||
@@ -22,11 +22,10 @@ pub fn generate(
|
||||
|
||||
// Stamp the entry title and actions from the template.
|
||||
let mut entry = list.entry.clone();
|
||||
entry.actions = entry
|
||||
.actions
|
||||
.into_iter()
|
||||
.map(|action| context.stamp(action))
|
||||
.collect();
|
||||
|
||||
// Stamp all the actions this entry references.
|
||||
entry.actions = context.stamp_iter(entry.actions.into_iter()).collect();
|
||||
|
||||
// Push the entry into the list with the new context.
|
||||
entries.push(BootableEntry::new(
|
||||
index.to_string(),
|
||||
|
||||
@@ -48,8 +48,8 @@ fn cstring16_contains_char(string: &CString16, c: char) -> bool {
|
||||
|
||||
/// Parses the input `path` as a [DevicePath].
|
||||
/// Uses the [DevicePathFromText] protocol exclusively, and will fail if it cannot acquire the protocol.
|
||||
pub fn text_to_device_path(path: &str) -> Result<PoolDevicePath> {
|
||||
let path = CString16::try_from(path).context("unable to convert path to CString16")?;
|
||||
pub fn text_to_device_path(path: impl AsRef<str>) -> Result<PoolDevicePath> {
|
||||
let path = CString16::try_from(path.as_ref()).context("unable to convert path to CString16")?;
|
||||
let device_path_from_text = uefi::boot::open_protocol_exclusive::<DevicePathFromText>(
|
||||
uefi::boot::get_handle_for_protocol::<DevicePathFromText>()
|
||||
.context("no device path from text protocol")?,
|
||||
@@ -113,8 +113,13 @@ pub fn device_path_subpath(path: &DevicePath) -> Result<String> {
|
||||
/// Resolve a path specified by `input` to its various components.
|
||||
/// Uses `default_root_path` as the base root if one is not specified in the path.
|
||||
/// Returns [ResolvedPath] which contains the resolved components.
|
||||
pub fn resolve_path(default_root_path: Option<&DevicePath>, input: &str) -> Result<ResolvedPath> {
|
||||
let mut path = text_to_device_path(input).context("unable to convert text to path")?;
|
||||
pub fn resolve_path(
|
||||
default_root_path: Option<&DevicePath>,
|
||||
input: impl ToString,
|
||||
) -> Result<ResolvedPath> {
|
||||
let mut input = input.to_string();
|
||||
|
||||
let mut path = text_to_device_path(&input).context("unable to convert text to path")?;
|
||||
let path_has_device = path
|
||||
.node_iter()
|
||||
.next()
|
||||
@@ -125,7 +130,6 @@ pub fn resolve_path(default_root_path: Option<&DevicePath>, input: &str) -> Resu
|
||||
.map(|it| it.to_string().contains('('))
|
||||
.unwrap_or(false);
|
||||
if !path_has_device {
|
||||
let mut input = input.to_string();
|
||||
if !input.starts_with('\\') {
|
||||
input.insert(0, '\\');
|
||||
}
|
||||
|
||||
@@ -84,7 +84,7 @@ impl<'a> ShimInput<'a> {
|
||||
let path = path
|
||||
.to_string(DisplayOnly(false), AllowShortcuts(false))
|
||||
.context("unable to convert device path to string")?;
|
||||
let path = crate::path::resolve_path(None, &path.to_string())
|
||||
let path = crate::path::resolve_path(None, path.to_string())
|
||||
.context("unable to resolve path")?;
|
||||
// Read the file path.
|
||||
let data = path.read_file()?;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
FROM --platform=$BUILDPLATFORM debian:trixie@sha256:0d01188e8dd0ac63bf155900fad49279131a876a1ea7fac917c62e87ccb2732d AS build
|
||||
FROM --platform=$BUILDPLATFORM debian:trixie@sha256:2c91e484d93f0830a7e05a2b9d92a7b102be7cab562198b984a84fdbc7806d91 AS build
|
||||
ARG BUILDPLATFORM
|
||||
ARG EFI_NAME
|
||||
RUN export DEBIAN_FRONTEND=noninteractive && apt-get update && apt-get install -y \
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
ARG KERNEL_SOURCE_URL=https://cdn.kernel.org/pub/linux/kernel/v6.x/linux-6.18.2.tar.xz
|
||||
ARG KERNEL_CHECKSUM=sha256:558c6bbab749492b34f99827fe807b0039a744693c21d3a7e03b3a48edaab96a
|
||||
|
||||
FROM --platform=$BUILDPLATFORM debian:trixie@sha256:0d01188e8dd0ac63bf155900fad49279131a876a1ea7fac917c62e87ccb2732d AS buildenv
|
||||
FROM --platform=$BUILDPLATFORM debian:trixie@sha256:2c91e484d93f0830a7e05a2b9d92a7b102be7cab562198b984a84fdbc7806d91 AS buildenv
|
||||
RUN export DEBIAN_FRONTEND=noninteractive && apt-get update && apt-get install -y \
|
||||
build-essential squashfs-tools python3-yaml \
|
||||
patch diffutils sed mawk findutils zstd \
|
||||
|
||||
@@ -1 +1 @@
|
||||
FROM --platform=$BUILDPLATFORM debian:trixie@sha256:0d01188e8dd0ac63bf155900fad49279131a876a1ea7fac917c62e87ccb2732d
|
||||
FROM --platform=$BUILDPLATFORM debian:trixie@sha256:2c91e484d93f0830a7e05a2b9d92a7b102be7cab562198b984a84fdbc7806d91
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
ARG TARGET_IMAGE=scratch
|
||||
FROM ${TARGET_IMAGE} AS image
|
||||
FROM --platform=$BUILDPLATFORM debian:trixie@sha256:0d01188e8dd0ac63bf155900fad49279131a876a1ea7fac917c62e87ccb2732d AS final
|
||||
FROM --platform=$BUILDPLATFORM debian:trixie@sha256:2c91e484d93f0830a7e05a2b9d92a7b102be7cab562198b984a84fdbc7806d91 AS final
|
||||
COPY --from=image / /image
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
FROM alpine:3.23@sha256:865b95f46d98cf867a156fe4a135ad3fe50d2056aa3f25ed31662dff6da4eb62 AS rootfs
|
||||
FROM alpine:3.23@sha256:25109184c71bdad752c8312a8623239686a9a2071e8825f20acb8f2198c3f659 AS rootfs
|
||||
RUN apk --no-cache add alpine-base tzdata wireless-regdb ifupdown-ng agetty
|
||||
RUN rc-update add devfs sysinit && \
|
||||
rc-update add dmesg sysinit && \
|
||||
@@ -21,7 +21,7 @@ RUN rc-update add devfs sysinit && \
|
||||
ADD kernel.modules.tgz /
|
||||
COPY files/interfaces /etc/network/interfaces
|
||||
|
||||
FROM alpine:3.23@sha256:865b95f46d98cf867a156fe4a135ad3fe50d2056aa3f25ed31662dff6da4eb62 AS build
|
||||
FROM alpine:3.23@sha256:25109184c71bdad752c8312a8623239686a9a2071e8825f20acb8f2198c3f659 AS build
|
||||
COPY --from=rootfs / /rootfs
|
||||
WORKDIR /rootfs
|
||||
RUN find . | cpio -R 0:0 --ignore-devno --renumber-inodes -o -H newc --quiet > /initramfs
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
FROM alpine:3.23@sha256:865b95f46d98cf867a156fe4a135ad3fe50d2056aa3f25ed31662dff6da4eb62 AS build
|
||||
FROM alpine:3.23@sha256:25109184c71bdad752c8312a8623239686a9a2071e8825f20acb8f2198c3f659 AS build
|
||||
ARG TARGETPLATFORM
|
||||
RUN if [ "${TARGETPLATFORM}" = "linux/amd64" ] || [ "${TARGETPLATFORM}" = "linux/x86_64" ]; then \
|
||||
apk --no-cache add ovmf edk2-shell; cp /usr/share/ovmf/bios.bin /ovmf.fd; fi
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
FROM alpine:3.23@sha256:865b95f46d98cf867a156fe4a135ad3fe50d2056aa3f25ed31662dff6da4eb62 AS build
|
||||
FROM alpine:3.23@sha256:25109184c71bdad752c8312a8623239686a9a2071e8825f20acb8f2198c3f659 AS build
|
||||
ARG TARGETPLATFORM
|
||||
RUN apk add --no-cache xen-hypervisor && cp /usr/lib/efi/xen.efi /xen.efi
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
[toolchain]
|
||||
channel = "1.92.0"
|
||||
channel = "1.93.0"
|
||||
components = ["rustfmt", "clippy"]
|
||||
targets = ["x86_64-unknown-uefi", "aarch64-unknown-uefi"]
|
||||
|
||||
Reference in New Issue
Block a user