Skip to content

Commit a1994c4

Browse files
committed
Merge remote-tracking branch 'main' into development
2 parents ee23397 + efddba1 commit a1994c4

2 files changed

Lines changed: 15 additions & 4 deletions

File tree

‎image-factory/create_image.sh‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ IMAGE="/output/image.img"
2323
IMAGE_QCOW="/output/image.qcow2"
2424
#SIZE_MB=2048
2525
SIZE_MB=4096
26+
SIZE_MB=1636
2627

2728
PARTITION="B"
2829

‎image-factory/start.sh‎

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@ raise() {
99
exit 1
1010
}
1111

12-
VERSION="${1:-"latest"}"
13-
BUILDER_IMAGE="cuos-image-factory"
14-
1512
dockerlogin() {
1613
## docker login:
1714
UPDATE_REGISTRY="$(jq -r '.update_registry' "${CONFIG_PATH}")"
@@ -38,11 +35,24 @@ dockerlogin() {
3835
fi
3936
}
4037

38+
export LOCAL_CONFIG_PATH="$1"
39+
if [[ ! -f "${LOCAL_CONFIG_PATH}" ]]; then
40+
echo "Config file not found."
41+
exit 1
42+
fi
43+
mkdir -p "${SCRIPT_DIR}/../output/"
44+
cp "${LOCAL_CONFIG_PATH}" "${CONFIG_PATH}"
45+
46+
4147
if [[ ! -f "${CONFIG_PATH}" ]]; then
4248
echo "Config file not found: ${CONFIG_PATH}"
4349
exit 1
4450
fi
4551

52+
VERSION="${2:-"latest"}"
53+
BUILDER_IMAGE="cuos-image-factory"
54+
55+
4656
dockerlogin
4757

4858
if [[ "${VERSION}" == "build" ]]; then
@@ -61,6 +71,6 @@ docker run --rm \
6171
--network=host \
6272
--privileged \
6373
-v "${HOME}/.docker/config.json":/root/.docker/config.json:ro \
64-
-v "${PWD}/../output/:/output/" \
74+
-v "${SCRIPT_DIR}/../output/:/output/" \
6575
--name dockerboot-imagebuilder-container \
6676
"${IMAGE}"

0 commit comments

Comments
 (0)