-
-
Notifications
You must be signed in to change notification settings - Fork 159
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(dev): make iso just commands work (#1287)
- Loading branch information
Showing
6 changed files
with
126 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
*.iso | ||
*_flatpaks/flatpaks_with_deps | ||
*.iso-CHECKSUM | ||
flatpaks_with_deps | ||
flatpak.* | ||
|
||
scripts/files/home/ublue-os/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
#!/usr/bin/bash | ||
if [[ -z ${project_root} ]]; then | ||
project_root=$(git rev-parse --show-toplevel) | ||
fi | ||
set -eo pipefail | ||
|
||
# Get Inputs | ||
image=$1 | ||
target=$2 | ||
version=$3 | ||
|
||
# Get image/target/version based on inputs | ||
# shellcheck disable=SC2154,SC1091 | ||
. "${project_root}/scripts/get-defaults.sh" | ||
|
||
# Get variables | ||
container_mgr=$(just _container_mgr) | ||
tag=$(just _tag "${image}" "${target}") | ||
|
||
#check if ISO exists. Create if it doesn't | ||
if [[ ! -f "${project_root}/scripts/files/output/${tag}-${version}.iso" ]]; then | ||
just build-iso "$image" "$target" "$version" | ||
fi | ||
|
||
workspace=${project_root} | ||
if [[ -f /.dockerenv ]]; then | ||
workspace=${LOCAL_WORKSPACE_FOLDER} | ||
fi | ||
|
||
${container_mgr} run --rm --cap-add NET_ADMIN \ | ||
--publish 127.0.0.1:8006:8006 \ | ||
--env "DISK_SIZE=50G" \ | ||
--env "BOOT_MODE=uefi" \ | ||
--device=/dev/kvm \ | ||
--volume "${workspace}/scripts/files/output/${tag}-${version}.iso":/boot.iso \ | ||
docker.io/qemux/qemu-docker |