fix: Apple Account sign-in on Sequoia (#426)

This commit is contained in:
Kroese
2026-06-06 09:00:02 +02:00
committed by GitHub
parent c2c6181853
commit 9b5f5baca4
8 changed files with 1445 additions and 1875 deletions
+7 -3
View File
@@ -15,10 +15,12 @@ FROM scratch AS runner
COPY --from=qemux/qemu:7.32 / /
ARG VERSION_ARG="0.0"
ARG VERSION_KVM_OPENCORE="v21"
ARG VERSION_VM_HIDE="2.0.0"
ARG VERSION_KVM_OPENCORE="0.7"
ARG VERSION_OSX_KVM="326053dd61f49375d5dfb28ee715d38b04b5cd8e"
ARG REPO_VM_HIDE="https://github.com/Carnations-Botanica/VMHide"
ARG REPO_KVM_OPENCORE="https://github.com/LongQT-sea/OpenCore-ISO"
ARG REPO_OSX_KVM="https://raw.githubusercontent.com/kholia/OSX-KVM"
ARG REPO_KVM_OPENCORE="https://github.com/thenickdude/KVM-Opencore"
ARG DEBCONF_NOWARNINGS="yes"
ARG DEBIAN_FRONTEND="noninteractive"
@@ -27,6 +29,7 @@ ARG DEBCONF_NONINTERACTIVE_SEEN="true"
RUN set -eu && \
apt-get update && \
apt-get --no-install-recommends -y install \
7zip \
mtools && \
apt-get clean && \
echo "$VERSION_ARG" > /etc/version && \
@@ -42,7 +45,8 @@ ADD --chmod=644 \
$REPO_OSX_KVM/$VERSION_OSX_KVM/OVMF_VARS-1024x768.fd \
$REPO_OSX_KVM/$VERSION_OSX_KVM/OVMF_VARS-1920x1080.fd /usr/share/OVMF/
ADD $REPO_KVM_OPENCORE/releases/download/$VERSION_KVM_OPENCORE/OpenCore-$VERSION_KVM_OPENCORE.iso.gz /opencore.iso.gz
ADD $REPO_VM_HIDE/releases/download/$VERSION_VM_HIDE/VMHide-$VERSION_VM_HIDE-RELEASE.zip /vmh.zip
ADD $REPO_KVM_OPENCORE/releases/download/v$VERSION_KVM_OPENCORE/LongQT-OpenCore-v$VERSION_KVM_OPENCORE.iso /opencore.iso
VOLUME /storage
EXPOSE 5900 8006
+1401 -1851
View File
File diff suppressed because it is too large Load Diff
+1 -1
View File
@@ -3,7 +3,7 @@ services:
image: dockurr/macos
container_name: macos
environment:
VERSION: "14"
VERSION: "15"
devices:
- /dev/kvm
- /dev/net/tun
+1 -1
View File
@@ -31,7 +31,7 @@ spec:
image: dockurr/macos
env:
- name: VERSION
value: "14"
value: "15"
- name: DISK_SIZE
value: "64G"
ports:
+3 -3
View File
@@ -30,7 +30,7 @@ services:
image: dockurr/macos
container_name: macos
environment:
VERSION: "14"
VERSION: "15"
devices:
- /dev/kvm
- /dev/net/tun
@@ -90,7 +90,7 @@ kubectl apply -f https://raw.githubusercontent.com/dockur/macos/refs/heads/maste
### How do I select the version of macOS?
By default, macOS 14 (Sonoma) will be installed, but you can add the `VERSION` environment variable in order to specify an alternative:
By default, macOS 15 (Sequoia) will be installed, but you can add the `VERSION` environment variable in order to specify an alternative:
```yaml
environment:
@@ -108,7 +108,7 @@ kubectl apply -f https://raw.githubusercontent.com/dockur/macos/refs/heads/maste
| `11` | macOS 11 | Big Sur |
> [!NOTE]
> Starting with macOS 15 (Sequoia), you cannot sign in to an Apple Account unless you install [VMHide.kext](https://github.com/Carnations-Botanica/VMHide) first.
> You can also select macOS 26 (Tahoe), but beware that it runs very slow currently.
### How do I change the storage location?
+28 -14
View File
@@ -87,36 +87,50 @@ if [ ! -f "$IMG" ]; then
rm -rf "$OUT"
mkdir -p "$OUT"
msg="Building boot image"
msg="Building OpenCore boot image"
info "$msg..." && html "$msg..."
[ ! -f "$ISO" ] && gzip -dk "$ISO.gz"
if [ ! -f "$ISO" ] || [ ! -s "$ISO" ]; then
# Extract image file
if [ ! -s "$ISO" ]; then
error "Could not find image file \"$ISO\"." && exit 10
fi
START=$(sfdisk -l "$ISO" | grep -i -m 1 "EFI System" | awk '{print $2}')
mcopy -bspmQ -i "$ISO@@${START}S" ::EFI "$OUT"
if ! 7z x "$ISO" -o"$OUT" > /dev/null; then
error "Failed to extract archive!" && exit 11
fi
CFG="$OUT/EFI/OC/config.plist"
# Overwrite extracted OpenCore config with our own
CFG="$(find "$OUT" -type f -path '*/EFI/OC/config.plist' -print -quit)"
[ -z "${CFG:-}" ] && error "Could not locate extracted OpenCore config.plist under \"$OUT\"." && exit 12
EFI_DIR="${CFG%/OC/config.plist}"
PLIST="/assets/config.plist"
[ -f "/config.plist" ] && PLIST="/config.plist"
[ -f "/custom.plist" ] && PLIST="/custom.plist"
cp "$PLIST" "$CFG"
# Replace placeholders with machine details
ROM="${MAC//[^[:alnum:]]/}"
ROM="${ROM,,}"
BROM=$(echo "$ROM" | xxd -r -p | base64)
RESOLUTION="${WIDTH}x${HEIGHT}@32"
sed -r -i -e 's|<data>m7zhIYfl</data>|<data>'"${BROM}"'</data>|g' "$CFG"
sed -r -i -e 's|<string>iMacPro1,1</string>|<string>'"${MODEL}"'</string>|g' "$CFG"
sed -r -i -e 's|<string>C02TM2ZBHX87</string>|<string>'"${SN}"'</string>|g' "$CFG"
sed -r -i -e 's|<string>C02717306J9JG361M</string>|<string>'"${MLB}"'</string>|g' "$CFG"
sed -r -i -e 's|<data>ESIzRFVm</data>|<data>'"${BROM}"'</data>|g' "$CFG"
sed -r -i -e 's|<string>iMac19,1</string>|<string>'"${MODEL}"'</string>|g' "$CFG"
sed -r -i -e 's|<string>W00000000001</string>|<string>'"${SN}"'</string>|g' "$CFG"
sed -r -i -e 's|<string>M0000000000000001</string>|<string>'"${MLB}"'</string>|g' "$CFG"
sed -r -i -e 's|<string>1920x1080@32</string>|<string>'"${RESOLUTION}"'</string>|g' "$CFG"
sed -r -i -e 's|<string>007076A6-F2A2-4461-BBE5-BAD019F8025A</string>|<string>'"${UUID}"'</string>|g' "$CFG"
sed -r -i -e 's|<string>00000000-0000-0000-0000-000000000000</string>|<string>'"${UUID}"'</string>|g' "$CFG"
# Add kext to disable VM detection
kexts="$EFI_DIR/OC/Kexts"
if ! 7z x /vmh.zip -o"$OUT/kext" > /dev/null; then
error "Failed to extract kext archive!" && exit 11
fi
mv "$OUT/kext/VMHide.kext" "$kexts"
rm -rf "$OUT/kext"
# Build image
@@ -155,7 +169,7 @@ if [ ! -f "$IMG" ]; then
echo "drive c: file=\"$IMG\" partition=0 offset=$OFFSET" > /etc/mtools.conf
mformat -F -M "$SECTOR" -c "$CLUSTER" -T "$COUNT" -v "EFI" "C:"
mcopy -bspmQ "$OUT/EFI" "C:"
mcopy -bspmQ "$EFI_DIR" "C:"
rm -rf "$OUT"
+2
View File
@@ -3,6 +3,8 @@ set -Eeuo pipefail
: "${APP:="macOS"}"
: "${VGA:="vmware"}"
: "${SHUTDOWN:="Y"}"
: "${TIMEOUT:="115"}"
: "${PLATFORM:="x64"}"
: "${DISK_TYPE:="blk"}"
: "${SUPPORT:="https://github.com/dockur/macos"}"
+2 -2
View File
@@ -169,7 +169,7 @@ install() {
fi
local file="$STORAGE/boot.dmg"
if ! download "$file" "$board" "$version"; then
delay 5
if ! download "$file" "$board" "$version"; then
@@ -212,7 +212,7 @@ generateAddress() {
# Generate Apple MAC address based on Docker container ID in hostname
MAC=$(echo "$HOST" | md5sum | sed 's/^\(..\)\(..\)\(..\)\(..\)\(..\).*$/00:16:cb:\3:\4:\5/')
MAC="${MAC^^}"
MAC="${MAC^^}"
echo "$MAC" > "$file"
! setOwner "$file" && error "Failed to set the owner for \"$file\" !"