Skip to content
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

Add option to install /usr/share/zoneinfo data #115

Merged
merged 1 commit into from
Dec 25, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions edition/min
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,5 @@ export LIMA_INSTALL_NERDCTL_FULL=false
export LIMA_INSTALL_OPENSSH_SFTP_SERVER=false
export LIMA_INSTALL_SSHFS=false
export LIMA_INSTALL_TINI=false
export LIMA_INSTALL_TZDATA=false
export LIMA_INSTALL_ZSTD=false
1 change: 1 addition & 0 deletions edition/std
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@ LIMA_INSTALL_LOGROTATE=true
LIMA_INSTALL_OPENSSH_SFTP_SERVER=true
LIMA_INSTALL_SSHFS=true
LIMA_INSTALL_TINI=true
LIMA_INSTALL_TZDATA=true
4 changes: 4 additions & 0 deletions genapkovl-lima.sh
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,10 @@ if [ "${LIMA_INSTALL_TINI}" == "true" ]; then
ln -sf /sbin/tini-static "$tmp"/usr/bin/tini
fi

if [ "${LIMA_INSTALL_TZDATA}" == "true" ]; then
echo tzdata >> "$tmp"/etc/apk/world
fi

if [ "${LIMA_INSTALL_CRI_DOCKERD}" == "true" ]; then
mkdir -p "${tmp}/cri-dockerd"
tar xz -C "${tmp}/cri-dockerd" -f /home/build/cri-dockerd.tar.gz
Expand Down
8 changes: 8 additions & 0 deletions lima-init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,14 @@ while read -r line; do export "$line"; done <"${LIMA_CIDATA_MNT}"/lima.env
LIMA_CIDATA_HOSTNAME="$(awk '/^local-hostname:/ {print $2}' "${LIMA_CIDATA_MNT}"/meta-data)"
hostname "${LIMA_CIDATA_HOSTNAME}"

# Set timezone
LIMA_CIDATA_TIMEZONE="$(awk '/^timezone:/ {print $2}' "${LIMA_CIDATA_MNT}"/user-data)"
if [ -n "${LIMA_CIDATA_TIMEZONE}" ]; then
if setup-timezone "${LIMA_CIDATA_TIMEZONE}"; then
echo "${LIMA_CIDATA_TIMEZONE}" >/etc/timezone
fi
fi

# Create user
LIMA_CIDATA_HOMEDIR="/home/${LIMA_CIDATA_USER}.linux"
useradd --home-dir "${LIMA_CIDATA_HOMEDIR}" --create-home --uid "${LIMA_CIDATA_UID}" "${LIMA_CIDATA_USER}"
Expand Down
3 changes: 3 additions & 0 deletions mkimg.lima.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ profile_lima() {
if [ "${LIMA_INSTALL_IPTABLES}" == "true" ] || [ "${LIMA_INSTALL_NERDCTL_FULL}" == "true" ]; then
apks="$apks iptables ip6tables"
fi
if [ "${LIMA_INSTALL_TZDATA}" == "true" ]; then
apks="$apks tzdata"
fi
if [ "${LIMA_INSTALL_ZSTD}" == "true" ]; then
apks="$apks zstd"
fi
Expand Down
Loading