Skip to content

Commit

Permalink
v2.5.1
Browse files Browse the repository at this point in the history
  • Loading branch information
brod-intel committed Jun 24, 2022
1 parent 38aeceb commit 7bcf956
Show file tree
Hide file tree
Showing 14 changed files with 109 additions and 101 deletions.
16 changes: 15 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,13 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
- Fixed missing DOCKER_RUN_ARGS
- Fixed Miscellaneous typos

## [2.0.4] - 2021-12-03
### Changed
- Fixed /dev/null permissions
- Fixed BASH syntax between distro versions
- Fixed builder-docker runtime detection
- Fixed Miscellaneous bugs

## [2.5.0] - 2022-06-17
### Added
- Dynamic Profiles - The Dynamic Profile feature allows ESP to install software on a target machine without any user interaction. See https://github.com/intel/Edge-Software-Provisioner#dynamic-profile
Expand All @@ -151,6 +158,11 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
### Known Issue
- Virtual PXE (vpxe.sh) may cause a kernel panic under a nested VM. Work around is to build a different kernel. For example, `./build.sh -k ubuntu -P`

## [2.5.1] - 2022-06-24
### Changed
- Fixed default initrd size being to big
- Fixed Miscellaneous bugs




Expand All @@ -162,4 +174,6 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
[2.0.1]: https://github.com/intel/Edge-Software-Provisioner/compare/v2.0...v2.0.1
[2.0.2]: https://github.com/intel/Edge-Software-Provisioner/compare/v2.0.1...v2.0.2
[2.0.3]: https://github.com/intel/Edge-Software-Provisioner/compare/v2.0.2...v2.0.3
[2.5.0]: https://github.com/intel/Edge-Software-Provisioner/compare/v2.0.3...v2.5
[2.0.4]: https://github.com/intel/Edge-Software-Provisioner/compare/v2.0.3...v2.0.4
[2.5.0]: https://github.com/intel/Edge-Software-Provisioner/compare/v2.0.3...v2.5
[2.5.1]: https://github.com/intel/Edge-Software-Provisioner/compare/v2.5...v2.5.1
15 changes: 14 additions & 1 deletion dockerfiles/uos/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,26 @@ LABEL maintainer "Bryan J Rodriguez <[email protected]>"

RUN apk update && apk add --no-cache \
bash \
cpio \
coreutils \
curl \
e2fsprogs \
lsblk \
findutils \
gzip \
dnsmasq \
dumb-init \
iptables \
ovmf \
parted \
pv \
qemu \
qemu-img \
qemu-system-x86_64
qemu-system-x86_64 \
rsync \
syslinux \
util-linux \
xz

COPY /bin/linuxkit /usr/bin/linuxkit

Expand Down
15 changes: 9 additions & 6 deletions dockerfiles/uos/Dockerfile.intel
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@
FROM alpine:3.12 as kernel-builder
LABEL maintainer "Bryan J Rodriguez <[email protected]>"

ARG UBUNTU_RELEASE=5.17.0-1011-oem
ARG KERNEL_VERSION=5.17.0-1011.12_amd64
ARG UBUNTU_RELEASE=5.15.0-1010-intel-iotg
ARG KERNEL_VERSION=5.15.0-1010.14~20.04.1_amd64
ARG KERNEL_PREFIX
ARG KERNEL_PATH=linux-oem-5.17
ARG KERNEL_MODULE_PATH=linux-oem-5.17
ARG KERNEL_PATH=linux-intel-iotg-5.15
ARG KERNEL_MODULE_PATH=linux-intel-iotg-5.15

RUN apk update && apk add --no-cache \
bash \
Expand All @@ -26,12 +26,15 @@ RUN mkdir /out
# wget -qO - https://mirrors.kernel.org/ubuntu/pool/main/l/linux/ | sed -n 's/.*href="\([^"]*\).*/\1/p' | grep -o "linux-image-unsigned-[0-9]\.[0-9]\+\.[0-9]\+-[0-9]\+-generic_[^ ]\+amd64\.deb"

RUN wget http://mirrors.edge.kernel.org/ubuntu/pool/main/l/${KERNEL_PATH}/linux-image-unsigned-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
wget http://mirrors.edge.kernel.org/ubuntu/pool/main/l/${KERNEL_MODULE_PATH}/linux-modules-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb
wget http://mirrors.edge.kernel.org/ubuntu/pool/main/l/${KERNEL_MODULE_PATH}/linux-modules-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
wget http://mirrors.edge.kernel.org/ubuntu/pool/main/l/${KERNEL_MODULE_PATH}/linux-modules-extra-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb

RUN ar x linux-image-unsigned-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
tar -xf data.tar && \
ar x linux-modules-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
tar -xf data.tar.zst && \
tar -xf data.tar.xz && \
ar x linux-modules-extra-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
tar -xf data.tar.xz ./lib/modules/${UBUNTU_RELEASE}/kernel/drivers/net/ethernet/ ./lib/modules/${UBUNTU_RELEASE}/kernel/drivers/gpu/ ./lib/modules/${UBUNTU_RELEASE}/kernel/drivers/net/phy/ ./lib/modules/${UBUNTU_RELEASE}/kernel/drivers/net/wireless/ && \
for d in lib/modules/*; do depmod -b . $(basename $d); done && \
cp boot/vmlinuz* /out/kernel && \
cp boot/config* /out/kernel_config && \
Expand Down
21 changes: 12 additions & 9 deletions dockerfiles/uos/Dockerfile.intel.signed
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@
FROM alpine:3.12 as kernel-builder
LABEL maintainer "Bryan J Rodriguez <[email protected]>"

ARG UBUNTU_RELEASE=5.17.0-1011-oem
ARG KERNEL_VERSION=5.17.0-1011.12_amd64
ARG UBUNTU_RELEASE=5.15.0-1010-intel-iotg
ARG KERNEL_VERSION=5.15.0-1010.14~20.04.1_amd64
ARG KERNEL_PREFIX
ARG KERNEL_PATH=linux-signed-oem-5.17
ARG KERNEL_MODULE_PATH=linux-oem-5.17
ARG KERNEL_PATH=linux-signed-intel-iotg-5.15
ARG KERNEL_MODULE_PATH=linux-intel-iotg-5.15

RUN apk update && apk add --no-cache \
bash \
Expand All @@ -25,13 +25,16 @@ RUN mkdir /out
# List of kernels
# wget -qO - https://mirrors.kernel.org/ubuntu/pool/main/l/linux/ | sed -n 's/.*href="\([^"]*\).*/\1/p' | grep -o "linux-image-unsigned-[0-9]\.[0-9]\+\.[0-9]\+-[0-9]\+-generic_[^ ]\+amd64\.deb"

RUN wget http://mirrors.edge.kernel.org/ubuntu/pool/main/l/${KERNEL_PATH}/linux-image-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
wget http://mirrors.edge.kernel.org/ubuntu/pool/main/l/${KERNEL_MODULE_PATH}/linux-modules-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb
RUN wget http://mirrors.edge.kernel.org/ubuntu/pool/main/l/${KERNEL_PATH}/linux-image-unsigned-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
wget http://mirrors.edge.kernel.org/ubuntu/pool/main/l/${KERNEL_MODULE_PATH}/linux-modules-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
wget http://mirrors.edge.kernel.org/ubuntu/pool/main/l/${KERNEL_MODULE_PATH}/linux-modules-extra-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb

RUN ar x linux-image-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
tar -xf data.tar.zst && \
RUN ar x linux-image-unsigned-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
tar -xf data.tar && \
ar x linux-modules-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
tar -xf data.tar.zst && \
tar -xf data.tar.xz && \
ar x linux-modules-extra-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
tar -xf data.tar.xz ./lib/modules/${UBUNTU_RELEASE}/kernel/drivers/net/ethernet/ ./lib/modules/${UBUNTU_RELEASE}/kernel/drivers/net/phy/ ./lib/modules/${UBUNTU_RELEASE}/kernel/drivers/net/wireless/ && \
for d in lib/modules/*; do depmod -b . $(basename $d); done && \
cp boot/vmlinuz* /out/kernel && \
cp boot/config* /out/kernel_config && \
Expand Down
2 changes: 1 addition & 1 deletion dockerfiles/uos/Dockerfile.ubuntu
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ RUN ar x linux-image-unsigned-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
ar x linux-modules-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
tar -xf data.tar.zst && \
ar x linux-modules-extra-${UBUNTU_RELEASE}_${KERNEL_VERSION}.deb && \
tar -xf data.tar.zst ./lib/modules/${UBUNTU_RELEASE}/kernel/drivers/net/ethernet/ && \
tar -xf data.tar.zst ./lib/modules/${UBUNTU_RELEASE}/kernel/drivers/net/ethernet/ ./lib/modules/${UBUNTU_RELEASE}/kernel/drivers/net/phy/ ./lib/modules/${UBUNTU_RELEASE}/kernel/drivers/net/wireless/ && \
for d in lib/modules/*; do depmod -b . $(basename $d); done && \
cp boot/vmlinuz* /out/kernel && \
cp boot/config* /out/kernel_config && \
Expand Down
2 changes: 1 addition & 1 deletion dockerfiles/uos/dockerfiles/firmware/Dockerfile.fedora
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,4 @@ FROM scratch
ENTRYPOINT []
CMD []
WORKDIR /
COPY --from=kernel-builder /out/* /
COPY --from=kernel-builder /out/* /lib/
8 changes: 4 additions & 4 deletions dockerfiles/uos/dockerfiles/firmware/Dockerfile.intel
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Copyright (C) 2020 Intel Corporation
# Copyright (C) 2022 Intel Corporation
# SPDX-License-Identifier: BSD-3-Clause

FROM alpine:3.12 as kernel-builder
LABEL maintainer "Bryan J Rodriguez <[email protected]>"

ARG FIRMWARE=1.201.5_all
ARG FIRMWARE=1.187.32_all

RUN apk update && apk add --no-cache \
bash \
Expand All @@ -25,11 +25,11 @@ RUN mkdir /out
RUN wget https://mirrors.edge.kernel.org/ubuntu/pool/main/l/linux-firmware/linux-firmware_${FIRMWARE}.deb

RUN ar x linux-firmware_${FIRMWARE}.deb && \
tar -xf data.tar.zst && \
tar -xf data.tar.xz && \
mv ./lib /out/

FROM scratch
ENTRYPOINT []
CMD []
WORKDIR /
COPY --from=kernel-builder /out/* /
COPY --from=kernel-builder /out/* /lib/
10 changes: 5 additions & 5 deletions dockerfiles/uos/dockerfiles/firmware/Dockerfile.intel.signed
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Copyright (C) 2020 Intel Corporation
# Copyright (C) 2022 Intel Corporation
# SPDX-License-Identifier: BSD-3-Clause

FROM alpine:3.12 as kernel-builder
LABEL maintainer "Bryan J Rodriguez <[email protected]>"

ARG FIRMWARE=1.201.5_all
ARG FIRMWARE=1.187.32_all

RUN apk update && apk add --no-cache \
bash \
Expand All @@ -13,7 +13,7 @@ RUN apk update && apk add --no-cache \
rpm \
cpio \
binutils \
zstd
zstd

WORKDIR /build
RUN mkdir /out
Expand All @@ -25,11 +25,11 @@ RUN mkdir /out
RUN wget https://mirrors.edge.kernel.org/ubuntu/pool/main/l/linux-firmware/linux-firmware_${FIRMWARE}.deb

RUN ar x linux-firmware_${FIRMWARE}.deb && \
tar -xf data.tar.zst && \
tar -xf data.tar.xz && \
mv ./lib /out/

FROM scratch
ENTRYPOINT []
CMD []
WORKDIR /
COPY --from=kernel-builder /out/* /
COPY --from=kernel-builder /out/* /lib/
2 changes: 1 addition & 1 deletion dockerfiles/uos/dockerfiles/firmware/Dockerfile.redhat
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ FROM scratch
ENTRYPOINT []
CMD []
WORKDIR /
COPY --from=kernel-builder /out/* /
COPY --from=kernel-builder /out/* /lib/
8 changes: 4 additions & 4 deletions dockerfiles/uos/dockerfiles/firmware/Dockerfile.ubuntu
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ FROM alpine:3.12 as kernel-builder
LABEL maintainer "Bryan J Rodriguez <[email protected]>"

ARG UBUNTU_RELEASE=5.15.0-23-generic
ARG FIRMWARE=1.201.5_all
ARG FIRMWARE=1.187.32_all

RUN apk update && apk add --no-cache \
bash \
Expand All @@ -14,7 +14,7 @@ RUN apk update && apk add --no-cache \
rpm \
cpio \
binutils \
zstd
zstd

WORKDIR /build
RUN mkdir /out
Expand All @@ -26,11 +26,11 @@ RUN mkdir /out
RUN wget https://mirrors.edge.kernel.org/ubuntu/pool/main/l/linux-firmware/linux-firmware_${FIRMWARE}.deb

RUN ar x linux-firmware_${FIRMWARE}.deb && \
tar -xf data.tar.zst && \
tar -xf data.tar.xz && \
mv ./lib /out/

FROM scratch
ENTRYPOINT []
CMD []
WORKDIR /
COPY --from=kernel-builder /out/* /
COPY --from=kernel-builder /out/* /lib/
2 changes: 1 addition & 1 deletion dockerfiles/uos/prepInitrd.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ mkdir -p prep/ && \
cd prep/ && \
gunzip -c < ../uos-initrd.img | cpio -i -d && \
rsync -rtc ../files/ ./ && \
find . | cpio -H newc -o | gzip > ../uos-initrd.img && \
find . | cpio -H newc -o | pv | xz -T0 --check=crc32 > ../uos-initrd.img && \
cd - && \
rm -fr prep/
11 changes: 2 additions & 9 deletions scripts/buildUOS.sh
Original file line number Diff line number Diff line change
Expand Up @@ -128,15 +128,8 @@ else
"docker run -t --rm ${DOCKER_RUN_ARGS} -v /var/run/docker.sock:/var/run/docker.sock -v $(pwd):/uos builder-uos:${GIT_COMMIT} -c 'cd /uos && /usr/bin/linuxkit build -format kernel+initrd /uos/uos.yml'" \
../../${LOG_FILE}
fi
run "(7/12) Prepping initrd" \
"docker run -t --rm --privileged ${DOCKER_RUN_ARGS} -v $(pwd):/uos alpine:3.12 sh -c '\
apk update && apk add --no-cache \
bash \
cpio \
coreutils \
gzip \
rsync \
curl && \
run "(7/12) Prepping initrd (~10 min)" \
"docker run -t --rm --privileged ${DOCKER_RUN_ARGS} -v $(pwd):/uos builder-uos:${GIT_COMMIT} -c '\
cd /uos && \
./prepInitrd.sh 2>&1'" \
../../${LOG_FILE}
Expand Down
4 changes: 2 additions & 2 deletions scripts/fileutils.sh
Original file line number Diff line number Diff line change
Expand Up @@ -483,13 +483,13 @@ processEmbedded() {
-v ${WEB_PROFILE}/${profile_name}/embedded:/opt/profile_embedded \
-v ${EMBEDDED_FILES}/${profile_name}:/opt/embedded \
alpine:3.12 sh -c 'apk update && \
apk add rsync gzip && \
apk add rsync xz gzip && \
mkdir -p prep/ && \
cd prep/ && \
gunzip -c < /opt/images/initrd | cpio -i -d 2> /dev/null || true && \
rsync -rtc /opt/profile_embedded/ ./ && \
rsync -rtc /opt/embedded/ ./ && \
find . | cpio -H newc -o | gzip > /opt/images/initrd' \
find . | cpio -H newc -o | xz -T0 --check=crc32 > /opt/images/initrd' \
echo 'Finished with embedding files into uOS, Cleaning up build docker container...'; \
docker rm -f esp_embedding > /dev/null 2>&1 || true" \
${LOG_FILE}
Expand Down
Loading

0 comments on commit 7bcf956

Please sign in to comment.