Skip to content

Commit

Permalink
Add xz images to automatic image detection in base module config
Browse files Browse the repository at this point in the history
  • Loading branch information
pablosproject committed Apr 13, 2022
1 parent 47fc3fd commit fbed8fc
Showing 1 changed file with 17 additions and 17 deletions.
34 changes: 17 additions & 17 deletions src/modules/base/config
Original file line number Diff line number Diff line change
Expand Up @@ -17,24 +17,24 @@ BASE_VERSION=1.5.0

# Note: Set BASE_ZIP_IMG relative to the distro/src/workspace directory to pass a custom named file or an already extracted '.img'-file.
if [ "${BASE_DISTRO}" == "ubuntu" ]; then
# Default image ubuntu
[ -n "$BASE_ZIP_IMG" ] || BASE_ZIP_IMG=`ls -t $BASE_IMAGE_PATH/ubuntu-*.xz | head -n 1`
# Default user ubuntu
[ -n "$BASE_USER" ] || BASE_USER=ubuntu

# Add base user if does not exist
[ -n "$BASE_ADD_USER" ] || BASE_ADD_USER=yes
# When adding a base user which password to use
[ -n "$BASE_USER_PASSWORD" ] || BASE_USER_PASSWORD=ubuntu
elif [ "${BASE_DISTRO}" == "raspios64" ]; then
[ -n "$BASE_ZIP_IMG" ] || BASE_ZIP_IMG=`ls -t $BASE_IMAGE_PATH/*-{raspbian,raspios}-*-arm64-*.zip | head -n 1`
[ -n "$BASE_ADD_USER" ] || BASE_ADD_USER=no
# Default image ubuntu
[ -n "$BASE_ZIP_IMG" ] || BASE_ZIP_IMG=`ls -t $BASE_IMAGE_PATH/ubuntu-*.xz | head -n 1`
# Default user ubuntu
[ -n "$BASE_USER" ] || BASE_USER=ubuntu
# Add base user if does not exist
[ -n "$BASE_ADD_USER" ] || BASE_ADD_USER=yes
# When adding a base user which password to use
[ -n "$BASE_USER_PASSWORD" ] || BASE_USER_PASSWORD=ubuntu
elif [ "${BASE_DISTRO}" == "raspios64" ]; then
[ -n "$BASE_ZIP_IMG" ] || BASE_ZIP_IMG=`ls -t $BASE_IMAGE_PATH/*-{raspbian,raspios}-*-arm64-*.{zip,7z,xz} | head -n 1`
[ -n "$BASE_ADD_USER" ] || BASE_ADD_USER=no
else
# Default image raspbian
[ -n "$BASE_ZIP_IMG" ] || BASE_ZIP_IMG=`ls -t $BASE_IMAGE_PATH/*-{raspbian,raspios}*.zip | head -n 1`
# Default user raspbian
[ -n "$BASE_USER" ] || BASE_USER=pi
[ -n "$BASE_ADD_USER" ] || BASE_ADD_USER=no
# Default image raspbian
[ -n "$BASE_ZIP_IMG" ] || BASE_ZIP_IMG=`ls -t $BASE_IMAGE_PATH/*-{raspbian,raspios}*.{zip,7z,xz} | head -n 1`
# Default user raspbian
[ -n "$BASE_USER" ] || BASE_USER=pi
[ -n "$BASE_ADD_USER" ] || BASE_ADD_USER=no
fi

# Release compression
Expand Down

3 comments on commit fbed8fc

@guysoft
Copy link
Owner

@guysoft guysoft commented on fbed8fc Oct 25, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@pablosproject
There was a bug here that 64bit was not acting like 32bit, see: 91bdb6d

@pablosproject
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😞 thanks for notifying

@guysoft
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No worries.

  1. Every version has a bug
  2. Every bugfix is a new version 😉

Please sign in to comment.