mirror of
				https://github.com/dockur/windows.git
				synced 2025-11-04 06:15:27 +00:00 
			
		
		
		
	Compare commits
	
		
			No commits in common. "b7ad0d3d88212ef525c145bd0fe669e0b12a1b0b" and "a3a2b3fb095a080b9760e137edae47ff94a2ced3" have entirely different histories.
		
	
	
		
			b7ad0d3d88
			...
			a3a2b3fb09
		
	
		
@ -1,6 +1,6 @@
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
  "name": "windows",
 | 
					  "name": "windows",
 | 
				
			||||||
  "service": "windows",
 | 
					  "service": "windows",
 | 
				
			||||||
  "forwardPorts": [8006],
 | 
					  "forwardPorts": ["8006"],
 | 
				
			||||||
  "dockerComposeFile": "compose.yml"
 | 
					  "dockerComposeFile": "compose.yml"
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
@ -1,7 +1,7 @@
 | 
				
			|||||||
ARG VERSION_ARG="latest"
 | 
					ARG VERSION_ARG="latest"
 | 
				
			||||||
FROM scratch AS build-amd64
 | 
					FROM scratch AS build-amd64
 | 
				
			||||||
 | 
					
 | 
				
			||||||
COPY --from=qemux/qemu:7.02 / /
 | 
					COPY --from=qemux/qemu:7.01 / /
 | 
				
			||||||
 | 
					
 | 
				
			||||||
ARG DEBCONF_NOWARNINGS="yes"
 | 
					ARG DEBCONF_NOWARNINGS="yes"
 | 
				
			||||||
ARG DEBIAN_FRONTEND="noninteractive"
 | 
					ARG DEBIAN_FRONTEND="noninteractive"
 | 
				
			||||||
 | 
				
			|||||||
@ -1300,9 +1300,6 @@ prepareInstall() {
 | 
				
			|||||||
  [ -n "$PASSWORD" ] && password="$PASSWORD"
 | 
					  [ -n "$PASSWORD" ] && password="$PASSWORD"
 | 
				
			||||||
  [ -n "$USERNAME" ] && username=$(echo "$USERNAME" | sed 's/[^[:alnum:]@!._-]//g')
 | 
					  [ -n "$USERNAME" ] && username=$(echo "$USERNAME" | sed 's/[^[:alnum:]@!._-]//g')
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  local ip="20.20.20.1"
 | 
					 | 
				
			||||||
  [ -n "${VM_NET_IP:-}" ] && ip="${VM_NET_IP%.*}.1"
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # These are not pirated keys, they come from the official MS documentation.
 | 
					  # These are not pirated keys, they come from the official MS documentation.
 | 
				
			||||||
  if [[ "${driver,,}" == "xp" ]]; then
 | 
					  if [[ "${driver,,}" == "xp" ]]; then
 | 
				
			||||||
    if [[ "${arch,,}" == "x86" ]]; then
 | 
					    if [[ "${arch,,}" == "x86" ]]; then
 | 
				
			||||||
@ -1497,7 +1494,7 @@ prepareInstall() {
 | 
				
			|||||||
          echo "Set oFSO = CreateObject(\"Scripting.FileSystemObject\")"
 | 
					          echo "Set oFSO = CreateObject(\"Scripting.FileSystemObject\")"
 | 
				
			||||||
          echo "Set oHosts = oFSO.GetFile(\"C:\Windows\System32\drivers\etc\hosts\")"
 | 
					          echo "Set oHosts = oFSO.GetFile(\"C:\Windows\System32\drivers\etc\hosts\")"
 | 
				
			||||||
          echo "Set fileAPPEND = oFSO.OpenTextFile(\"C:\Windows\System32\drivers\etc\hosts\", 8, true)"
 | 
					          echo "Set fileAPPEND = oFSO.OpenTextFile(\"C:\Windows\System32\drivers\etc\hosts\", 8, true)"
 | 
				
			||||||
          echo "fileAPPEND.Write(\"$ip      host.lan\")"
 | 
					          echo "fileAPPEND.Write(\"${VM_NET_IP%.*}.1      host.lan\")"
 | 
				
			||||||
          echo "fileAPPEND.Close()"
 | 
					          echo "fileAPPEND.Close()"
 | 
				
			||||||
          echo ""
 | 
					          echo ""
 | 
				
			||||||
  } | unix2dos > "$dir/\$OEM\$/admin.vbs"
 | 
					  } | unix2dos > "$dir/\$OEM\$/admin.vbs"
 | 
				
			||||||
 | 
				
			|||||||
@ -628,9 +628,7 @@ updateXML() {
 | 
				
			|||||||
  local language="$2"
 | 
					  local language="$2"
 | 
				
			||||||
  local culture region user admin pass keyboard
 | 
					  local culture region user admin pass keyboard
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  if [ -n "${VM_NET_IP:-}" ]; then
 | 
					  sed -i "s/ 20.20.20.1 / ${VM_NET_IP%.*}.1 /g" "$asset"
 | 
				
			||||||
    sed -i "s/ 20.20.20.1 / ${VM_NET_IP%.*}.1 /g" "$asset"
 | 
					 | 
				
			||||||
  fi
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
  [ -z "$HEIGHT" ] && HEIGHT="720"
 | 
					  [ -z "$HEIGHT" ] && HEIGHT="720"
 | 
				
			||||||
  [ -z "$WIDTH" ] && WIDTH="1280"
 | 
					  [ -z "$WIDTH" ] && WIDTH="1280"
 | 
				
			||||||
 | 
				
			|||||||
@ -111,8 +111,14 @@ done
 | 
				
			|||||||
if ! smbd; then
 | 
					if ! smbd; then
 | 
				
			||||||
  error "Samba daemon failed to start!"
 | 
					  error "Samba daemon failed to start!"
 | 
				
			||||||
  smbd -i --debug-stdout || true
 | 
					  smbd -i --debug-stdout || true
 | 
				
			||||||
 | 
					else
 | 
				
			||||||
 | 
					  if [[ "${NETWORK,,}" == "user"* ]]; then
 | 
				
			||||||
 | 
					    NET_OPTS="${NET_OPTS/,hostfwd/,guestfwd=tcp:${VM_NET_IP%.*}.1:445-tcp:127.0.0.1:445,hostfwd}"
 | 
				
			||||||
 | 
					  fi
 | 
				
			||||||
fi
 | 
					fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					[[ "${NETWORK,,}" == "user"* ]] && return 0
 | 
				
			||||||
 | 
					
 | 
				
			||||||
if [[ "${BOOT_MODE:-}" == "windows_legacy" ]]; then
 | 
					if [[ "${BOOT_MODE:-}" == "windows_legacy" ]]; then
 | 
				
			||||||
  # Enable NetBIOS on Windows 7 and lower
 | 
					  # Enable NetBIOS on Windows 7 and lower
 | 
				
			||||||
  if ! nmbd; then
 | 
					  if ! nmbd; then
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user