-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
setup_board, update_chroot, dev container: use new bincache mirror #159
Conversation
setup_board
Outdated
@@ -27,8 +27,10 @@ DEFINE_boolean getbinpkg "${FLAGS_TRUE}" \ | |||
"Download binary packages from remote repository." | |||
DEFINE_string getbinpkgver "" \ | |||
"Use binary packages from a specific version." | |||
|
|||
get_board_and_variant $FLAGS_board $FLAGS_variant |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FLAGS_board
and FLAGS_variant
are not yet evaluated at this point, no? It happens below, after the line with # Parse command line flags
, I think.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
True. Currently it only outputs the defaults. Since get_board_and_variant
is only called to populate BOARD
for the succeeding help text I'll just change the help text and remove get_board_and_variant
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The BOARD variable is used below also for other things, so I don't think get_board_and_variant
call should be completely removed. Just called after the flags are evaluated, like it used to be.
fbb7d57
to
3649ca5
Compare
setup_board
Outdated
@@ -149,7 +149,6 @@ if [[ "${FLAGS_usepkgonly}" -eq "${FLAGS_TRUE}" ]]; then | |||
done | |||
fi | |||
|
|||
get_board_and_variant $FLAGS_board $FLAGS_variant |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But this should stay, I think. Otherwise BOARD, VARIANT and BOARD_VARIANT will not be initialized.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh no I removed it entirely instead of moving it back where it was :-/ Will fix.
This updates the default settings in build scripts to use https://mirror.release.flatcar-linux.net/ instead of the google storage bucket if no binhost or FLATCAR_DEV_BUILDS is specified. Defaults are updated for * update_chroot (runs at SDK initialisation time) * setup_board (creates /boards/[ARCH]/) chroots * the development container * set_version
3649ca5
to
51aac23
Compare
build_library/dev_container_util.sh
Outdated
if [ "${image_group}" == "developer" ]; then | ||
echo "https://storage.googleapis.com/flatcar-jenkins/${image_group}/boards/${BOARD}/${FLATCAR_VERSION}/${image_path}" | ||
echo "${FLATCAR_DEV_BUILDS}/${image_group}/boards/${BOARD}/${FLATCAR_VERSION}/${image_path}" | ||
else | ||
echo "https://storage.googleapis.com/flatcar-jenkins/boards/${BOARD}/${FLATCAR_VERSION_ID}/${image_path}" | ||
echo "${FLATCAR_DEV_BUILDS}/boards/${BOARD}/${FLATCAR_VERSION_ID}/${image_path}" | ||
fi |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thinking about it, this won't work in the CI. The CI will set FLATCAR_DEV_BUILDS
to a custom value (the private google bucket) so the official mirror will not be used when the dev container is built via CI.
I'll introduce a command line option to build_image
to set the dev container's binhost.
Signed-off-by: Thilo Fromm <[email protected]>
OK, I think we're good to go now. |
Co-authored-by: Kai Lüke <[email protected]>
This updates the default settings in build scripts to use https://mirror.release.flatcar-linux.net/ instead of the google storage bucket if no binhost or FLATCAR_DEV_BUILDS is specified.
Defaults are updated for
Testing done
./update_chroot
with and withoutFLATCAR_DEV_BUILDS
set, verified thathttps://mirror.release.flatcar-linux.net/
is used by default, the URL inFLATCAR_DEV_BUILDS
otherwise./setup_board
with and withoutFLATCAR_DEV_BUILDS
set, same as above./build_packages
and verifyhttps://mirror.release.flatcar-linux.net/
is used as bincache./build image prodtar container
and verify dev container useshttps://mirror.release.flatcar-linux.net/