diff --git a/tinyipa/build-instance-images.sh b/tinyipa/build-instance-images.sh index 1203771..0fd0221 100755 --- a/tinyipa/build-instance-images.sh +++ b/tinyipa/build-instance-images.sh @@ -19,6 +19,9 @@ sudo mount -o loop "$PARTIMG" "$DST_DIR/" setup_tce $DST_DIR +# NOTE(rpittau) change ownership of the tce info dir to prevent writing issues +sudo chown $TC:$STAFF $DST_DIR/usr/local/tce.installed + $TC_CHROOT_CMD tce-load -wci grub2-multi.tcz cleanup_tce $DST_DIR diff --git a/tinyipa/build-tinyipa.sh b/tinyipa/build-tinyipa.sh index b9b0f8a..d14f8f2 100755 --- a/tinyipa/build-tinyipa.sh +++ b/tinyipa/build-tinyipa.sh @@ -167,6 +167,9 @@ if [[ $USE_PYTHON3 == "True" ]]; then PY_REQS="buildreqs_python3.lst" fi +# NOTE(rpittau) change ownership of the tce info dir to prevent writing issues +sudo chown $TC:$STAFF $BUILDDIR/usr/local/tce.installed + while read line; do sudo chroot --userspec=$TC:$STAFF $BUILDDIR /usr/bin/env -i PATH=$CHROOT_PATH http_proxy=$http_proxy https_proxy=$https_proxy no_proxy=$no_proxy tce-load -wci $line done < <(paste $WORKDIR/build_files/$PY_REQS $WORKDIR/build_files/buildreqs.lst) diff --git a/tinyipa/finalise-tinyipa.sh b/tinyipa/finalise-tinyipa.sh index 87e75eb..1b4e319 100755 --- a/tinyipa/finalise-tinyipa.sh +++ b/tinyipa/finalise-tinyipa.sh @@ -99,6 +99,9 @@ if [[ $USE_PYTHON3 == "True" ]]; then PY_REQS="finalreqs_python3.lst" fi +# NOTE(rpittau) change ownership of the tce info dir to prevent writing issues +sudo chown $TC:$STAFF $FINALDIR/usr/local/tce.installed + while read line; do $TC_CHROOT_CMD tce-load -wic $line done < <(paste $WORKDIR/build_files/finalreqs.lst $WORKDIR/build_files/$PY_REQS)