mirror of
https://github.com/dockur/windows.git
synced 2026-10-09 02:44:34 +01:00
Compare commits
326
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c8ff794df9 | ||
|
|
013ea27498 | ||
|
|
8fa0dacad0 | ||
|
|
ddd1785881 | ||
|
|
4ad4d9b121 | ||
|
|
9937f3b7e4 | ||
|
|
f444ddecc4 | ||
|
|
1e99833c8f | ||
|
|
c504d7c144 | ||
|
|
792ff0d7ec | ||
|
|
e0026b432d | ||
|
|
3dfc86cb47 | ||
|
|
ef4094039a | ||
|
|
a448c81b97 | ||
|
|
d0a910707e | ||
|
|
220bdf5db1 | ||
|
|
aaa0cdffda | ||
|
|
4b64464292 | ||
|
|
f2f4d941a7 | ||
|
|
8ffeb98eb3 | ||
|
|
09ed611a7f | ||
|
|
66998948c3 | ||
|
|
27f5a75ec3 | ||
|
|
3ce2f2eace | ||
|
|
d66fa8714a | ||
|
|
262b2d4d7c | ||
|
|
cf3772768e | ||
|
|
874c5d5fa3 | ||
|
|
3c50cdd981 | ||
|
|
ed83980b1d | ||
|
|
91b7e8a9c1 | ||
|
|
4e57031200 | ||
|
|
efe47da76d | ||
|
|
2fe4645685 | ||
|
|
afa55b476c | ||
|
|
1e5d3c75a8 | ||
|
|
4c74370da0 | ||
|
|
ae9fa8716b | ||
|
|
0d84fd35f5 | ||
|
|
d68a489295 | ||
|
|
c86067cb6e | ||
|
|
37f4908f22 | ||
|
|
09627c4e51 | ||
|
|
f6e6a15b42 | ||
|
|
eeaf64bdd9 | ||
|
|
eb1befd90e | ||
|
|
afb28c9234 | ||
|
|
2a116bf655 | ||
|
|
9af2409510 | ||
|
|
6bfe3b1adc | ||
|
|
2904a8d932 | ||
|
|
e490d142ef | ||
|
|
2bf6ae55ab | ||
|
|
a0a4520be6 | ||
|
|
003d7da5db | ||
|
|
1c2efa65df | ||
|
|
00fe722d4e | ||
|
|
603bd079fc | ||
|
|
be032648e8 | ||
|
|
1d98f065dc | ||
|
|
a0822d00a7 | ||
|
|
8713fa50e1 | ||
|
|
e8028db237 | ||
|
|
e4b910fba3 | ||
|
|
1066895aca | ||
|
|
39862b25b5 | ||
|
|
a3461db9a8 | ||
|
|
019c70dbaa | ||
|
|
ffec37e758 | ||
|
|
e832e705f9 | ||
|
|
db6b085ae2 | ||
|
|
cf93c6d7f3 | ||
|
|
afce7af300 | ||
|
|
cfac963278 | ||
|
|
0d7e26adad | ||
|
|
9ef6f3c4ca | ||
|
|
5b9a376111 | ||
|
|
a4ae486d83 | ||
|
|
c9b12ba97d | ||
|
|
7e3e24780d | ||
|
|
433c83cab0 | ||
|
|
19264a42da | ||
|
|
33ae12677e | ||
|
|
133c3d3bc3 | ||
|
|
43be9024e9 | ||
|
|
9e87e1aefa | ||
|
|
2780b08a1f | ||
|
|
0da09cf633 | ||
|
|
6c4e167915 | ||
|
|
eb2207dff9 | ||
|
|
5c213770ad | ||
|
|
2170bc0f3c | ||
|
|
4ae04facfa | ||
|
|
0b76ed9744 | ||
|
|
221cf5ad73 | ||
|
|
e51c597821 | ||
|
|
be96767802 | ||
|
|
ff8c17ad04 | ||
|
|
b7ded137f8 | ||
|
|
543060fd95 | ||
|
|
84eabc07fb | ||
|
|
5f16a000d6 | ||
|
|
490501fba4 | ||
|
|
751fae1343 | ||
|
|
803377ac3c | ||
|
|
ed8dcea704 | ||
|
|
ffc9f02c83 | ||
|
|
6129e500bd | ||
|
|
248c9e9314 | ||
|
|
976c22fcc2 | ||
|
|
ef783b900b | ||
|
|
314c6c1fc1 | ||
|
|
0780a91124 | ||
|
|
c56cd3de18 | ||
|
|
43d0478f7e | ||
|
|
65fe8ada74 | ||
|
|
93cab3110d | ||
|
|
91326c9664 | ||
|
|
927f92282c | ||
|
|
2fc733b3f0 | ||
|
|
fd50523c7d | ||
|
|
446dae699b | ||
|
|
1cef71d265 | ||
|
|
54bf0ed8de | ||
|
|
8f5a6b0b85 | ||
|
|
528b82c60d | ||
|
|
565d7ef04b | ||
|
|
d8cb4816f6 | ||
|
|
4f70ba9e89 | ||
|
|
881bd0bc7f | ||
|
|
0d3206c973 | ||
|
|
4b39ed53ae | ||
|
|
32d887c741 | ||
|
|
8a009b6891 | ||
|
|
3aab9e97b5 | ||
|
|
617b26897d | ||
|
|
74275da920 | ||
|
|
1babe34333 | ||
|
|
fd5806105e | ||
|
|
9086a904aa | ||
|
|
f5c1a5c034 | ||
|
|
f7bebb2ae3 | ||
|
|
cae621ae2f | ||
|
|
38e8da4aa3 | ||
|
|
392b96a541 | ||
|
|
1d42488287 | ||
|
|
9c90ccc636 | ||
|
|
089d9dd98a | ||
|
|
b296a37d65 | ||
|
|
f8c72b3404 | ||
|
|
16c4ee0552 | ||
|
|
379867370a | ||
|
|
28792f32a1 | ||
|
|
c212e22073 | ||
|
|
2da8322dba | ||
|
|
6c5264d444 | ||
|
|
0c2dbdf98a | ||
|
|
9d01d237c2 | ||
|
|
919222ef25 | ||
|
|
cd8af5af51 | ||
|
|
b1e2cc47ac | ||
|
|
77902bd05b | ||
|
|
aa9584df90 | ||
|
|
2f7e3d1903 | ||
|
|
9a57ec3096 | ||
|
|
7645a2b34f | ||
|
|
3e45a97075 | ||
|
|
6a03ddff71 | ||
|
|
9e8c1d0dda | ||
|
|
59011680b5 | ||
|
|
033a06a3df | ||
|
|
f487122f80 | ||
|
|
45deb0c638 | ||
|
|
e94a3c203d | ||
|
|
7ec498e3f2 | ||
|
|
38e732ea79 | ||
|
|
f447eeddce | ||
|
|
6389212ca7 | ||
|
|
22091ceb67 | ||
|
|
5f6bf2a230 | ||
|
|
60705368ef | ||
|
|
45ba5317a7 | ||
|
|
69727e49dc | ||
|
|
a83e049f8b | ||
|
|
e3fb3bbe8e | ||
|
|
43d1f54806 | ||
|
|
b38b7b0953 | ||
|
|
0fdab89516 | ||
|
|
2488d5735b | ||
|
|
aa7ddb698c | ||
|
|
5eba2a5fed | ||
|
|
ee97b9d628 | ||
|
|
c36c36ca00 | ||
|
|
a6c1e4c8a5 | ||
|
|
5287b0ba85 | ||
|
|
f6fcb46958 | ||
|
|
4fdc3f0428 | ||
|
|
16f763912b | ||
|
|
e00d1aead1 | ||
|
|
78ba661605 | ||
|
|
bada80331d | ||
|
|
c589e1be18 | ||
|
|
2ac9d71b32 | ||
|
|
e7e637531e | ||
|
|
b90ded928b | ||
|
|
0d0dd7be87 | ||
|
|
5b080ac6c8 | ||
|
|
6df58b5dc7 | ||
|
|
8929f7cdcd | ||
|
|
aa6240ff99 | ||
|
|
3d3bab023d | ||
|
|
36d127d8cf | ||
|
|
2b7d7bf902 | ||
|
|
30d9858c7d | ||
|
|
09941ba0f6 | ||
|
|
828bdb1b29 | ||
|
|
c64cf2313b | ||
|
|
f45575c13f | ||
|
|
11b300149f | ||
|
|
605f31af72 | ||
|
|
4e35ead612 | ||
|
|
0a3bff5a7d | ||
|
|
fdad5260cf | ||
|
|
0728b3e0a8 | ||
|
|
184ab1c481 | ||
|
|
4cf7dc005b | ||
|
|
da7dd544b3 | ||
|
|
213245e5c9 | ||
|
|
240db47ae0 | ||
|
|
2ee0ae2e28 | ||
|
|
bc17fdfe74 | ||
|
|
3d9ede8852 | ||
|
|
66d51a23c6 | ||
|
|
6bdfb06827 | ||
|
|
ce1e7b877d | ||
|
|
d1b3364471 | ||
|
|
4b5eb2c882 | ||
|
|
fe36fe3ab8 | ||
|
|
c64467596b | ||
|
|
28b5ee1f08 | ||
|
|
173b67b2af | ||
|
|
b692649a4f | ||
|
|
b721ba2320 | ||
|
|
6bfe2ff106 | ||
|
|
c739e41e7e | ||
|
|
99ac4035c7 | ||
|
|
b656a8a57f | ||
|
|
7f1f5510d5 | ||
|
|
2515318f89 | ||
|
|
b310f56e78 | ||
|
|
c0a48b23c8 | ||
|
|
d3253830fe | ||
|
|
48150e7060 | ||
|
|
958d25d095 | ||
|
|
a1047a8deb | ||
|
|
b10e4d7fdc | ||
|
|
c2f73db036 | ||
|
|
742f0bddee | ||
|
|
603fe5e491 | ||
|
|
b1dc452ed2 | ||
|
|
21d628e924 | ||
|
|
ef5ce4ad65 | ||
|
|
377337a625 | ||
|
|
49135eb09e | ||
|
|
598ff994f6 | ||
|
|
ef49e7bb0b | ||
|
|
a831593327 | ||
|
|
da73600b14 | ||
|
|
1a698a3943 | ||
|
|
293166c428 | ||
|
|
f193dac580 | ||
|
|
c60aff232f | ||
|
|
4b9dbf8f1a | ||
|
|
31770bec44 | ||
|
|
43e209294f | ||
|
|
8bb131d4fe | ||
|
|
b6a160c19e | ||
|
|
9f87b3a69b | ||
|
|
28d83e8aab | ||
|
|
7996bacb39 | ||
|
|
520be36ed5 | ||
|
|
577be226fe | ||
|
|
c7514780c5 | ||
|
|
df5b0e639f | ||
|
|
12be0a7d77 | ||
|
|
e925d664d5 | ||
|
|
c888801f4d | ||
|
|
092800903c | ||
|
|
a67a6a26e8 | ||
|
|
d29cca7f51 | ||
|
|
f200781975 | ||
|
|
ee94f2c0ae | ||
|
|
bd147e236b | ||
|
|
2a24e1a4c7 | ||
|
|
421ba38b70 | ||
|
|
14b736567a | ||
|
|
4fb5ddd02f | ||
|
|
6233599f28 | ||
|
|
9409c06e32 | ||
|
|
c9e09156a5 | ||
|
|
5642d3e045 | ||
|
|
fbdcc7457c | ||
|
|
09bd2b2c4b | ||
|
|
05996b083b | ||
|
|
895d726b8b | ||
|
|
9caf1a9a3f | ||
|
|
59cba25705 | ||
|
|
19b354bccf | ||
|
|
810a53980f | ||
|
|
f997e81e81 | ||
|
|
11a16d34f8 | ||
|
|
2f70dbde3c | ||
|
|
6119201d93 | ||
|
|
bbe972d3e5 | ||
|
|
9e09567c73 | ||
|
|
378312cfa4 | ||
|
|
55ac87c0c4 | ||
|
|
d75ed28b35 | ||
|
|
ea19f2e5ed | ||
|
|
f0b3967927 | ||
|
|
3b2a26e303 | ||
|
|
463935baf2 | ||
|
|
50d5f4fc09 | ||
|
|
9421d31b91 | ||
|
|
7642a17b57 | ||
|
|
b1ff5da11a |
+2
-2
@@ -1,8 +1,8 @@
|
|||||||
{
|
{
|
||||||
"name": "Tiny11 Nano",
|
"name": "Windows ME",
|
||||||
"service": "windows",
|
"service": "windows",
|
||||||
"containerEnv": {
|
"containerEnv": {
|
||||||
"VERSION": "nano11"
|
"VERSION": "me"
|
||||||
},
|
},
|
||||||
"forwardPorts": [8006],
|
"forwardPorts": [8006],
|
||||||
"portsAttributes": {
|
"portsAttributes": {
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
{
|
||||||
|
"name": "Windows 98",
|
||||||
|
"service": "windows",
|
||||||
|
"containerEnv": {
|
||||||
|
"VERSION": "98"
|
||||||
|
},
|
||||||
|
"forwardPorts": [8006],
|
||||||
|
"portsAttributes": {
|
||||||
|
"8006": {
|
||||||
|
"label": "Web",
|
||||||
|
"onAutoForward": "notify"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"otherPortsAttributes": {
|
||||||
|
"onAutoForward": "ignore"
|
||||||
|
},
|
||||||
|
"dockerComposeFile": "../codespaces.yml",
|
||||||
|
"initializeCommand": "docker system prune --all --force"
|
||||||
|
}
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
{
|
||||||
|
"name": "Windows 95",
|
||||||
|
"service": "windows",
|
||||||
|
"containerEnv": {
|
||||||
|
"VERSION": "95"
|
||||||
|
},
|
||||||
|
"forwardPorts": [8006],
|
||||||
|
"portsAttributes": {
|
||||||
|
"8006": {
|
||||||
|
"label": "Web",
|
||||||
|
"onAutoForward": "notify"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"otherPortsAttributes": {
|
||||||
|
"onAutoForward": "ignore"
|
||||||
|
},
|
||||||
|
"dockerComposeFile": "../codespaces.yml",
|
||||||
|
"initializeCommand": "docker system prune --all --force"
|
||||||
|
}
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
{
|
||||||
|
"name": "Reactos",
|
||||||
|
"service": "windows",
|
||||||
|
"containerEnv": {
|
||||||
|
"VERSION": "reactos"
|
||||||
|
},
|
||||||
|
"forwardPorts": [8006],
|
||||||
|
"portsAttributes": {
|
||||||
|
"8006": {
|
||||||
|
"label": "Web",
|
||||||
|
"onAutoForward": "notify"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"otherPortsAttributes": {
|
||||||
|
"onAutoForward": "ignore"
|
||||||
|
},
|
||||||
|
"dockerComposeFile": "../codespaces.yml",
|
||||||
|
"initializeCommand": "docker system prune --all --force"
|
||||||
|
}
|
||||||
@@ -6,6 +6,7 @@ services:
|
|||||||
RAM_SIZE: "half"
|
RAM_SIZE: "half"
|
||||||
DISK_SIZE: "max"
|
DISK_SIZE: "max"
|
||||||
CPU_CORES: "max"
|
CPU_CORES: "max"
|
||||||
|
DISK_MINIMUM: "1G"
|
||||||
devices:
|
devices:
|
||||||
- /dev/kvm
|
- /dev/kvm
|
||||||
- /dev/net/tun
|
- /dev/net/tun
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
version: 2
|
version: 2
|
||||||
|
|
||||||
updates:
|
updates:
|
||||||
- package-ecosystem: docker
|
- package-ecosystem: docker
|
||||||
directory: /
|
directory: /
|
||||||
@@ -6,9 +7,15 @@ updates:
|
|||||||
interval: weekly
|
interval: weekly
|
||||||
cooldown:
|
cooldown:
|
||||||
default-days: 7
|
default-days: 7
|
||||||
|
|
||||||
- package-ecosystem: github-actions
|
- package-ecosystem: github-actions
|
||||||
directory: /
|
directory: /
|
||||||
schedule:
|
schedule:
|
||||||
interval: weekly
|
interval: weekly
|
||||||
cooldown:
|
cooldown:
|
||||||
default-days: 7
|
default-days: 7
|
||||||
|
ignore:
|
||||||
|
- dependency-name: "*"
|
||||||
|
update-types:
|
||||||
|
- version-update:semver-minor
|
||||||
|
- version-update:semver-patch
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 22 KiB |
@@ -1,5 +1,7 @@
|
|||||||
on: [workflow_call]
|
on: [workflow_call]
|
||||||
|
|
||||||
name: "Check"
|
name: "Check"
|
||||||
|
|
||||||
permissions: {}
|
permissions: {}
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
@@ -15,13 +17,19 @@ jobs:
|
|||||||
name: Run ShellCheck
|
name: Run ShellCheck
|
||||||
uses: ludeeus/action-shellcheck@master
|
uses: ludeeus/action-shellcheck@master
|
||||||
env:
|
env:
|
||||||
SHELLCHECK_OPTS: -x --source-path=src -e SC1091 -e SC2001 -e SC2002 -e SC2034 -e SC2064 -e SC2153 -e SC2317 -e SC2028
|
SHELLCHECK_OPTS: >-
|
||||||
|
-x
|
||||||
|
--source-path=src
|
||||||
|
-e SC1091
|
||||||
|
-e SC2034
|
||||||
|
-e SC2153
|
||||||
|
-e SC2317
|
||||||
-
|
-
|
||||||
name: Lint Dockerfile
|
name: Lint Dockerfile
|
||||||
uses: hadolint/hadolint-action@v3.3.0
|
uses: hadolint/hadolint-action@v3.5.0
|
||||||
with:
|
with:
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
ignore: DL3006,DL3008
|
ignore: DL3006,DL3008,DL3067
|
||||||
failure-threshold: warning
|
failure-threshold: warning
|
||||||
-
|
-
|
||||||
name: Validate XML
|
name: Validate XML
|
||||||
@@ -31,6 +39,4 @@ jobs:
|
|||||||
file-endings: ".xml"
|
file-endings: ".xml"
|
||||||
-
|
-
|
||||||
name: Validate JSON and YML files
|
name: Validate JSON and YML files
|
||||||
uses: GrantBirki/json-yaml-validate@v5.0.0
|
uses: GrantBirki/json-yaml-validate@v5
|
||||||
with:
|
|
||||||
yaml_exclude_regex: ".*\\kubernetes\\.yml$"
|
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
+205
-13
@@ -2,6 +2,8 @@ name: Links
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
schedule:
|
||||||
|
- cron: '0 0 * * *'
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: links
|
group: links
|
||||||
@@ -22,29 +24,156 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
-
|
-
|
||||||
name: Validate Links
|
name: Install aria2
|
||||||
|
run: |
|
||||||
|
if ! command -v aria2c > /dev/null; then
|
||||||
|
sudo apt-get update -qq
|
||||||
|
sudo apt-get install -qq --no-install-recommends -y aria2
|
||||||
|
fi
|
||||||
|
-
|
||||||
|
name: Validate all download mirrors
|
||||||
|
id: validate
|
||||||
run: |
|
run: |
|
||||||
errors=0
|
errors=0
|
||||||
count=0
|
tested=0
|
||||||
host=""
|
host=""
|
||||||
|
failed_links=""
|
||||||
|
failed_links_html=""
|
||||||
declare -A seen
|
declare -A seen
|
||||||
wget https://github.com/lwthiker/curl-impersonate/releases/download/v0.6.1/curl-impersonate-v0.6.1.x86_64-linux-gnu.tar.gz
|
|
||||||
tar -xzf curl-impersonate-v0.6.1.x86_64-linux-gnu.tar.gz
|
ignored_domains=(
|
||||||
sudo cp curl-impersonate-ff /usr/local/bin/
|
files.dog
|
||||||
|
)
|
||||||
|
|
||||||
check() {
|
check() {
|
||||||
local url="$1" http
|
local url="$1"
|
||||||
http=$(curl-impersonate-ff -sSL -o /dev/null -w "%{http_code}" --max-time 10 -I -- "$url" 2>&1) || http="000"
|
local agent="Mozilla/5.0 (X11; Linux x86_64; rv:154.0) Gecko/20100101 Firefox/154.0"
|
||||||
[[ "$http" == 2* ]] && return 0
|
local tmp output pid blocks bytes rc status delay
|
||||||
http=$(curl-impersonate-ff -sSL -o /dev/null -w "%{http_code}" --max-time 10 -r "0-0" -- "$url" 2>&1) || http="000"
|
local attempt=1
|
||||||
[[ "$http" == 2* ]]
|
local attempts=3
|
||||||
|
local start
|
||||||
|
|
||||||
|
tmp=$(mktemp -d)
|
||||||
|
|
||||||
|
while (( attempt <= attempts )); do
|
||||||
|
output="$tmp/aria2.log"
|
||||||
|
rm -f -- "$tmp/probe" "$tmp/probe.aria2" "$output"
|
||||||
|
start=$SECONDS
|
||||||
|
|
||||||
|
aria2c \
|
||||||
|
--no-conf=true \
|
||||||
|
--connect-timeout=30 \
|
||||||
|
--timeout=30 \
|
||||||
|
--max-tries=2 \
|
||||||
|
--retry-wait=2 \
|
||||||
|
--async-dns=false \
|
||||||
|
--follow-metalink=false \
|
||||||
|
--follow-torrent=false \
|
||||||
|
--user-agent="$agent" \
|
||||||
|
--split=4 \
|
||||||
|
--max-connection-per-server=4 \
|
||||||
|
--file-allocation=none \
|
||||||
|
--allow-overwrite=true \
|
||||||
|
--auto-file-renaming=false \
|
||||||
|
--continue=false \
|
||||||
|
--dir="$tmp" \
|
||||||
|
--out=probe \
|
||||||
|
--console-log-level=error \
|
||||||
|
--summary-interval=0 \
|
||||||
|
--download-result=hide \
|
||||||
|
--show-console-readout=false \
|
||||||
|
--enable-color=false \
|
||||||
|
-- "$url" > "$output" 2>&1 &
|
||||||
|
pid=$!
|
||||||
|
|
||||||
|
while kill -0 "$pid" 2>/dev/null; do
|
||||||
|
if [[ -f "$tmp/probe" ]]; then
|
||||||
|
blocks=$(stat -c '%b' "$tmp/probe" 2>/dev/null || echo 0)
|
||||||
|
bytes=$((blocks * 512))
|
||||||
|
|
||||||
|
if (( bytes >= 1048576 )); then
|
||||||
|
kill "$pid" 2>/dev/null || true
|
||||||
|
wait "$pid" 2>/dev/null || true
|
||||||
|
rm -rf -- "$tmp"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if (( SECONDS - start >= 60 )); then
|
||||||
|
kill "$pid" 2>/dev/null || true
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
|
||||||
|
sleep 0.2
|
||||||
|
done
|
||||||
|
|
||||||
|
if wait "$pid"; then
|
||||||
|
rc=0
|
||||||
|
else
|
||||||
|
rc=$?
|
||||||
|
fi
|
||||||
|
|
||||||
|
blocks=0
|
||||||
|
|
||||||
|
if [[ -f "$tmp/probe" ]]; then
|
||||||
|
blocks=$(stat -c '%b' "$tmp/probe" 2>/dev/null || echo 0)
|
||||||
|
fi
|
||||||
|
|
||||||
|
bytes=$((blocks * 512))
|
||||||
|
|
||||||
|
if (( bytes >= 1048576 || (rc == 0 && bytes > 0) )); then
|
||||||
|
rm -rf -- "$tmp"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
status=$(sed -n 's/.*status=\([0-9][0-9][0-9]\).*/\1/p' "$output" | tail -n 1)
|
||||||
|
|
||||||
|
if (( attempt < attempts )) && [[ "$status" == "429" || "$status" == 5?? ]]; then
|
||||||
|
delay=$((attempt * 15))
|
||||||
|
echo " HTTP ${status}, retrying in ${delay} seconds..." >&2
|
||||||
|
sleep "$delay"
|
||||||
|
attempt=$((attempt + 1))
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
|
sed 's/^/ /' "$output" >&2
|
||||||
|
echo " Downloaded bytes: $bytes" >&2
|
||||||
|
echo " aria2c exit status: $rc" >&2
|
||||||
|
rm -rf -- "$tmp"
|
||||||
|
return 1
|
||||||
|
done
|
||||||
|
|
||||||
|
rm -rf -- "$tmp"
|
||||||
|
return 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
isIgnoredDomain() {
|
||||||
|
local url="$1"
|
||||||
|
local domain ignored
|
||||||
|
|
||||||
|
domain="${url#*://}"
|
||||||
|
domain="${domain%%/*}"
|
||||||
|
domain="${domain%%:*}"
|
||||||
|
domain="${domain,,}"
|
||||||
|
|
||||||
|
for ignored in "${ignored_domains[@]}"; do
|
||||||
|
if [[ "$domain" == "$ignored" || "$domain" == *."$ignored" ]]; then
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
while IFS= read -r line; do
|
while IFS= read -r line; do
|
||||||
if [[ "$line" =~ ^[[:space:]]*local[[:space:]]+host=\"(https://[^\"]+)\" ]]; then
|
if [[ "$line" =~ ^[[:space:]]*local[[:space:]]+host=\"(https://[^\"]+)\" ]]; then
|
||||||
host="${BASH_REMATCH[1]%/}"
|
host="${BASH_REMATCH[1]%/}"
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
|
|
||||||
[[ "$line" =~ ^[[:space:]]*url=\"(.+)\" ]] || continue
|
[[ "$line" =~ ^[[:space:]]*url=\"(.+)\" ]] || continue
|
||||||
val="${BASH_REMATCH[1]#/}"
|
val="${BASH_REMATCH[1]#/}"
|
||||||
|
|
||||||
if [[ "$val" == https://* ]]; then
|
if [[ "$val" == https://* ]]; then
|
||||||
url="$val"
|
url="$val"
|
||||||
elif [[ -n "$host" ]]; then
|
elif [[ -n "$host" ]]; then
|
||||||
@@ -52,16 +181,79 @@ jobs:
|
|||||||
else
|
else
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
|
|
||||||
[[ -v seen[$url] ]] && continue
|
[[ -v seen[$url] ]] && continue
|
||||||
seen[$url]=1
|
seen[$url]=1
|
||||||
count=$((count + 1))
|
|
||||||
|
if isIgnoredDomain "$url"; then
|
||||||
|
echo "SKIP: $url"
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
|
tested=$((tested + 1))
|
||||||
|
|
||||||
if check "$url"; then
|
if check "$url"; then
|
||||||
echo " OK: $url"
|
echo " OK: $url"
|
||||||
else
|
else
|
||||||
echo "FAIL: $url"
|
echo "FAIL: $url"
|
||||||
errors=$((errors + 1))
|
errors=$((errors + 1))
|
||||||
|
failed_links+="$url"$'\n'
|
||||||
|
failed_links_html+="<li><a href=\"$url\">$url</a></li>"$'\n'
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
sleep 2
|
||||||
done < "src/define.sh"
|
done < "src/define.sh"
|
||||||
|
|
||||||
echo ""
|
echo ""
|
||||||
printf '%d/%d links valid\n' "$(( count - errors ))" "$count"
|
printf '%d/%d tested links valid\n' "$((tested - errors))" "$tested"
|
||||||
(( errors == 0 ))
|
|
||||||
|
if (( errors > 0 )); then
|
||||||
|
printf '%d blocking failure(s)\n' "$errors"
|
||||||
|
|
||||||
|
{
|
||||||
|
echo "failed=true"
|
||||||
|
echo "links<<EOF"
|
||||||
|
printf '%s' "$failed_links"
|
||||||
|
echo "EOF"
|
||||||
|
echo "html_links<<EOF"
|
||||||
|
printf '%s' "$failed_links_html"
|
||||||
|
echo "EOF"
|
||||||
|
} >> "$GITHUB_OUTPUT"
|
||||||
|
else
|
||||||
|
echo "failed=false" >> "$GITHUB_OUTPUT"
|
||||||
|
fi
|
||||||
|
-
|
||||||
|
name: Send mail
|
||||||
|
if: steps.validate.outputs.failed == 'true'
|
||||||
|
uses: action-pack/send-mail@v1
|
||||||
|
with:
|
||||||
|
to: ${{secrets.MAILTO}}
|
||||||
|
from: Github Actions <${{secrets.MAILTO}}>
|
||||||
|
connection_url: ${{secrets.MAIL_CONNECTION}}
|
||||||
|
subject: Mirror verification failed!
|
||||||
|
body: |
|
||||||
|
Mirror verification failed!
|
||||||
|
|
||||||
|
The following links failed:
|
||||||
|
|
||||||
|
${{ steps.validate.outputs.links }}
|
||||||
|
|
||||||
|
See https://github.com/${{ github.repository }}/actions for more information.
|
||||||
|
html_body: |
|
||||||
|
<p>Mirror verification failed!</p>
|
||||||
|
|
||||||
|
<p>The following links failed:</p>
|
||||||
|
|
||||||
|
<ul>
|
||||||
|
${{ steps.validate.outputs.html_links }}
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
See
|
||||||
|
<a href="https://github.com/${{ github.repository }}/actions">GitHub Actions</a>
|
||||||
|
for more information.
|
||||||
|
</p>
|
||||||
|
-
|
||||||
|
name: Fail workflow
|
||||||
|
if: always() && steps.validate.outputs.failed == 'true'
|
||||||
|
run: exit 1
|
||||||
|
|||||||
@@ -11,61 +11,4 @@ permissions:
|
|||||||
jobs:
|
jobs:
|
||||||
review:
|
review:
|
||||||
name: review
|
name: review
|
||||||
runs-on: ubuntu-latest
|
uses: action-pack/.github/.github/workflows/review.yml@master
|
||||||
steps:
|
|
||||||
-
|
|
||||||
name: Checkout
|
|
||||||
uses: actions/checkout@v7
|
|
||||||
- parallel:
|
|
||||||
-
|
|
||||||
name: Spelling
|
|
||||||
uses: reviewdog/action-misspell@v1
|
|
||||||
with:
|
|
||||||
locale: "US"
|
|
||||||
level: warning
|
|
||||||
pattern: |
|
|
||||||
*.md
|
|
||||||
*.sh
|
|
||||||
reporter: github-pr-review
|
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
-
|
|
||||||
name: Hadolint
|
|
||||||
uses: reviewdog/action-hadolint@v1
|
|
||||||
with:
|
|
||||||
level: warning
|
|
||||||
fail_level: error
|
|
||||||
reporter: github-pr-review
|
|
||||||
hadolint_ignore: DL3006 DL3008
|
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
-
|
|
||||||
name: YamlLint
|
|
||||||
uses: reviewdog/action-yamllint@v1
|
|
||||||
with:
|
|
||||||
level: warning
|
|
||||||
reporter: github-pr-review
|
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
-
|
|
||||||
name: ActionLint
|
|
||||||
uses: reviewdog/action-actionlint@v1
|
|
||||||
with:
|
|
||||||
level: warning
|
|
||||||
reporter: github-pr-review
|
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
-
|
|
||||||
name: Shellformat
|
|
||||||
uses: reviewdog/action-shfmt@v1
|
|
||||||
if: false
|
|
||||||
with:
|
|
||||||
level: warning
|
|
||||||
fail_on_error: "true"
|
|
||||||
shfmt_flags: "-i 2 -ci -bn"
|
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
-
|
|
||||||
name: Shellcheck
|
|
||||||
uses: reviewdog/action-shellcheck@v1
|
|
||||||
with:
|
|
||||||
level: warning
|
|
||||||
fail_level: error
|
|
||||||
reporter: github-pr-review
|
|
||||||
shellcheck_flags: -x -e SC1091 -e SC2001 -e SC2002 -e SC2034 -e SC2064 -e SC2153 -e SC2317 -e SC2028
|
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
|
|||||||
@@ -0,0 +1,64 @@
|
|||||||
|
name: Settings
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_call:
|
||||||
|
inputs:
|
||||||
|
name:
|
||||||
|
description: Display name for the Windows version
|
||||||
|
required: true
|
||||||
|
type: string
|
||||||
|
|
||||||
|
version:
|
||||||
|
description: VERSION value passed to the container
|
||||||
|
required: true
|
||||||
|
type: string
|
||||||
|
|
||||||
|
callback:
|
||||||
|
description: Guest script type
|
||||||
|
required: false
|
||||||
|
default: powershell
|
||||||
|
type: string
|
||||||
|
|
||||||
|
expected_caption:
|
||||||
|
description: Text expected in the Windows caption
|
||||||
|
required: true
|
||||||
|
type: string
|
||||||
|
|
||||||
|
expected_edition:
|
||||||
|
description: Expected Windows EditionID
|
||||||
|
required: false
|
||||||
|
default: ""
|
||||||
|
type: string
|
||||||
|
|
||||||
|
minimum_build:
|
||||||
|
description: Minimum acceptable Windows build number
|
||||||
|
required: true
|
||||||
|
type: number
|
||||||
|
|
||||||
|
platform:
|
||||||
|
description: Expected Windows platform
|
||||||
|
required: true
|
||||||
|
type: string
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
install:
|
||||||
|
name: ${{ inputs.name }}
|
||||||
|
uses: ./.github/workflows/install.yml
|
||||||
|
with:
|
||||||
|
name: ${{ inputs.name }}
|
||||||
|
version: ${{ inputs.version }}
|
||||||
|
callback: ${{ inputs.callback }}
|
||||||
|
enable_tunnel: false
|
||||||
|
tunnel_delay: 1800
|
||||||
|
kill_on_failure: true
|
||||||
|
install_timeout: 9000
|
||||||
|
reboot_timeout: 18000
|
||||||
|
minimum_reboots: 1
|
||||||
|
boot_loop_limit: 10
|
||||||
|
expected_caption: ${{ inputs.expected_caption }}
|
||||||
|
expected_edition: ${{ inputs.expected_edition }}
|
||||||
|
minimum_build: ${{ inputs.minimum_build }}
|
||||||
|
platform: ${{ inputs.platform }}
|
||||||
@@ -0,0 +1,272 @@
|
|||||||
|
name: Validation
|
||||||
|
|
||||||
|
on:
|
||||||
|
release:
|
||||||
|
types:
|
||||||
|
- published
|
||||||
|
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: validation-${{ github.ref }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
desktop:
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
- name: Windows 11 Pro
|
||||||
|
version: "11"
|
||||||
|
expected_caption: Windows 11
|
||||||
|
expected_edition: Professional
|
||||||
|
minimum_build: 22000
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows 11 LTSC
|
||||||
|
version: "11l"
|
||||||
|
expected_caption: Windows 11
|
||||||
|
expected_edition: EnterpriseS
|
||||||
|
minimum_build: 26100
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows 11 Enterprise
|
||||||
|
version: "11e"
|
||||||
|
expected_caption: Windows 11
|
||||||
|
expected_edition: Enterprise
|
||||||
|
minimum_build: 22000
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows 11 IoT
|
||||||
|
version: "11i"
|
||||||
|
expected_caption: Windows 11
|
||||||
|
expected_edition: IoTEnterpriseS
|
||||||
|
minimum_build: 26100
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows 10 Pro
|
||||||
|
version: "10"
|
||||||
|
expected_caption: Windows 10
|
||||||
|
expected_edition: Professional
|
||||||
|
minimum_build: 10240
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows 10 LTSC
|
||||||
|
version: "10l"
|
||||||
|
expected_caption: Windows 10
|
||||||
|
expected_edition: EnterpriseS
|
||||||
|
minimum_build: 17763
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows 10 Enterprise
|
||||||
|
version: "10e"
|
||||||
|
expected_caption: Windows 10
|
||||||
|
expected_edition: Enterprise
|
||||||
|
minimum_build: 10240
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows 10 IoT
|
||||||
|
version: "10i"
|
||||||
|
expected_caption: Windows 10
|
||||||
|
expected_edition: IoTEnterpriseS
|
||||||
|
minimum_build: 19044
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows 8.1 Enterprise
|
||||||
|
version: "8e"
|
||||||
|
expected_caption: Windows 8.1
|
||||||
|
expected_edition: Enterprise
|
||||||
|
minimum_build: 9600
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
name: ${{ matrix.name }}
|
||||||
|
uses: ./.github/workflows/settings.yml
|
||||||
|
with:
|
||||||
|
name: ${{ matrix.name }}
|
||||||
|
version: ${{ matrix.version }}
|
||||||
|
expected_caption: ${{ matrix.expected_caption }}
|
||||||
|
expected_edition: ${{ matrix.expected_edition }}
|
||||||
|
minimum_build: ${{ matrix.minimum_build }}
|
||||||
|
platform: ${{ matrix.platform }}
|
||||||
|
|
||||||
|
server:
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
- name: Windows Server 2025
|
||||||
|
version: "2025"
|
||||||
|
expected_caption: Windows Server 2025
|
||||||
|
minimum_build: 26100
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows Server 2022
|
||||||
|
version: "2022"
|
||||||
|
expected_caption: Windows Server 2022
|
||||||
|
minimum_build: 20348
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows Server 2019
|
||||||
|
version: "2019"
|
||||||
|
expected_caption: Windows Server 2019
|
||||||
|
minimum_build: 17763
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows Server 2016
|
||||||
|
version: "2016"
|
||||||
|
expected_caption: Windows Server 2016
|
||||||
|
minimum_build: 14393
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows Server 2012
|
||||||
|
version: "2012"
|
||||||
|
expected_caption: Windows Server 2012 R2
|
||||||
|
minimum_build: 9600
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
name: ${{ matrix.name }}
|
||||||
|
uses: ./.github/workflows/settings.yml
|
||||||
|
with:
|
||||||
|
name: ${{ matrix.name }}
|
||||||
|
version: ${{ matrix.version }}
|
||||||
|
expected_caption: ${{ matrix.expected_caption }}
|
||||||
|
minimum_build: ${{ matrix.minimum_build }}
|
||||||
|
platform: ${{ matrix.platform }}
|
||||||
|
|
||||||
|
legacy:
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
- name: Windows 7 x64
|
||||||
|
version: "7u"
|
||||||
|
expected_caption: Windows 7
|
||||||
|
minimum_build: 7601
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows 7 x86
|
||||||
|
version: "7x86"
|
||||||
|
expected_caption: Windows 7
|
||||||
|
minimum_build: 7601
|
||||||
|
platform: x86
|
||||||
|
|
||||||
|
- name: Windows Vista x64
|
||||||
|
version: "vu"
|
||||||
|
expected_caption: Windows Vista
|
||||||
|
minimum_build: 6002
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows Vista x86
|
||||||
|
version: "vistax86"
|
||||||
|
expected_caption: Windows Vista
|
||||||
|
minimum_build: 6002
|
||||||
|
platform: x86
|
||||||
|
|
||||||
|
- name: Windows XP x86
|
||||||
|
version: "xp"
|
||||||
|
expected_caption: Windows XP
|
||||||
|
minimum_build: 2600
|
||||||
|
platform: x86
|
||||||
|
|
||||||
|
- name: Windows XP x64
|
||||||
|
version: "xp64"
|
||||||
|
expected_caption: Windows XP
|
||||||
|
minimum_build: 3790
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows 2000
|
||||||
|
version: "2k"
|
||||||
|
expected_caption: Windows 2000
|
||||||
|
minimum_build: 2195
|
||||||
|
platform: x86
|
||||||
|
|
||||||
|
- name: Windows Server 2008
|
||||||
|
version: "2008"
|
||||||
|
expected_caption: Windows Server 2008 R2
|
||||||
|
minimum_build: 7601
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Windows Server 2003
|
||||||
|
version: "2003"
|
||||||
|
expected_caption: Windows Server 2003
|
||||||
|
minimum_build: 3790
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
name: ${{ matrix.name }}
|
||||||
|
uses: ./.github/workflows/settings.yml
|
||||||
|
with:
|
||||||
|
name: ${{ matrix.name }}
|
||||||
|
version: ${{ matrix.version }}
|
||||||
|
callback: legacy
|
||||||
|
expected_caption: ${{ matrix.expected_caption }}
|
||||||
|
minimum_build: ${{ matrix.minimum_build }}
|
||||||
|
platform: ${{ matrix.platform }}
|
||||||
|
|
||||||
|
win9x:
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
- name: Windows 95
|
||||||
|
version: "95"
|
||||||
|
expected_caption: Windows 95
|
||||||
|
minimum_build: 950
|
||||||
|
platform: x86
|
||||||
|
|
||||||
|
- name: Windows 98
|
||||||
|
version: "98"
|
||||||
|
expected_caption: Windows 98
|
||||||
|
minimum_build: 2222
|
||||||
|
platform: x86
|
||||||
|
|
||||||
|
- name: Windows ME
|
||||||
|
version: "me"
|
||||||
|
expected_caption: Windows Millennium
|
||||||
|
minimum_build: 3000
|
||||||
|
platform: x86
|
||||||
|
|
||||||
|
name: ${{ matrix.name }}
|
||||||
|
uses: ./.github/workflows/settings.yml
|
||||||
|
with:
|
||||||
|
name: ${{ matrix.name }}
|
||||||
|
version: ${{ matrix.version }}
|
||||||
|
callback: basic
|
||||||
|
expected_caption: ${{ matrix.expected_caption }}
|
||||||
|
minimum_build: ${{ matrix.minimum_build }}
|
||||||
|
platform: ${{ matrix.platform }}
|
||||||
|
|
||||||
|
tiny:
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
- name: Core 11
|
||||||
|
version: "core11"
|
||||||
|
expected_caption: Windows 11
|
||||||
|
minimum_build: 22000
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Tiny 11
|
||||||
|
version: "tiny11"
|
||||||
|
expected_caption: Windows 11
|
||||||
|
minimum_build: 22000
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
- name: Tiny 10
|
||||||
|
version: "tiny10"
|
||||||
|
expected_caption: Windows 10
|
||||||
|
minimum_build: 19041
|
||||||
|
platform: x64
|
||||||
|
|
||||||
|
name: ${{ matrix.name }}
|
||||||
|
uses: ./.github/workflows/settings.yml
|
||||||
|
with:
|
||||||
|
name: ${{ matrix.name }}
|
||||||
|
version: ${{ matrix.version }}
|
||||||
|
expected_caption: ${{ matrix.expected_caption }}
|
||||||
|
minimum_build: ${{ matrix.minimum_build }}
|
||||||
|
platform: ${{ matrix.platform }}
|
||||||
+267
@@ -1 +1,268 @@
|
|||||||
|
##############################
|
||||||
|
# Operating System Files
|
||||||
|
##############################
|
||||||
|
|
||||||
|
.DS_Store
|
||||||
|
.AppleDouble
|
||||||
|
.LSOverride
|
||||||
|
Thumbs.db
|
||||||
|
ehthumbs.db
|
||||||
|
Desktop.ini
|
||||||
|
Icon?
|
||||||
|
$RECYCLE.BIN/
|
||||||
|
.Spotlight-V100/
|
||||||
|
.Trashes/
|
||||||
|
.fseventsd
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# IDEs
|
||||||
|
##############################
|
||||||
|
|
||||||
|
.vscode/
|
||||||
|
.idea/
|
||||||
|
*.iml
|
||||||
|
*.ipr
|
||||||
|
*.iws
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# VS Code
|
||||||
|
##############################
|
||||||
|
|
||||||
|
.history/
|
||||||
|
*.code-workspace
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Vim
|
||||||
|
##############################
|
||||||
|
|
||||||
|
*.swp
|
||||||
|
*.swo
|
||||||
|
Session.vim
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Sublime
|
||||||
|
##############################
|
||||||
|
|
||||||
|
*.sublime-workspace
|
||||||
|
*.sublime-project
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Temporary Files
|
||||||
|
##############################
|
||||||
|
|
||||||
|
*.tmp
|
||||||
|
*.temp
|
||||||
|
*.bak
|
||||||
|
*.old
|
||||||
|
*.orig
|
||||||
|
*.rej
|
||||||
|
*.save
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Logs
|
||||||
|
##############################
|
||||||
|
|
||||||
|
*.log
|
||||||
|
logs/
|
||||||
|
log/
|
||||||
|
*.out
|
||||||
|
*.err
|
||||||
|
*.trace
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Runtime
|
||||||
|
##############################
|
||||||
|
|
||||||
|
*.pid
|
||||||
|
*.seed
|
||||||
|
*.pid.lock
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Secrets
|
||||||
|
##############################
|
||||||
|
|
||||||
|
.env
|
||||||
|
.env.*
|
||||||
|
!.env.example
|
||||||
|
*.pem
|
||||||
|
*.key
|
||||||
|
*.crt
|
||||||
|
*.cer
|
||||||
|
*.p12
|
||||||
|
*.pfx
|
||||||
|
*.kdbx
|
||||||
|
*.secret
|
||||||
|
*.token
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# SSH
|
||||||
|
##############################
|
||||||
|
|
||||||
|
.ssh/
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Docker
|
||||||
|
##############################
|
||||||
|
|
||||||
|
docker-compose.override.yml
|
||||||
|
docker-compose.local.yml
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# VM Storage
|
||||||
|
##############################
|
||||||
|
|
||||||
|
storage/
|
||||||
|
windows/
|
||||||
|
downloads/
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Disk Images
|
||||||
|
##############################
|
||||||
|
|
||||||
|
*.qcow2
|
||||||
|
*.qcow
|
||||||
|
*.vhd
|
||||||
|
*.vhdx
|
||||||
|
*.vdi
|
||||||
|
*.raw
|
||||||
|
*.img
|
||||||
|
*.iso
|
||||||
|
*.bin
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# QEMU
|
||||||
|
##############################
|
||||||
|
|
||||||
|
*.nvram
|
||||||
|
*.fd
|
||||||
|
*.efi
|
||||||
|
*.sock
|
||||||
|
*.monitor
|
||||||
|
*.serial
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Samba
|
||||||
|
##############################
|
||||||
|
|
||||||
|
shared/
|
||||||
|
share/
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Backups
|
||||||
|
##############################
|
||||||
|
|
||||||
|
backup/
|
||||||
|
backups/
|
||||||
|
*.backup
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Cache
|
||||||
|
##############################
|
||||||
|
|
||||||
|
.cache/
|
||||||
|
.cache-loader/
|
||||||
|
.tmp/
|
||||||
|
temp/
|
||||||
|
tmp/
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Python
|
||||||
|
##############################
|
||||||
|
|
||||||
|
__pycache__/
|
||||||
|
*.py[cod]
|
||||||
|
.pytest_cache/
|
||||||
|
.mypy_cache/
|
||||||
|
.venv/
|
||||||
|
venv/
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Node
|
||||||
|
##############################
|
||||||
|
|
||||||
|
node_modules/
|
||||||
|
npm-debug.log*
|
||||||
|
yarn-debug.log*
|
||||||
|
yarn-error.log*
|
||||||
|
pnpm-debug.log*
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Build
|
||||||
|
##############################
|
||||||
|
|
||||||
|
dist/
|
||||||
|
build/
|
||||||
|
out/
|
||||||
|
release/
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Coverage
|
||||||
|
##############################
|
||||||
|
|
||||||
|
coverage/
|
||||||
|
.coverage
|
||||||
|
coverage.xml
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Archives
|
||||||
|
##############################
|
||||||
|
|
||||||
|
*.zip
|
||||||
|
*.tar
|
||||||
|
*.tar.gz
|
||||||
|
*.tgz
|
||||||
|
*.7z
|
||||||
|
*.rar
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Generated Config
|
||||||
|
##############################
|
||||||
|
|
||||||
|
config.local.*
|
||||||
|
settings.local.*
|
||||||
|
local.env
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Test Files
|
||||||
|
##############################
|
||||||
|
|
||||||
|
test-output/
|
||||||
|
playwright-report/
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# macOS
|
||||||
|
##############################
|
||||||
|
|
||||||
|
.AppleDB
|
||||||
|
.AppleDesktop
|
||||||
|
Network Trash Folder
|
||||||
|
Temporary Items
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Linux
|
||||||
|
##############################
|
||||||
|
|
||||||
|
*~
|
||||||
|
.nfs*
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Windows
|
||||||
|
##############################
|
||||||
|
|
||||||
|
*.stackdump
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Misc
|
||||||
|
##############################
|
||||||
|
|
||||||
|
*.cache
|
||||||
|
*.lock
|
||||||
|
*.lock.json
|
||||||
|
*.bak.*
|
||||||
|
|
||||||
|
##############################
|
||||||
|
# Keep Examples
|
||||||
|
##############################
|
||||||
|
|
||||||
|
!.gitkeep
|
||||||
|
!.env.example
|
||||||
|
|||||||
+22
-5
@@ -1,13 +1,16 @@
|
|||||||
# syntax=docker/dockerfile:1
|
# syntax=docker/dockerfile:1.28
|
||||||
|
|
||||||
ARG VERSION_ARG="latest"
|
ARG VERSION_ARG="latest"
|
||||||
FROM scratch AS build-amd64
|
FROM scratch AS build-amd64
|
||||||
|
|
||||||
COPY --from=qemux/qemu:7.36 / /
|
COPY --from=qemux/qemu:7.50 --exclude=usr/bin/qemu-system-x86_64 / /
|
||||||
|
|
||||||
ARG TARGETARCH
|
ARG TARGETARCH
|
||||||
ARG VERSION_WSDD="1.26"
|
|
||||||
ARG VERSION_VIRTIO="1.9.58"
|
ARG VERSION_WSDD="1.27"
|
||||||
|
ARG VERSION_DXVK="3.1.1"
|
||||||
|
ARG VERSION_VIRTIO="1.9.61"
|
||||||
|
ARG VERSION_BLINTER="1.0.112"
|
||||||
|
|
||||||
ARG DEBCONF_NOWARNINGS="yes"
|
ARG DEBCONF_NOWARNINGS="yes"
|
||||||
ARG DEBIAN_FRONTEND="noninteractive"
|
ARG DEBIAN_FRONTEND="noninteractive"
|
||||||
@@ -18,23 +21,37 @@ RUN <<EOF
|
|||||||
|
|
||||||
apt-get update
|
apt-get update
|
||||||
apt-get --no-install-recommends -y install \
|
apt-get --no-install-recommends -y install \
|
||||||
|
gcab \
|
||||||
samba \
|
samba \
|
||||||
|
mtools \
|
||||||
wimtools \
|
wimtools \
|
||||||
dos2unix \
|
dos2unix \
|
||||||
cabextract \
|
cabextract \
|
||||||
|
xmlstarlet \
|
||||||
|
icu-devtools \
|
||||||
libxml2-utils \
|
libxml2-utils \
|
||||||
libarchive-tools
|
libarchive-tools
|
||||||
|
|
||||||
# Install wsdd
|
# Install Blinter
|
||||||
|
python3 -m pip install --break-system-packages --root-user-action=ignore --no-cache-dir "Blinter==${VERSION_BLINTER}"
|
||||||
|
|
||||||
|
# Install wsddn package
|
||||||
wget "https://github.com/gershnik/wsdd-native/releases/download/v${VERSION_WSDD}/wsddn_${VERSION_WSDD}_${TARGETARCH}.deb" -O /tmp/wsddn.deb -q --timeout=10
|
wget "https://github.com/gershnik/wsdd-native/releases/download/v${VERSION_WSDD}/wsddn_${VERSION_WSDD}_${TARGETARCH}.deb" -O /tmp/wsddn.deb -q --timeout=10
|
||||||
dpkg -i /tmp/wsddn.deb
|
dpkg -i /tmp/wsddn.deb
|
||||||
|
|
||||||
|
# Install dxvk-native
|
||||||
|
wget "https://github.com/doitsujin/dxvk/releases/download/v${VERSION_DXVK}/dxvk-native-${VERSION_DXVK}-steamrt-sniper.tar.gz" -O /tmp/dxvk-native.tar.gz -q --timeout=10
|
||||||
|
tar -xzf /tmp/dxvk-native.tar.gz -C /
|
||||||
|
ldconfig
|
||||||
|
|
||||||
apt-get clean
|
apt-get clean
|
||||||
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
|
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
COPY --chmod=755 ./src /run/
|
COPY --chmod=755 ./src /run/
|
||||||
COPY --chmod=755 ./assets /run/assets
|
COPY --chmod=755 ./assets /run/assets
|
||||||
|
COPY --from=qemux/udfread:1.2.0 /udfread /usr/bin/
|
||||||
|
COPY --from=qemux/qemu-windows:11.2.23 /usr/bin/qemu-system-x86_64 /usr/bin/
|
||||||
|
|
||||||
ADD --chmod=664 https://github.com/qemus/virtiso-whql/releases/download/v${VERSION_VIRTIO}-0/virtio-win-${VERSION_VIRTIO}.tar.xz /var/drivers.txz
|
ADD --chmod=664 https://github.com/qemus/virtiso-whql/releases/download/v${VERSION_VIRTIO}-0/virtio-win-${VERSION_VIRTIO}.tar.xz /var/drivers.txz
|
||||||
|
|
||||||
|
|||||||
@@ -1,444 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<unattend xmlns="urn:schemas-microsoft-com:unattend" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
|
|
||||||
<settings pass="windowsPE">
|
|
||||||
<component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SetupUILanguage>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
</SetupUILanguage>
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DiskConfiguration>
|
|
||||||
<Disk wcm:action="add">
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
|
||||||
<CreatePartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Type>EFI</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Microsoft reserved partition (MSR) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Type>MSR</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Type>Primary</Type>
|
|
||||||
<Extend>true</Extend>
|
|
||||||
</CreatePartition>
|
|
||||||
</CreatePartitions>
|
|
||||||
<ModifyPartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<PartitionID>1</PartitionID>
|
|
||||||
<Label>System</Label>
|
|
||||||
<Format>FAT32</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- MSR partition does not need to be modified -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<PartitionID>2</PartitionID>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
<Label>Windows</Label>
|
|
||||||
<Letter>C</Letter>
|
|
||||||
<Format>NTFS</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
</ModifyPartitions>
|
|
||||||
</Disk>
|
|
||||||
</DiskConfiguration>
|
|
||||||
<ImageInstall>
|
|
||||||
<OSImage>
|
|
||||||
<InstallTo>
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
</InstallTo>
|
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
|
||||||
</OSImage>
|
|
||||||
</ImageInstall>
|
|
||||||
<DynamicUpdate>
|
|
||||||
<Enable>true</Enable>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</DynamicUpdate>
|
|
||||||
<UpgradeData>
|
|
||||||
<Upgrade>false</Upgrade>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</UpgradeData>
|
|
||||||
<UserData>
|
|
||||||
<AcceptEula>true</AcceptEula>
|
|
||||||
<FullName>Docker</FullName>
|
|
||||||
<Organization>Windows for Docker</Organization>
|
|
||||||
</UserData>
|
|
||||||
<EnableFirewall>false</EnableFirewall>
|
|
||||||
<Diagnostics>
|
|
||||||
<OptIn>false</OptIn>
|
|
||||||
</Diagnostics>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="offlineServicing">
|
|
||||||
<component name="Microsoft-Windows-LUA-Settings" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<EnableLUA>false</EnableLUA>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="generalize">
|
|
||||||
<component name="Microsoft-Windows-PnPSysprep" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PersistAllDeviceInstalls>true</PersistAllDeviceInstalls>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Security-SPP" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipRearm>1</SkipRearm>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="specialize">
|
|
||||||
<component name="Microsoft-Windows-Security-SPP-UX" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipAutoActivation>true</SkipAutoActivation>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<ComputerName>*</ComputerName>
|
|
||||||
<OEMInformation>
|
|
||||||
<Manufacturer>Dockur</Manufacturer>
|
|
||||||
<Model>Windows for Docker</Model>
|
|
||||||
<SupportHours>24/7</SupportHours>
|
|
||||||
<SupportPhone />
|
|
||||||
<SupportProvider>Dockur</SupportProvider>
|
|
||||||
<SupportURL>https://github.com/dockur/windows/issues</SupportURL>
|
|
||||||
</OEMInformation>
|
|
||||||
<OEMName>Windows for Docker</OEMName>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ErrorReportingCore" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableWER>1</DisableWER>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="wow64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SQMApi" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<CEIPEnabled>0</CEIPEnabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SystemRestore-Main" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableSR>1</DisableSR>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Deployment" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<RunSynchronous>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<Path>reg.exe unload "HKU\mount"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
</RunSynchronous>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-RDP-WinStationExtensions" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAuthentication>0</UserAuthentication>
|
|
||||||
</component>
|
|
||||||
<component name="Networking-MPSSVC-Svc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<FirewallGroups>
|
|
||||||
<FirewallGroup wcm:action="add" wcm:keyValue="RemoteDesktop">
|
|
||||||
<Active>true</Active>
|
|
||||||
<Profile>all</Profile>
|
|
||||||
<Group>@FirewallAPI.dll,-28752</Group>
|
|
||||||
</FirewallGroup>
|
|
||||||
</FirewallGroups>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="auditSystem" />
|
|
||||||
<settings pass="auditUser" />
|
|
||||||
<settings pass="oobeSystem">
|
|
||||||
<component name="Microsoft-Windows-SecureStartup-FilterDriver" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PreventDeviceEncryption>true</PreventDeviceEncryption>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-EnhancedStorage-Adm" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<TCGSecurityActivationDisabled>1</TCGSecurityActivationDisabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAccounts>
|
|
||||||
<LocalAccounts>
|
|
||||||
<LocalAccount wcm:action="add">
|
|
||||||
<Name>Docker</Name>
|
|
||||||
<Group>Administrators</Group>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</LocalAccount>
|
|
||||||
</LocalAccounts>
|
|
||||||
<AdministratorPassword>
|
|
||||||
<Value>password</Value>
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</AdministratorPassword>
|
|
||||||
</UserAccounts>
|
|
||||||
<AutoLogon>
|
|
||||||
<Username>Docker</Username>
|
|
||||||
<Enabled>true</Enabled>
|
|
||||||
<LogonCount>65432</LogonCount>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</AutoLogon>
|
|
||||||
<Display>
|
|
||||||
<ColorDepth>32</ColorDepth>
|
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
|
||||||
</Display>
|
|
||||||
<OOBE>
|
|
||||||
<HideEULAPage>true</HideEULAPage>
|
|
||||||
<HideLocalAccountScreen>true</HideLocalAccountScreen>
|
|
||||||
<HideOEMRegistrationScreen>true</HideOEMRegistrationScreen>
|
|
||||||
<HideOnlineAccountScreens>true</HideOnlineAccountScreens>
|
|
||||||
<HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
|
|
||||||
<NetworkLocation>Home</NetworkLocation>
|
|
||||||
<ProtectYourPC>3</ProtectYourPC>
|
|
||||||
<SkipUserOOBE>true</SkipUserOOBE>
|
|
||||||
<SkipMachineOOBE>true</SkipMachineOOBE>
|
|
||||||
</OOBE>
|
|
||||||
<RegisteredOrganization>Dockur</RegisteredOrganization>
|
|
||||||
<RegisteredOwner>Windows for Docker</RegisteredOwner>
|
|
||||||
<FirstLogonCommands>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Allow guest access to network shares</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Hide Copilot button</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Search from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
</FirstLogonCommands>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
</unattend>
|
|
||||||
@@ -0,0 +1,169 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe unload "HKU\mount"
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "FlightSettingsMaxPauseDays" /t REG_DWORD /d 3650 /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesExpiryTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Hide Copilot button.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Search from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Task View from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Chat from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-226
@@ -13,7 +13,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -62,14 +62,14 @@
|
|||||||
<ImageInstall>
|
<ImageInstall>
|
||||||
<OSImage>
|
<OSImage>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -150,109 +150,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
</RunSynchronousCommand>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<Path>reg.exe unload "HKU\mount"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -288,14 +187,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -303,14 +202,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -328,118 +227,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Hide Copilot button</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Search from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,169 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe unload "HKU\mount"
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "FlightSettingsMaxPauseDays" /t REG_DWORD /d 3650 /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesExpiryTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Hide Copilot button.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Search from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Task View from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Chat from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-226
@@ -13,7 +13,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -68,14 +68,14 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -156,109 +156,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
</RunSynchronousCommand>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<Path>reg.exe unload "HKU\mount"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -294,14 +193,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -309,14 +208,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -334,118 +233,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Hide Copilot button</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Search from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,169 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe unload "HKU\mount"
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "FlightSettingsMaxPauseDays" /t REG_DWORD /d 3650 /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesExpiryTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Hide Copilot button.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Search from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Task View from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Chat from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-226
@@ -13,7 +13,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -68,14 +68,14 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -153,109 +153,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
</RunSynchronousCommand>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<Path>reg.exe unload "HKU\mount"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -291,14 +190,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -306,14 +205,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -331,118 +230,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Hide Copilot button</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Search from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,168 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe unload "HKU\mount"
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "FlightSettingsMaxPauseDays" /t REG_DWORD /d 3650 /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesExpiryTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Hide Copilot button.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Search from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Task View from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Chat from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-226
@@ -13,7 +13,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -62,14 +62,14 @@
|
|||||||
<ImageInstall>
|
<ImageInstall>
|
||||||
<OSImage>
|
<OSImage>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -150,109 +150,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
</RunSynchronousCommand>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<Path>reg.exe unload "HKU\mount"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -288,14 +187,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -303,14 +202,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -328,118 +227,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Hide Copilot button</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Search from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -1,477 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<unattend xmlns="urn:schemas-microsoft-com:unattend" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
|
|
||||||
<settings pass="windowsPE">
|
|
||||||
<component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SetupUILanguage>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
</SetupUILanguage>
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DiskConfiguration>
|
|
||||||
<Disk wcm:action="add">
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
|
||||||
<CreatePartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Type>EFI</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Microsoft reserved partition (MSR) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Type>MSR</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Type>Primary</Type>
|
|
||||||
<Extend>true</Extend>
|
|
||||||
</CreatePartition>
|
|
||||||
</CreatePartitions>
|
|
||||||
<ModifyPartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<PartitionID>1</PartitionID>
|
|
||||||
<Label>System</Label>
|
|
||||||
<Format>FAT32</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- MSR partition does not need to be modified -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<PartitionID>2</PartitionID>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
<Label>Windows</Label>
|
|
||||||
<Letter>C</Letter>
|
|
||||||
<Format>NTFS</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
</ModifyPartitions>
|
|
||||||
</Disk>
|
|
||||||
</DiskConfiguration>
|
|
||||||
<ImageInstall>
|
|
||||||
<OSImage>
|
|
||||||
<InstallTo>
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
</InstallTo>
|
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
|
||||||
</OSImage>
|
|
||||||
</ImageInstall>
|
|
||||||
<DynamicUpdate>
|
|
||||||
<Enable>true</Enable>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</DynamicUpdate>
|
|
||||||
<UpgradeData>
|
|
||||||
<Upgrade>false</Upgrade>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</UpgradeData>
|
|
||||||
<UserData>
|
|
||||||
<AcceptEula>true</AcceptEula>
|
|
||||||
<FullName>Docker</FullName>
|
|
||||||
<Organization>Windows for Docker</Organization>
|
|
||||||
</UserData>
|
|
||||||
<EnableFirewall>false</EnableFirewall>
|
|
||||||
<Diagnostics>
|
|
||||||
<OptIn>false</OptIn>
|
|
||||||
</Diagnostics>
|
|
||||||
<RunSynchronous>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassTPMCheck /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassSecureBootCheck /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassRAMCheck /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SYSTEM\Setup\MoSetup" /v AllowUpgradesWithUnsupportedTPMOrCPU /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
</RunSynchronous>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="offlineServicing">
|
|
||||||
<component name="Microsoft-Windows-LUA-Settings" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<EnableLUA>false</EnableLUA>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="generalize">
|
|
||||||
<component name="Microsoft-Windows-PnPSysprep" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PersistAllDeviceInstalls>true</PersistAllDeviceInstalls>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Security-SPP" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipRearm>1</SkipRearm>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="specialize">
|
|
||||||
<component name="Microsoft-Windows-Security-SPP-UX" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipAutoActivation>true</SkipAutoActivation>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<ComputerName>*</ComputerName>
|
|
||||||
<OEMInformation>
|
|
||||||
<Manufacturer>Dockur</Manufacturer>
|
|
||||||
<Model>Windows for Docker</Model>
|
|
||||||
<SupportHours>24/7</SupportHours>
|
|
||||||
<SupportPhone />
|
|
||||||
<SupportProvider>Dockur</SupportProvider>
|
|
||||||
<SupportURL>https://github.com/dockur/windows/issues</SupportURL>
|
|
||||||
</OEMInformation>
|
|
||||||
<OEMName>Windows for Docker</OEMName>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ErrorReportingCore" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableWER>1</DisableWER>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="wow64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SQMApi" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<CEIPEnabled>0</CEIPEnabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SystemRestore-Main" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableSR>1</DisableSR>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Deployment" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<RunSynchronous>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<Path>reg.exe unload "HKU\mount"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<Path>pnputil -i -a C:\Windows\Drivers\viogpudo\viogpudo.inf</Path>
|
|
||||||
<Description>Install VirtIO display driver</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>27</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
</RunSynchronous>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-RDP-WinStationExtensions" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAuthentication>0</UserAuthentication>
|
|
||||||
</component>
|
|
||||||
<component name="Networking-MPSSVC-Svc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<FirewallGroups>
|
|
||||||
<FirewallGroup wcm:action="add" wcm:keyValue="RemoteDesktop">
|
|
||||||
<Active>true</Active>
|
|
||||||
<Profile>all</Profile>
|
|
||||||
<Group>@FirewallAPI.dll,-28752</Group>
|
|
||||||
</FirewallGroup>
|
|
||||||
</FirewallGroups>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="auditSystem" />
|
|
||||||
<settings pass="auditUser" />
|
|
||||||
<settings pass="oobeSystem">
|
|
||||||
<component name="Microsoft-Windows-SecureStartup-FilterDriver" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PreventDeviceEncryption>true</PreventDeviceEncryption>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-EnhancedStorage-Adm" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<TCGSecurityActivationDisabled>1</TCGSecurityActivationDisabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAccounts>
|
|
||||||
<LocalAccounts>
|
|
||||||
<LocalAccount wcm:action="add">
|
|
||||||
<Name>Docker</Name>
|
|
||||||
<Group>Administrators</Group>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</LocalAccount>
|
|
||||||
</LocalAccounts>
|
|
||||||
<AdministratorPassword>
|
|
||||||
<Value>password</Value>
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</AdministratorPassword>
|
|
||||||
</UserAccounts>
|
|
||||||
<AutoLogon>
|
|
||||||
<Username>Docker</Username>
|
|
||||||
<Enabled>true</Enabled>
|
|
||||||
<LogonCount>65432</LogonCount>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</AutoLogon>
|
|
||||||
<Display>
|
|
||||||
<ColorDepth>32</ColorDepth>
|
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
|
||||||
</Display>
|
|
||||||
<OOBE>
|
|
||||||
<HideEULAPage>true</HideEULAPage>
|
|
||||||
<HideLocalAccountScreen>true</HideLocalAccountScreen>
|
|
||||||
<HideOEMRegistrationScreen>true</HideOEMRegistrationScreen>
|
|
||||||
<HideOnlineAccountScreens>true</HideOnlineAccountScreens>
|
|
||||||
<HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
|
|
||||||
<NetworkLocation>Home</NetworkLocation>
|
|
||||||
<ProtectYourPC>3</ProtectYourPC>
|
|
||||||
<SkipUserOOBE>true</SkipUserOOBE>
|
|
||||||
<SkipMachineOOBE>true</SkipMachineOOBE>
|
|
||||||
</OOBE>
|
|
||||||
<RegisteredOrganization>Dockur</RegisteredOrganization>
|
|
||||||
<RegisteredOwner>Windows for Docker</RegisteredOwner>
|
|
||||||
<FirstLogonCommands>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Allow guest access to network shares</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "RequireSecuritySignature" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable SMB signing requirement</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Hide Copilot button</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV1 /d 0 /t REG_DWORD /f</CommandLine>
|
|
||||||
<Description>Disable unsupported hardware notifications</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV2 /d 0 /t REG_DWORD /f</CommandLine>
|
|
||||||
<Description>Disable unsupported hardware notifications</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C rd /q C:\Windows.old</CommandLine>
|
|
||||||
<Description>Remove empty Windows.old folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
</FirstLogonCommands>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
</unattend>
|
|
||||||
@@ -0,0 +1,188 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="pe" goto pe
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:pe
|
||||||
|
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassTPMCheck /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassSecureBootCheck /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassRAMCheck /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\MoSetup" /v AllowUpgradesWithUnsupportedTPMOrCPU /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe unload "HKU\mount"
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable the SMB signing requirement.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "RequireSecuritySignature" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable per-CPU clock tick scheduling.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\kernel" /v "EnablePerCpuClockTickScheduling" /t REG_DWORD /d 2 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteAPP to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "FlightSettingsMaxPauseDays" /t REG_DWORD /d 3650 /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesExpiryTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Remove the empty Windows.old folder.
|
||||||
|
if exist "%SystemDrive%\Windows.old" rd /q "%SystemDrive%\Windows.old"
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Hide Copilot button.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Task View from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Chat from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable unsupported hardware notifications.
|
||||||
|
reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV1 /d 0 /t REG_DWORD /f
|
||||||
|
|
||||||
|
rem Disable unsupported hardware notifications.
|
||||||
|
reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV2 /d 0 /t REG_DWORD /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-241
@@ -13,7 +13,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -62,14 +62,14 @@
|
|||||||
<ImageInstall>
|
<ImageInstall>
|
||||||
<OSImage>
|
<OSImage>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -168,114 +168,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
</RunSynchronousCommand>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<Path>reg.exe unload "HKU\mount"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<Path>pnputil -i -a C:\Windows\Drivers\viogpudo\viogpudo.inf</Path>
|
|
||||||
<Description>Install VirtIO display driver</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>27</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -311,14 +205,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -326,14 +220,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -351,128 +245,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "RequireSecuritySignature" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable SMB signing requirement</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Hide Copilot button</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV1 /d 0 /t REG_DWORD /f</CommandLine>
|
|
||||||
<Description>Disable unsupported hardware notifications</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV2 /d 0 /t REG_DWORD /f</CommandLine>
|
|
||||||
<Description>Disable unsupported hardware notifications</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C rd /q C:\Windows.old</CommandLine>
|
|
||||||
<Description>Remove empty Windows.old folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,188 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="pe" goto pe
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:pe
|
||||||
|
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassTPMCheck /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassSecureBootCheck /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassRAMCheck /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\MoSetup" /v AllowUpgradesWithUnsupportedTPMOrCPU /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe unload "HKU\mount"
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable the SMB signing requirement.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "RequireSecuritySignature" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable per-CPU clock tick scheduling.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\kernel" /v "EnablePerCpuClockTickScheduling" /t REG_DWORD /d 2 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteAPP to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "FlightSettingsMaxPauseDays" /t REG_DWORD /d 3650 /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesExpiryTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Remove the empty Windows.old folder.
|
||||||
|
if exist "%SystemDrive%\Windows.old" rd /q "%SystemDrive%\Windows.old"
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Hide Copilot button.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Task View from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Chat from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable unsupported hardware notifications.
|
||||||
|
reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV1 /d 0 /t REG_DWORD /f
|
||||||
|
|
||||||
|
rem Disable unsupported hardware notifications.
|
||||||
|
reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV2 /d 0 /t REG_DWORD /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-241
@@ -13,7 +13,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -62,14 +62,14 @@
|
|||||||
<ImageInstall>
|
<ImageInstall>
|
||||||
<OSImage>
|
<OSImage>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -168,114 +168,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
</RunSynchronousCommand>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<Path>reg.exe unload "HKU\mount"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<Path>pnputil -i -a C:\Windows\Drivers\viogpudo\viogpudo.inf</Path>
|
|
||||||
<Description>Install VirtIO display driver</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>27</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -311,14 +205,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -326,14 +220,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -351,128 +245,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "RequireSecuritySignature" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable SMB signing requirement</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Hide Copilot button</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV1 /d 0 /t REG_DWORD /f</CommandLine>
|
|
||||||
<Description>Disable unsupported hardware notifications</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV2 /d 0 /t REG_DWORD /f</CommandLine>
|
|
||||||
<Description>Disable unsupported hardware notifications</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C rd /q C:\Windows.old</CommandLine>
|
|
||||||
<Description>Remove empty Windows.old folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,188 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="pe" goto pe
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:pe
|
||||||
|
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassTPMCheck /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassSecureBootCheck /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassRAMCheck /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\MoSetup" /v AllowUpgradesWithUnsupportedTPMOrCPU /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe unload "HKU\mount"
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable the SMB signing requirement.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "RequireSecuritySignature" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable per-CPU clock tick scheduling.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\kernel" /v "EnablePerCpuClockTickScheduling" /t REG_DWORD /d 2 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteAPP to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "FlightSettingsMaxPauseDays" /t REG_DWORD /d 3650 /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesExpiryTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Remove the empty Windows.old folder.
|
||||||
|
if exist "%SystemDrive%\Windows.old" rd /q "%SystemDrive%\Windows.old"
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Hide Copilot button.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Task View from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Chat from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable unsupported hardware notifications.
|
||||||
|
reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV1 /d 0 /t REG_DWORD /f
|
||||||
|
|
||||||
|
rem Disable unsupported hardware notifications.
|
||||||
|
reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV2 /d 0 /t REG_DWORD /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-241
@@ -13,7 +13,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -62,14 +62,14 @@
|
|||||||
<ImageInstall>
|
<ImageInstall>
|
||||||
<OSImage>
|
<OSImage>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -168,114 +168,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
</RunSynchronousCommand>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<Path>reg.exe unload "HKU\mount"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<Path>pnputil -i -a C:\Windows\Drivers\viogpudo\viogpudo.inf</Path>
|
|
||||||
<Description>Install VirtIO display driver</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>27</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -311,14 +205,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -326,14 +220,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -351,128 +245,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "RequireSecuritySignature" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable SMB signing requirement</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Hide Copilot button</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV1 /d 0 /t REG_DWORD /f</CommandLine>
|
|
||||||
<Description>Disable unsupported hardware notifications</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV2 /d 0 /t REG_DWORD /f</CommandLine>
|
|
||||||
<Description>Disable unsupported hardware notifications</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C rd /q C:\Windows.old</CommandLine>
|
|
||||||
<Description>Remove empty Windows.old folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,188 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="pe" goto pe
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:pe
|
||||||
|
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassTPMCheck /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassSecureBootCheck /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\LabConfig" /v BypassRAMCheck /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\SYSTEM\Setup\MoSetup" /v AllowUpgradesWithUnsupportedTPMOrCPU /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe unload "HKU\mount"
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f
|
||||||
|
reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable the SMB signing requirement.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "RequireSecuritySignature" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable per-CPU clock tick scheduling.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\kernel" /v "EnablePerCpuClockTickScheduling" /t REG_DWORD /d 2 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteAPP to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "FlightSettingsMaxPauseDays" /t REG_DWORD /d 3650 /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesExpiryTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Remove the empty Windows.old folder.
|
||||||
|
if exist "%SystemDrive%\Windows.old" rd /q "%SystemDrive%\Windows.old"
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Hide Copilot button.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Task View from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Chat from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable unsupported hardware notifications.
|
||||||
|
reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV1 /d 0 /t REG_DWORD /f
|
||||||
|
|
||||||
|
rem Disable unsupported hardware notifications.
|
||||||
|
reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV2 /d 0 /t REG_DWORD /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-241
@@ -13,7 +13,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -62,14 +62,14 @@
|
|||||||
<ImageInstall>
|
<ImageInstall>
|
||||||
<OSImage>
|
<OSImage>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -168,114 +168,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v BypassNRO /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
</RunSynchronousCommand>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>reg.exe load "HKU\mount" "C:\Users\Default\NTUSER.DAT"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "ContentDeliveryAllowed" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "FeatureManagementEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OEMPreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEverEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SoftLandingEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContentEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-310093Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338387Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338388Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338389Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-338393Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SubscribedContent-353698Enabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SystemPaneSuggestionsEnabled" /t REG_DWORD /d 0 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<Path>reg.exe add "HKU\mount\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<Path>reg.exe unload "HKU\mount"</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableCloudOptimizedContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<Path>reg.exe add "HKLM\Software\Policies\Microsoft\Windows\CloudContent" /v "DisableConsumerAccountStateContent" /t REG_DWORD /d 1 /f</Path>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<Path>pnputil -i -a C:\Windows\Drivers\viogpudo\viogpudo.inf</Path>
|
|
||||||
<Description>Install VirtIO display driver</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>27</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -311,14 +205,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -326,14 +220,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -351,128 +245,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "RequireSecuritySignature" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable SMB signing requirement</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Hide Copilot button</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV1 /d 0 /t REG_DWORD /f</CommandLine>
|
|
||||||
<Description>Disable unsupported hardware notifications</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\UnsupportedHardwareNotificationCache" /v SV2 /d 0 /t REG_DWORD /f</CommandLine>
|
|
||||||
<Description>Disable unsupported hardware notifications</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C rd /q C:\Windows.old</CommandLine>
|
|
||||||
<Description>Remove empty Windows.old folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>25</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>26</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -1,313 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<unattend xmlns="urn:schemas-microsoft-com:unattend" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
|
|
||||||
<settings pass="windowsPE">
|
|
||||||
<component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SetupUILanguage>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
</SetupUILanguage>
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DiskConfiguration>
|
|
||||||
<WillShowUI>OnError</WillShowUI>
|
|
||||||
<Disk wcm:action="add">
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
|
||||||
<CreatePartitions>
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Type>Primary</Type>
|
|
||||||
<Size>100</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Type>Primary</Type>
|
|
||||||
<Extend>true</Extend>
|
|
||||||
</CreatePartition>
|
|
||||||
</CreatePartitions>
|
|
||||||
<ModifyPartitions>
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Format>NTFS</Format>
|
|
||||||
<Label>System Reserved</Label>
|
|
||||||
<Order>1</Order>
|
|
||||||
<Active>true</Active>
|
|
||||||
<PartitionID>1</PartitionID>
|
|
||||||
<TypeID>0x27</TypeID>
|
|
||||||
</ModifyPartition>
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Active>true</Active>
|
|
||||||
<Format>NTFS</Format>
|
|
||||||
<Label>Windows</Label>
|
|
||||||
<Letter>C</Letter>
|
|
||||||
<Order>2</Order>
|
|
||||||
<PartitionID>2</PartitionID>
|
|
||||||
</ModifyPartition>
|
|
||||||
</ModifyPartitions>
|
|
||||||
</Disk>
|
|
||||||
</DiskConfiguration>
|
|
||||||
<ImageInstall>
|
|
||||||
<OSImage>
|
|
||||||
<InstallFrom>
|
|
||||||
<MetaData wcm:action="add">
|
|
||||||
<Value>1</Value>
|
|
||||||
<Key>/IMAGE/INDEX</Key>
|
|
||||||
</MetaData>
|
|
||||||
</InstallFrom>
|
|
||||||
<InstallTo>
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<PartitionID>2</PartitionID>
|
|
||||||
</InstallTo>
|
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
|
||||||
</OSImage>
|
|
||||||
</ImageInstall>
|
|
||||||
<DynamicUpdate>
|
|
||||||
<Enable>true</Enable>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</DynamicUpdate>
|
|
||||||
<UpgradeData>
|
|
||||||
<Upgrade>false</Upgrade>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</UpgradeData>
|
|
||||||
<UserData>
|
|
||||||
<AcceptEula>true</AcceptEula>
|
|
||||||
<FullName>Docker</FullName>
|
|
||||||
<Organization>Windows for Docker</Organization>
|
|
||||||
</UserData>
|
|
||||||
<EnableFirewall>false</EnableFirewall>
|
|
||||||
<Diagnostics>
|
|
||||||
<OptIn>false</OptIn>
|
|
||||||
</Diagnostics>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="offlineServicing">
|
|
||||||
<component name="Microsoft-Windows-LUA-Settings" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<EnableLUA>false</EnableLUA>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="generalize">
|
|
||||||
<component name="Microsoft-Windows-PnPSysprep" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PersistAllDeviceInstalls>true</PersistAllDeviceInstalls>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Security-SPP" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipRearm>1</SkipRearm>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="specialize">
|
|
||||||
<component name="Microsoft-Windows-Security-SPP-UX" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipAutoActivation>true</SkipAutoActivation>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<ComputerName>*</ComputerName>
|
|
||||||
<OEMInformation>
|
|
||||||
<Manufacturer>Dockur</Manufacturer>
|
|
||||||
<Model>Windows for Docker</Model>
|
|
||||||
</OEMInformation>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ErrorReportingCore" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableWER>1</DisableWER>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="wow64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SQMApi" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<CEIPEnabled>0</CEIPEnabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SystemRestore-Main" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableSR>1</DisableSR>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ServerManager-SvrMgrNc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DoNotOpenServerManagerAtLogon>true</DoNotOpenServerManagerAtLogon>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-OutOfBoxExperience" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DoNotOpenInitialConfigurationTasksAtLogon>true</DoNotOpenInitialConfigurationTasksAtLogon>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-RDP-WinStationExtensions" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAuthentication>0</UserAuthentication>
|
|
||||||
</component>
|
|
||||||
<component name="Networking-MPSSVC-Svc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<FirewallGroups>
|
|
||||||
<FirewallGroup wcm:action="add" wcm:keyValue="RemoteDesktop">
|
|
||||||
<Active>true</Active>
|
|
||||||
<Profile>all</Profile>
|
|
||||||
<Group>@FirewallAPI.dll,-28752</Group>
|
|
||||||
</FirewallGroup>
|
|
||||||
</FirewallGroups>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Deployment" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<RunSynchronous>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
</RunSynchronous>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="oobeSystem">
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAccounts>
|
|
||||||
<LocalAccounts>
|
|
||||||
<LocalAccount wcm:action="add">
|
|
||||||
<Name>Docker</Name>
|
|
||||||
<Group>Administrators</Group>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</LocalAccount>
|
|
||||||
</LocalAccounts>
|
|
||||||
<AdministratorPassword>
|
|
||||||
<Value>password</Value>
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</AdministratorPassword>
|
|
||||||
</UserAccounts>
|
|
||||||
<AutoLogon>
|
|
||||||
<Username>Docker</Username>
|
|
||||||
<Enabled>true</Enabled>
|
|
||||||
<LogonCount>65432</LogonCount>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</AutoLogon>
|
|
||||||
<Display>
|
|
||||||
<ColorDepth>32</ColorDepth>
|
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
|
||||||
</Display>
|
|
||||||
<OOBE>
|
|
||||||
<HideEULAPage>true</HideEULAPage>
|
|
||||||
<HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
|
|
||||||
<NetworkLocation>Home</NetworkLocation>
|
|
||||||
<ProtectYourPC>3</ProtectYourPC>
|
|
||||||
<SkipUserOOBE>true</SkipUserOOBE>
|
|
||||||
<SkipMachineOOBE>true</SkipMachineOOBE>
|
|
||||||
</OOBE>
|
|
||||||
<RegisteredOrganization>Dockur</RegisteredOrganization>
|
|
||||||
<RegisteredOwner>Windows for Docker</RegisteredOwner>
|
|
||||||
<FirstLogonCommands>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Allow guest access to network shares</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
</FirstLogonCommands>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
</unattend>
|
|
||||||
@@ -0,0 +1,129 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable Shutdown Event Tracker.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Reliability" /v "ShutdownReasonOn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-110
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -57,14 +57,14 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>2</PartitionID>
|
<PartitionID>2</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -161,8 +161,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -175,14 +175,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -190,14 +190,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -212,103 +212,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -1,332 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<unattend xmlns="urn:schemas-microsoft-com:unattend" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
|
|
||||||
<settings pass="windowsPE">
|
|
||||||
<component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SetupUILanguage>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
</SetupUILanguage>
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UILanguageFallback>en-US</UILanguageFallback>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DiskConfiguration>
|
|
||||||
<Disk wcm:action="add">
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
|
||||||
<CreatePartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Type>EFI</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Microsoft reserved partition (MSR) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Type>MSR</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Type>Primary</Type>
|
|
||||||
<Extend>true</Extend>
|
|
||||||
</CreatePartition>
|
|
||||||
</CreatePartitions>
|
|
||||||
<ModifyPartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<PartitionID>1</PartitionID>
|
|
||||||
<Label>System</Label>
|
|
||||||
<Format>FAT32</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- MSR partition does not need to be modified -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<PartitionID>2</PartitionID>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
<Label>Windows</Label>
|
|
||||||
<Letter>C</Letter>
|
|
||||||
<Format>NTFS</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
</ModifyPartitions>
|
|
||||||
</Disk>
|
|
||||||
</DiskConfiguration>
|
|
||||||
<ImageInstall>
|
|
||||||
<OSImage>
|
|
||||||
<InstallFrom>
|
|
||||||
<MetaData wcm:action="add">
|
|
||||||
<Key>/image/index</Key>
|
|
||||||
<Value>2</Value>
|
|
||||||
</MetaData>
|
|
||||||
</InstallFrom>
|
|
||||||
<InstallTo>
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
</InstallTo>
|
|
||||||
<WillShowUI>OnError</WillShowUI>
|
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
|
||||||
</OSImage>
|
|
||||||
</ImageInstall>
|
|
||||||
<DynamicUpdate>
|
|
||||||
<Enable>true</Enable>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</DynamicUpdate>
|
|
||||||
<UpgradeData>
|
|
||||||
<Upgrade>false</Upgrade>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</UpgradeData>
|
|
||||||
<UserData>
|
|
||||||
<AcceptEula>true</AcceptEula>
|
|
||||||
<FullName>Docker</FullName>
|
|
||||||
<Organization>Windows for Docker</Organization>
|
|
||||||
</UserData>
|
|
||||||
<EnableFirewall>false</EnableFirewall>
|
|
||||||
<Diagnostics>
|
|
||||||
<OptIn>false</OptIn>
|
|
||||||
</Diagnostics>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="offlineServicing">
|
|
||||||
<component name="Microsoft-Windows-LUA-Settings" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<EnableLUA>false</EnableLUA>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="generalize">
|
|
||||||
<component name="Microsoft-Windows-PnPSysprep" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PersistAllDeviceInstalls>true</PersistAllDeviceInstalls>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Security-SPP" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipRearm>1</SkipRearm>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="specialize">
|
|
||||||
<component name="Microsoft-Windows-Security-SPP-UX" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipAutoActivation>true</SkipAutoActivation>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<ComputerName>*</ComputerName>
|
|
||||||
<OEMInformation>
|
|
||||||
<Manufacturer>Dockur</Manufacturer>
|
|
||||||
<Model>Windows for Docker</Model>
|
|
||||||
</OEMInformation>
|
|
||||||
<OEMName>Windows for Docker</OEMName>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ErrorReportingCore" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableWER>1</DisableWER>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="wow64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SQMApi" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<CEIPEnabled>0</CEIPEnabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SystemRestore-Main" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableSR>1</DisableSR>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UILanguageFallback>en-US</UILanguageFallback>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Deployment" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<RunSynchronous>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
</RunSynchronous>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ServerManager-SvrMgrNc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DoNotOpenServerManagerAtLogon>true</DoNotOpenServerManagerAtLogon>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-OutOfBoxExperience" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DoNotOpenInitialConfigurationTasksAtLogon>true</DoNotOpenInitialConfigurationTasksAtLogon>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-RDP-WinStationExtensions" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAuthentication>0</UserAuthentication>
|
|
||||||
</component>
|
|
||||||
<component name="Networking-MPSSVC-Svc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<FirewallGroups>
|
|
||||||
<FirewallGroup wcm:action="add" wcm:keyValue="RemoteDesktop">
|
|
||||||
<Active>true</Active>
|
|
||||||
<Profile>all</Profile>
|
|
||||||
<Group>@FirewallAPI.dll,-28752</Group>
|
|
||||||
</FirewallGroup>
|
|
||||||
</FirewallGroups>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="oobeSystem">
|
|
||||||
<component name="Microsoft-Windows-SecureStartup-FilterDriver" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PreventDeviceEncryption>true</PreventDeviceEncryption>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-EnhancedStorage-Adm" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<TCGSecurityActivationDisabled>1</TCGSecurityActivationDisabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAccounts>
|
|
||||||
<LocalAccounts>
|
|
||||||
<LocalAccount wcm:action="add">
|
|
||||||
<Name>Docker</Name>
|
|
||||||
<Group>Administrators</Group>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</LocalAccount>
|
|
||||||
</LocalAccounts>
|
|
||||||
<AdministratorPassword>
|
|
||||||
<Value>password</Value>
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</AdministratorPassword>
|
|
||||||
</UserAccounts>
|
|
||||||
<AutoLogon>
|
|
||||||
<Username>Docker</Username>
|
|
||||||
<Enabled>true</Enabled>
|
|
||||||
<LogonCount>65432</LogonCount>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</AutoLogon>
|
|
||||||
<Display>
|
|
||||||
<ColorDepth>32</ColorDepth>
|
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
|
||||||
</Display>
|
|
||||||
<OOBE>
|
|
||||||
<HideEULAPage>true</HideEULAPage>
|
|
||||||
<HideLocalAccountScreen>true</HideLocalAccountScreen>
|
|
||||||
<HideOEMRegistrationScreen>true</HideOEMRegistrationScreen>
|
|
||||||
<HideOnlineAccountScreens>true</HideOnlineAccountScreens>
|
|
||||||
<HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
|
|
||||||
<NetworkLocation>Home</NetworkLocation>
|
|
||||||
<ProtectYourPC>3</ProtectYourPC>
|
|
||||||
<SkipUserOOBE>true</SkipUserOOBE>
|
|
||||||
<SkipMachineOOBE>true</SkipMachineOOBE>
|
|
||||||
</OOBE>
|
|
||||||
<RegisteredOrganization>Dockur</RegisteredOrganization>
|
|
||||||
<RegisteredOwner>Windows for Docker</RegisteredOwner>
|
|
||||||
<FirstLogonCommands>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Allow guest access to network shares</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
</FirstLogonCommands>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
</unattend>
|
|
||||||
@@ -0,0 +1,126 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable Shutdown Event Tracker.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Reliability" /v "ShutdownReasonOn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-105
@@ -14,7 +14,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -69,7 +69,7 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
@@ -77,7 +77,7 @@
|
|||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -155,13 +155,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Set Network Location to Home</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -201,14 +196,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -216,14 +211,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -241,93 +236,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -1,352 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<unattend xmlns="urn:schemas-microsoft-com:unattend" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
|
|
||||||
<settings pass="windowsPE">
|
|
||||||
<component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SetupUILanguage>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
</SetupUILanguage>
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UILanguageFallback>en-US</UILanguageFallback>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DiskConfiguration>
|
|
||||||
<Disk wcm:action="add">
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
|
||||||
<CreatePartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Type>EFI</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Microsoft reserved partition (MSR) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Type>MSR</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Type>Primary</Type>
|
|
||||||
<Extend>true</Extend>
|
|
||||||
</CreatePartition>
|
|
||||||
</CreatePartitions>
|
|
||||||
<ModifyPartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<PartitionID>1</PartitionID>
|
|
||||||
<Label>System</Label>
|
|
||||||
<Format>FAT32</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- MSR partition does not need to be modified -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<PartitionID>2</PartitionID>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
<Label>Windows</Label>
|
|
||||||
<Letter>C</Letter>
|
|
||||||
<Format>NTFS</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
</ModifyPartitions>
|
|
||||||
</Disk>
|
|
||||||
</DiskConfiguration>
|
|
||||||
<ImageInstall>
|
|
||||||
<OSImage>
|
|
||||||
<InstallFrom>
|
|
||||||
<MetaData wcm:action="add">
|
|
||||||
<Key>/IMAGE/NAME</Key>
|
|
||||||
<Value>Windows Server 2016 SERVERSTANDARD</Value>
|
|
||||||
</MetaData>
|
|
||||||
</InstallFrom>
|
|
||||||
<InstallTo>
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
</InstallTo>
|
|
||||||
<WillShowUI>OnError</WillShowUI>
|
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
|
||||||
</OSImage>
|
|
||||||
</ImageInstall>
|
|
||||||
<DynamicUpdate>
|
|
||||||
<Enable>true</Enable>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</DynamicUpdate>
|
|
||||||
<UpgradeData>
|
|
||||||
<Upgrade>false</Upgrade>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</UpgradeData>
|
|
||||||
<UserData>
|
|
||||||
<AcceptEula>true</AcceptEula>
|
|
||||||
<FullName>Docker</FullName>
|
|
||||||
<Organization>Windows for Docker</Organization>
|
|
||||||
</UserData>
|
|
||||||
<EnableFirewall>false</EnableFirewall>
|
|
||||||
<Diagnostics>
|
|
||||||
<OptIn>false</OptIn>
|
|
||||||
</Diagnostics>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="offlineServicing">
|
|
||||||
<component name="Microsoft-Windows-LUA-Settings" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<EnableLUA>false</EnableLUA>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="generalize">
|
|
||||||
<component name="Microsoft-Windows-PnPSysprep" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PersistAllDeviceInstalls>true</PersistAllDeviceInstalls>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Security-SPP" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipRearm>1</SkipRearm>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="specialize">
|
|
||||||
<component name="Microsoft-Windows-Security-SPP-UX" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipAutoActivation>true</SkipAutoActivation>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<ComputerName>*</ComputerName>
|
|
||||||
<OEMInformation>
|
|
||||||
<Manufacturer>Dockur</Manufacturer>
|
|
||||||
<Model>Windows for Docker</Model>
|
|
||||||
</OEMInformation>
|
|
||||||
<OEMName>Windows for Docker</OEMName>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ErrorReportingCore" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableWER>1</DisableWER>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="wow64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SQMApi" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<CEIPEnabled>0</CEIPEnabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SystemRestore-Main" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableSR>1</DisableSR>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UILanguageFallback>en-US</UILanguageFallback>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Deployment" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<RunSynchronous>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
</RunSynchronous>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ServerManager-SvrMgrNc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DoNotOpenServerManagerAtLogon>true</DoNotOpenServerManagerAtLogon>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-OutOfBoxExperience" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DoNotOpenInitialConfigurationTasksAtLogon>true</DoNotOpenInitialConfigurationTasksAtLogon>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-RDP-WinStationExtensions" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAuthentication>0</UserAuthentication>
|
|
||||||
</component>
|
|
||||||
<component name="Networking-MPSSVC-Svc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<FirewallGroups>
|
|
||||||
<FirewallGroup wcm:action="add" wcm:keyValue="RemoteDesktop">
|
|
||||||
<Active>true</Active>
|
|
||||||
<Profile>all</Profile>
|
|
||||||
<Group>@FirewallAPI.dll,-28752</Group>
|
|
||||||
</FirewallGroup>
|
|
||||||
</FirewallGroups>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="oobeSystem">
|
|
||||||
<component name="Microsoft-Windows-SecureStartup-FilterDriver" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PreventDeviceEncryption>true</PreventDeviceEncryption>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-EnhancedStorage-Adm" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<TCGSecurityActivationDisabled>1</TCGSecurityActivationDisabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAccounts>
|
|
||||||
<LocalAccounts>
|
|
||||||
<LocalAccount wcm:action="add">
|
|
||||||
<Name>Docker</Name>
|
|
||||||
<Group>Administrators</Group>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</LocalAccount>
|
|
||||||
</LocalAccounts>
|
|
||||||
<AdministratorPassword>
|
|
||||||
<Value>password</Value>
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</AdministratorPassword>
|
|
||||||
</UserAccounts>
|
|
||||||
<AutoLogon>
|
|
||||||
<Username>Docker</Username>
|
|
||||||
<Enabled>true</Enabled>
|
|
||||||
<LogonCount>65432</LogonCount>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</AutoLogon>
|
|
||||||
<Display>
|
|
||||||
<ColorDepth>32</ColorDepth>
|
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
|
||||||
</Display>
|
|
||||||
<OOBE>
|
|
||||||
<HideEULAPage>true</HideEULAPage>
|
|
||||||
<HideLocalAccountScreen>true</HideLocalAccountScreen>
|
|
||||||
<HideOEMRegistrationScreen>true</HideOEMRegistrationScreen>
|
|
||||||
<HideOnlineAccountScreens>true</HideOnlineAccountScreens>
|
|
||||||
<HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
|
|
||||||
<NetworkLocation>Home</NetworkLocation>
|
|
||||||
<ProtectYourPC>3</ProtectYourPC>
|
|
||||||
<SkipUserOOBE>true</SkipUserOOBE>
|
|
||||||
<SkipMachineOOBE>true</SkipMachineOOBE>
|
|
||||||
</OOBE>
|
|
||||||
<RegisteredOrganization>Dockur</RegisteredOrganization>
|
|
||||||
<RegisteredOwner>Windows for Docker</RegisteredOwner>
|
|
||||||
<FirstLogonCommands>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Allow guest access to network shares</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Search from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
</FirstLogonCommands>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
</unattend>
|
|
||||||
@@ -0,0 +1,138 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable Shutdown Event Tracker.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Reliability" /v "ShutdownReasonOn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Search from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Task View from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Chat from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-125
@@ -14,7 +14,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -69,7 +69,7 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
@@ -77,7 +77,7 @@
|
|||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -155,13 +155,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Set Network Location to Home</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -201,14 +196,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -216,14 +211,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -241,113 +236,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Search from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -1,356 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<unattend xmlns="urn:schemas-microsoft-com:unattend" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
|
|
||||||
<settings pass="windowsPE">
|
|
||||||
<component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SetupUILanguage>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
</SetupUILanguage>
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UILanguageFallback>en-US</UILanguageFallback>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DiskConfiguration>
|
|
||||||
<Disk wcm:action="add">
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
|
||||||
<CreatePartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Type>EFI</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Microsoft reserved partition (MSR) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Type>MSR</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Type>Primary</Type>
|
|
||||||
<Extend>true</Extend>
|
|
||||||
</CreatePartition>
|
|
||||||
</CreatePartitions>
|
|
||||||
<ModifyPartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<PartitionID>1</PartitionID>
|
|
||||||
<Label>System</Label>
|
|
||||||
<Format>FAT32</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- MSR partition does not need to be modified -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<PartitionID>2</PartitionID>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
<Label>Windows</Label>
|
|
||||||
<Letter>C</Letter>
|
|
||||||
<Format>NTFS</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
</ModifyPartitions>
|
|
||||||
</Disk>
|
|
||||||
</DiskConfiguration>
|
|
||||||
<ImageInstall>
|
|
||||||
<OSImage>
|
|
||||||
<InstallFrom>
|
|
||||||
<MetaData wcm:action="add">
|
|
||||||
<Key>/IMAGE/NAME</Key>
|
|
||||||
<Value>Windows Server 2019 SERVERSTANDARD</Value>
|
|
||||||
</MetaData>
|
|
||||||
</InstallFrom>
|
|
||||||
<InstallTo>
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
</InstallTo>
|
|
||||||
<WillShowUI>OnError</WillShowUI>
|
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
|
||||||
</OSImage>
|
|
||||||
</ImageInstall>
|
|
||||||
<DynamicUpdate>
|
|
||||||
<Enable>true</Enable>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</DynamicUpdate>
|
|
||||||
<UpgradeData>
|
|
||||||
<Upgrade>false</Upgrade>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</UpgradeData>
|
|
||||||
<UserData>
|
|
||||||
<AcceptEula>true</AcceptEula>
|
|
||||||
<FullName>Docker</FullName>
|
|
||||||
<Organization>Windows for Docker</Organization>
|
|
||||||
</UserData>
|
|
||||||
<EnableFirewall>false</EnableFirewall>
|
|
||||||
<Diagnostics>
|
|
||||||
<OptIn>false</OptIn>
|
|
||||||
</Diagnostics>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="offlineServicing">
|
|
||||||
<component name="Microsoft-Windows-LUA-Settings" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<EnableLUA>false</EnableLUA>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="generalize">
|
|
||||||
<component name="Microsoft-Windows-PnPSysprep" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PersistAllDeviceInstalls>true</PersistAllDeviceInstalls>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Security-SPP" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipRearm>1</SkipRearm>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="specialize">
|
|
||||||
<component name="Microsoft-Windows-Security-SPP-UX" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipAutoActivation>true</SkipAutoActivation>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<ComputerName>*</ComputerName>
|
|
||||||
<OEMInformation>
|
|
||||||
<Manufacturer>Dockur</Manufacturer>
|
|
||||||
<Model>Windows for Docker</Model>
|
|
||||||
<SupportHours>24/7</SupportHours>
|
|
||||||
<SupportPhone />
|
|
||||||
<SupportProvider>Dockur</SupportProvider>
|
|
||||||
<SupportURL>https://github.com/dockur/windows/issues</SupportURL>
|
|
||||||
</OEMInformation>
|
|
||||||
<OEMName>Windows for Docker</OEMName>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ErrorReportingCore" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableWER>1</DisableWER>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="wow64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SQMApi" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<CEIPEnabled>0</CEIPEnabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SystemRestore-Main" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableSR>1</DisableSR>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UILanguageFallback>en-US</UILanguageFallback>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Deployment" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<RunSynchronous>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
</RunSynchronous>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ServerManager-SvrMgrNc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DoNotOpenServerManagerAtLogon>true</DoNotOpenServerManagerAtLogon>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-OutOfBoxExperience" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DoNotOpenInitialConfigurationTasksAtLogon>true</DoNotOpenInitialConfigurationTasksAtLogon>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-RDP-WinStationExtensions" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAuthentication>0</UserAuthentication>
|
|
||||||
</component>
|
|
||||||
<component name="Networking-MPSSVC-Svc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<FirewallGroups>
|
|
||||||
<FirewallGroup wcm:action="add" wcm:keyValue="RemoteDesktop">
|
|
||||||
<Active>true</Active>
|
|
||||||
<Profile>all</Profile>
|
|
||||||
<Group>@FirewallAPI.dll,-28752</Group>
|
|
||||||
</FirewallGroup>
|
|
||||||
</FirewallGroups>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="oobeSystem">
|
|
||||||
<component name="Microsoft-Windows-SecureStartup-FilterDriver" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PreventDeviceEncryption>true</PreventDeviceEncryption>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-EnhancedStorage-Adm" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<TCGSecurityActivationDisabled>1</TCGSecurityActivationDisabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAccounts>
|
|
||||||
<LocalAccounts>
|
|
||||||
<LocalAccount wcm:action="add">
|
|
||||||
<Name>Docker</Name>
|
|
||||||
<Group>Administrators</Group>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</LocalAccount>
|
|
||||||
</LocalAccounts>
|
|
||||||
<AdministratorPassword>
|
|
||||||
<Value>password</Value>
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</AdministratorPassword>
|
|
||||||
</UserAccounts>
|
|
||||||
<AutoLogon>
|
|
||||||
<Username>Docker</Username>
|
|
||||||
<Enabled>true</Enabled>
|
|
||||||
<LogonCount>65432</LogonCount>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</AutoLogon>
|
|
||||||
<Display>
|
|
||||||
<ColorDepth>32</ColorDepth>
|
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
|
||||||
</Display>
|
|
||||||
<OOBE>
|
|
||||||
<HideEULAPage>true</HideEULAPage>
|
|
||||||
<HideLocalAccountScreen>true</HideLocalAccountScreen>
|
|
||||||
<HideOEMRegistrationScreen>true</HideOEMRegistrationScreen>
|
|
||||||
<HideOnlineAccountScreens>true</HideOnlineAccountScreens>
|
|
||||||
<HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
|
|
||||||
<NetworkLocation>Home</NetworkLocation>
|
|
||||||
<ProtectYourPC>3</ProtectYourPC>
|
|
||||||
<SkipUserOOBE>true</SkipUserOOBE>
|
|
||||||
<SkipMachineOOBE>true</SkipMachineOOBE>
|
|
||||||
</OOBE>
|
|
||||||
<RegisteredOrganization>Dockur</RegisteredOrganization>
|
|
||||||
<RegisteredOwner>Windows for Docker</RegisteredOwner>
|
|
||||||
<FirstLogonCommands>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Allow guest access to network shares</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Search from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
</FirstLogonCommands>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
</unattend>
|
|
||||||
@@ -0,0 +1,138 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Hyper-V role
|
||||||
|
dism.exe /online /Disable-Feature /FeatureName:Microsoft-Hyper-V /NoRestart
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable Shutdown Event Tracker.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Reliability" /v "ShutdownReasonOn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Search from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Task View from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Chat from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-130
@@ -14,7 +14,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -69,7 +69,7 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
@@ -77,7 +77,7 @@
|
|||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -156,18 +156,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Set Network Location to Home</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>dism.exe /online /Disable-Feature /FeatureName:Microsoft-Hyper-V /NoRestart</Path>
|
|
||||||
<Description>Disable Hyper-V role</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -207,14 +197,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -222,14 +212,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -247,113 +237,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Search from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,144 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable Shutdown Event Tracker.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Reliability" /v "ShutdownReasonOn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "FlightSettingsMaxPauseDays" /t REG_DWORD /d 3650 /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesExpiryTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Search from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Task View from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Chat from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-125
@@ -14,7 +14,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -69,7 +69,7 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
@@ -77,7 +77,7 @@
|
|||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -159,13 +159,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Set Network Location to Home</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -205,14 +200,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -220,14 +215,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -245,113 +240,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Search from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -1,356 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<unattend xmlns="urn:schemas-microsoft-com:unattend" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
|
|
||||||
<settings pass="windowsPE">
|
|
||||||
<component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SetupUILanguage>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
</SetupUILanguage>
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UILanguageFallback>en-US</UILanguageFallback>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DiskConfiguration>
|
|
||||||
<Disk wcm:action="add">
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
|
||||||
<CreatePartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Type>EFI</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Microsoft reserved partition (MSR) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Type>MSR</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Type>Primary</Type>
|
|
||||||
<Extend>true</Extend>
|
|
||||||
</CreatePartition>
|
|
||||||
</CreatePartitions>
|
|
||||||
<ModifyPartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<PartitionID>1</PartitionID>
|
|
||||||
<Label>System</Label>
|
|
||||||
<Format>FAT32</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- MSR partition does not need to be modified -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<PartitionID>2</PartitionID>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
<Label>Windows</Label>
|
|
||||||
<Letter>C</Letter>
|
|
||||||
<Format>NTFS</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
</ModifyPartitions>
|
|
||||||
</Disk>
|
|
||||||
</DiskConfiguration>
|
|
||||||
<ImageInstall>
|
|
||||||
<OSImage>
|
|
||||||
<InstallFrom>
|
|
||||||
<MetaData wcm:action="add">
|
|
||||||
<Key>/IMAGE/NAME</Key>
|
|
||||||
<Value>Windows Server 2022 SERVERSTANDARD</Value>
|
|
||||||
</MetaData>
|
|
||||||
</InstallFrom>
|
|
||||||
<InstallTo>
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
</InstallTo>
|
|
||||||
<WillShowUI>OnError</WillShowUI>
|
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
|
||||||
</OSImage>
|
|
||||||
</ImageInstall>
|
|
||||||
<DynamicUpdate>
|
|
||||||
<Enable>true</Enable>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</DynamicUpdate>
|
|
||||||
<UpgradeData>
|
|
||||||
<Upgrade>false</Upgrade>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</UpgradeData>
|
|
||||||
<UserData>
|
|
||||||
<AcceptEula>true</AcceptEula>
|
|
||||||
<FullName>Docker</FullName>
|
|
||||||
<Organization>Windows for Docker</Organization>
|
|
||||||
</UserData>
|
|
||||||
<EnableFirewall>false</EnableFirewall>
|
|
||||||
<Diagnostics>
|
|
||||||
<OptIn>false</OptIn>
|
|
||||||
</Diagnostics>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="offlineServicing">
|
|
||||||
<component name="Microsoft-Windows-LUA-Settings" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<EnableLUA>false</EnableLUA>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="generalize">
|
|
||||||
<component name="Microsoft-Windows-PnPSysprep" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PersistAllDeviceInstalls>true</PersistAllDeviceInstalls>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Security-SPP" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipRearm>1</SkipRearm>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="specialize">
|
|
||||||
<component name="Microsoft-Windows-Security-SPP-UX" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipAutoActivation>true</SkipAutoActivation>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<ComputerName>*</ComputerName>
|
|
||||||
<OEMInformation>
|
|
||||||
<Manufacturer>Dockur</Manufacturer>
|
|
||||||
<Model>Windows for Docker</Model>
|
|
||||||
<SupportHours>24/7</SupportHours>
|
|
||||||
<SupportPhone />
|
|
||||||
<SupportProvider>Dockur</SupportProvider>
|
|
||||||
<SupportURL>https://github.com/dockur/windows/issues</SupportURL>
|
|
||||||
</OEMInformation>
|
|
||||||
<OEMName>Windows for Docker</OEMName>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ErrorReportingCore" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableWER>1</DisableWER>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="wow64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SQMApi" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<CEIPEnabled>0</CEIPEnabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SystemRestore-Main" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableSR>1</DisableSR>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UILanguageFallback>en-US</UILanguageFallback>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Deployment" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<RunSynchronous>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
</RunSynchronous>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ServerManager-SvrMgrNc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DoNotOpenServerManagerAtLogon>true</DoNotOpenServerManagerAtLogon>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-OutOfBoxExperience" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DoNotOpenInitialConfigurationTasksAtLogon>true</DoNotOpenInitialConfigurationTasksAtLogon>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-RDP-WinStationExtensions" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAuthentication>0</UserAuthentication>
|
|
||||||
</component>
|
|
||||||
<component name="Networking-MPSSVC-Svc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<FirewallGroups>
|
|
||||||
<FirewallGroup wcm:action="add" wcm:keyValue="RemoteDesktop">
|
|
||||||
<Active>true</Active>
|
|
||||||
<Profile>all</Profile>
|
|
||||||
<Group>@FirewallAPI.dll,-28752</Group>
|
|
||||||
</FirewallGroup>
|
|
||||||
</FirewallGroups>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="oobeSystem">
|
|
||||||
<component name="Microsoft-Windows-SecureStartup-FilterDriver" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PreventDeviceEncryption>true</PreventDeviceEncryption>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-EnhancedStorage-Adm" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<TCGSecurityActivationDisabled>1</TCGSecurityActivationDisabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAccounts>
|
|
||||||
<LocalAccounts>
|
|
||||||
<LocalAccount wcm:action="add">
|
|
||||||
<Name>Docker</Name>
|
|
||||||
<Group>Administrators</Group>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</LocalAccount>
|
|
||||||
</LocalAccounts>
|
|
||||||
<AdministratorPassword>
|
|
||||||
<Value>password</Value>
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</AdministratorPassword>
|
|
||||||
</UserAccounts>
|
|
||||||
<AutoLogon>
|
|
||||||
<Username>Docker</Username>
|
|
||||||
<Enabled>true</Enabled>
|
|
||||||
<LogonCount>65432</LogonCount>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</AutoLogon>
|
|
||||||
<Display>
|
|
||||||
<ColorDepth>32</ColorDepth>
|
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
|
||||||
</Display>
|
|
||||||
<OOBE>
|
|
||||||
<HideEULAPage>true</HideEULAPage>
|
|
||||||
<HideLocalAccountScreen>true</HideLocalAccountScreen>
|
|
||||||
<HideOEMRegistrationScreen>true</HideOEMRegistrationScreen>
|
|
||||||
<HideOnlineAccountScreens>true</HideOnlineAccountScreens>
|
|
||||||
<HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
|
|
||||||
<NetworkLocation>Home</NetworkLocation>
|
|
||||||
<ProtectYourPC>3</ProtectYourPC>
|
|
||||||
<SkipUserOOBE>true</SkipUserOOBE>
|
|
||||||
<SkipMachineOOBE>true</SkipMachineOOBE>
|
|
||||||
</OOBE>
|
|
||||||
<RegisteredOrganization>Dockur</RegisteredOrganization>
|
|
||||||
<RegisteredOwner>Windows for Docker</RegisteredOwner>
|
|
||||||
<FirstLogonCommands>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Allow guest access to network shares</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Search from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
</FirstLogonCommands>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
</unattend>
|
|
||||||
@@ -0,0 +1,144 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable Shutdown Event Tracker.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Reliability" /v "ShutdownReasonOn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "FlightSettingsMaxPauseDays" /t REG_DWORD /d 3650 /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesExpiryTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Search from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Task View from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Chat from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-125
@@ -14,7 +14,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -69,7 +69,7 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
@@ -77,7 +77,7 @@
|
|||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -159,13 +159,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Set Network Location to Home</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -205,14 +200,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -220,14 +215,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -245,113 +240,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" /v "SearchboxTaskbarMode" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Search from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -1,366 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<unattend xmlns="urn:schemas-microsoft-com:unattend" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
|
|
||||||
<settings pass="windowsPE">
|
|
||||||
<component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SetupUILanguage>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
</SetupUILanguage>
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UILanguageFallback>en-US</UILanguageFallback>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DiskConfiguration>
|
|
||||||
<Disk wcm:action="add">
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
|
||||||
<CreatePartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Type>EFI</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Microsoft reserved partition (MSR) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Type>MSR</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Type>Primary</Type>
|
|
||||||
<Extend>true</Extend>
|
|
||||||
</CreatePartition>
|
|
||||||
</CreatePartitions>
|
|
||||||
<ModifyPartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<PartitionID>1</PartitionID>
|
|
||||||
<Label>System</Label>
|
|
||||||
<Format>FAT32</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- MSR partition does not need to be modified -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<PartitionID>2</PartitionID>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
<Label>Windows</Label>
|
|
||||||
<Letter>C</Letter>
|
|
||||||
<Format>NTFS</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
</ModifyPartitions>
|
|
||||||
</Disk>
|
|
||||||
</DiskConfiguration>
|
|
||||||
<ImageInstall>
|
|
||||||
<OSImage>
|
|
||||||
<InstallFrom>
|
|
||||||
<MetaData wcm:action="add">
|
|
||||||
<Key>/IMAGE/NAME</Key>
|
|
||||||
<Value>Windows Server 2025 SERVERSTANDARD</Value>
|
|
||||||
</MetaData>
|
|
||||||
</InstallFrom>
|
|
||||||
<InstallTo>
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
</InstallTo>
|
|
||||||
<WillShowUI>OnError</WillShowUI>
|
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
|
||||||
</OSImage>
|
|
||||||
</ImageInstall>
|
|
||||||
<DynamicUpdate>
|
|
||||||
<Enable>true</Enable>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</DynamicUpdate>
|
|
||||||
<UpgradeData>
|
|
||||||
<Upgrade>false</Upgrade>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</UpgradeData>
|
|
||||||
<UserData>
|
|
||||||
<AcceptEula>true</AcceptEula>
|
|
||||||
<FullName>Docker</FullName>
|
|
||||||
<Organization>Windows for Docker</Organization>
|
|
||||||
</UserData>
|
|
||||||
<EnableFirewall>false</EnableFirewall>
|
|
||||||
<Diagnostics>
|
|
||||||
<OptIn>false</OptIn>
|
|
||||||
</Diagnostics>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="offlineServicing">
|
|
||||||
<component name="Microsoft-Windows-LUA-Settings" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<EnableLUA>false</EnableLUA>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="generalize">
|
|
||||||
<component name="Microsoft-Windows-PnPSysprep" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PersistAllDeviceInstalls>true</PersistAllDeviceInstalls>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Security-SPP" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipRearm>1</SkipRearm>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="specialize">
|
|
||||||
<component name="Microsoft-Windows-Security-SPP-UX" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipAutoActivation>true</SkipAutoActivation>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<ComputerName>*</ComputerName>
|
|
||||||
<OEMInformation>
|
|
||||||
<Manufacturer>Dockur</Manufacturer>
|
|
||||||
<Model>Windows for Docker</Model>
|
|
||||||
<SupportHours>24/7</SupportHours>
|
|
||||||
<SupportPhone />
|
|
||||||
<SupportProvider>Dockur</SupportProvider>
|
|
||||||
<SupportURL>https://github.com/dockur/windows/issues</SupportURL>
|
|
||||||
</OEMInformation>
|
|
||||||
<OEMName>Windows for Docker</OEMName>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ErrorReportingCore" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableWER>1</DisableWER>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="wow64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SQMApi" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<CEIPEnabled>0</CEIPEnabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SystemRestore-Main" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableSR>1</DisableSR>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UILanguageFallback>en-US</UILanguageFallback>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Deployment" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<RunSynchronous>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>pnputil -i -a C:\Windows\Drivers\viogpudo\viogpudo.inf</Path>
|
|
||||||
<Description>Install VirtIO display driver</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
</RunSynchronous>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ServerManager-SvrMgrNc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DoNotOpenServerManagerAtLogon>true</DoNotOpenServerManagerAtLogon>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-OutOfBoxExperience" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DoNotOpenInitialConfigurationTasksAtLogon>true</DoNotOpenInitialConfigurationTasksAtLogon>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-RDP-WinStationExtensions" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAuthentication>0</UserAuthentication>
|
|
||||||
</component>
|
|
||||||
<component name="Networking-MPSSVC-Svc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<FirewallGroups>
|
|
||||||
<FirewallGroup wcm:action="add" wcm:keyValue="RemoteDesktop">
|
|
||||||
<Active>true</Active>
|
|
||||||
<Profile>all</Profile>
|
|
||||||
<Group>@FirewallAPI.dll,-28752</Group>
|
|
||||||
</FirewallGroup>
|
|
||||||
</FirewallGroups>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="oobeSystem">
|
|
||||||
<component name="Microsoft-Windows-SecureStartup-FilterDriver" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PreventDeviceEncryption>true</PreventDeviceEncryption>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-EnhancedStorage-Adm" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<TCGSecurityActivationDisabled>1</TCGSecurityActivationDisabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAccounts>
|
|
||||||
<LocalAccounts>
|
|
||||||
<LocalAccount wcm:action="add">
|
|
||||||
<Name>Docker</Name>
|
|
||||||
<Group>Administrators</Group>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</LocalAccount>
|
|
||||||
</LocalAccounts>
|
|
||||||
<AdministratorPassword>
|
|
||||||
<Value>password</Value>
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</AdministratorPassword>
|
|
||||||
</UserAccounts>
|
|
||||||
<AutoLogon>
|
|
||||||
<Username>Docker</Username>
|
|
||||||
<Enabled>true</Enabled>
|
|
||||||
<LogonCount>65432</LogonCount>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</AutoLogon>
|
|
||||||
<Display>
|
|
||||||
<ColorDepth>32</ColorDepth>
|
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
|
||||||
</Display>
|
|
||||||
<OOBE>
|
|
||||||
<HideEULAPage>true</HideEULAPage>
|
|
||||||
<HideLocalAccountScreen>true</HideLocalAccountScreen>
|
|
||||||
<HideOEMRegistrationScreen>true</HideOEMRegistrationScreen>
|
|
||||||
<HideOnlineAccountScreens>true</HideOnlineAccountScreens>
|
|
||||||
<HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
|
|
||||||
<NetworkLocation>Home</NetworkLocation>
|
|
||||||
<ProtectYourPC>3</ProtectYourPC>
|
|
||||||
<SkipUserOOBE>true</SkipUserOOBE>
|
|
||||||
<SkipMachineOOBE>true</SkipMachineOOBE>
|
|
||||||
</OOBE>
|
|
||||||
<RegisteredOrganization>Dockur</RegisteredOrganization>
|
|
||||||
<RegisteredOwner>Windows for Docker</RegisteredOwner>
|
|
||||||
<FirstLogonCommands>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Allow guest access to network shares</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "RequireSecuritySignature" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable SMB signing requirement</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Hide Copilot button</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>cmd /C rd /q C:\Windows.old</CommandLine>
|
|
||||||
<Description>Remove empty Windows.old folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
</FirstLogonCommands>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
</unattend>
|
|
||||||
@@ -0,0 +1,141 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable Shutdown Event Tracker.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Reliability" /v "ShutdownReasonOn" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable the SMB signing requirement.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "RequireSecuritySignature" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable per-CPU clock tick scheduling.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\kernel" /v "EnablePerCpuClockTickScheduling" /t REG_DWORD /d 2 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "FlightSettingsMaxPauseDays" /t REG_DWORD /d 3650 /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseFeatureUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseQualityUpdatesEndTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesStartTime" /t REG_SZ /d "2026-01-01T00:00:00Z" /f
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings" /v "PauseUpdatesExpiryTime" /t REG_SZ /d "2035-12-29T00:00:00Z" /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Remove the empty Windows.old folder.
|
||||||
|
if exist "%SystemDrive%\Windows.old" rd /q "%SystemDrive%\Windows.old"
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
rem Install the VirtIO display driver last to avoid disrupting earlier setup work.
|
||||||
|
pnputil.exe -i -a "%SystemRoot%\Drivers\viogpudo\viogpudo.inf"
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Remove Widgets from the Taskbar.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-135
@@ -14,7 +14,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -69,7 +69,7 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
@@ -77,7 +77,7 @@
|
|||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -159,18 +159,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Set Network Location to Home</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>pnputil -i -a C:\Windows\Drivers\viogpudo\viogpudo.inf</Path>
|
|
||||||
<Description>Install VirtIO display driver</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -210,14 +200,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -225,14 +215,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -250,118 +240,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "RequireSecuritySignature" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable SMB signing requirement</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>powershell.exe -ExecutionPolicy Unrestricted -NoLogo -NoProfile -NonInteractive set-localuser -name "Docker" -passwordneverexpires 1</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowCopilotButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Hide Copilot button</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "ShowTaskViewButton" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Task View from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarDa" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Widgets from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Remove Chat from the Taskbar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>cmd /C rd /q C:\Windows.old</CommandLine>
|
|
||||||
<Description>Remove empty Windows.old folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -1,292 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<unattend xmlns="urn:schemas-microsoft-com:unattend" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
|
|
||||||
<settings pass="windowsPE">
|
|
||||||
<component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SetupUILanguage>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
</SetupUILanguage>
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DiskConfiguration>
|
|
||||||
<WillShowUI>OnError</WillShowUI>
|
|
||||||
<Disk wcm:action="add">
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
|
||||||
<CreatePartitions>
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Type>Primary</Type>
|
|
||||||
<Size>100</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Type>Primary</Type>
|
|
||||||
<Extend>true</Extend>
|
|
||||||
</CreatePartition>
|
|
||||||
</CreatePartitions>
|
|
||||||
<ModifyPartitions>
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Format>NTFS</Format>
|
|
||||||
<Label>System Reserved</Label>
|
|
||||||
<Order>1</Order>
|
|
||||||
<Active>true</Active>
|
|
||||||
<PartitionID>1</PartitionID>
|
|
||||||
<TypeID>0x27</TypeID>
|
|
||||||
</ModifyPartition>
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Active>true</Active>
|
|
||||||
<Format>NTFS</Format>
|
|
||||||
<Label>Windows</Label>
|
|
||||||
<Letter>C</Letter>
|
|
||||||
<Order>2</Order>
|
|
||||||
<PartitionID>2</PartitionID>
|
|
||||||
</ModifyPartition>
|
|
||||||
</ModifyPartitions>
|
|
||||||
</Disk>
|
|
||||||
</DiskConfiguration>
|
|
||||||
<ImageInstall>
|
|
||||||
<OSImage>
|
|
||||||
<InstallFrom>
|
|
||||||
<MetaData wcm:action="add">
|
|
||||||
<Value>Windows 7 Enterprise</Value>
|
|
||||||
<Key>/IMAGE/NAME</Key>
|
|
||||||
</MetaData>
|
|
||||||
</InstallFrom>
|
|
||||||
<InstallTo>
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<PartitionID>2</PartitionID>
|
|
||||||
</InstallTo>
|
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
|
||||||
</OSImage>
|
|
||||||
</ImageInstall>
|
|
||||||
<DynamicUpdate>
|
|
||||||
<Enable>true</Enable>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</DynamicUpdate>
|
|
||||||
<UpgradeData>
|
|
||||||
<Upgrade>false</Upgrade>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</UpgradeData>
|
|
||||||
<UserData>
|
|
||||||
<AcceptEula>true</AcceptEula>
|
|
||||||
<FullName>Docker</FullName>
|
|
||||||
<Organization>Windows for Docker</Organization>
|
|
||||||
</UserData>
|
|
||||||
<EnableFirewall>false</EnableFirewall>
|
|
||||||
<Diagnostics>
|
|
||||||
<OptIn>false</OptIn>
|
|
||||||
</Diagnostics>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="offlineServicing">
|
|
||||||
<component name="Microsoft-Windows-LUA-Settings" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<EnableLUA>false</EnableLUA>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="generalize">
|
|
||||||
<component name="Microsoft-Windows-PnPSysprep" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PersistAllDeviceInstalls>true</PersistAllDeviceInstalls>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Security-SPP" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipRearm>1</SkipRearm>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="specialize">
|
|
||||||
<component name="Microsoft-Windows-Security-SPP-UX" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipAutoActivation>true</SkipAutoActivation>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<ComputerName>*</ComputerName>
|
|
||||||
<OEMInformation>
|
|
||||||
<Manufacturer>Dockur</Manufacturer>
|
|
||||||
<Model>Windows for Docker</Model>
|
|
||||||
</OEMInformation>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ErrorReportingCore" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableWER>1</DisableWER>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="wow64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SQMApi" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<CEIPEnabled>0</CEIPEnabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SystemRestore-Main" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableSR>1</DisableSR>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-RDP-WinStationExtensions" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAuthentication>0</UserAuthentication>
|
|
||||||
</component>
|
|
||||||
<component name="Networking-MPSSVC-Svc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<FirewallGroups>
|
|
||||||
<FirewallGroup wcm:action="add" wcm:keyValue="RemoteDesktop">
|
|
||||||
<Active>true</Active>
|
|
||||||
<Profile>all</Profile>
|
|
||||||
<Group>@FirewallAPI.dll,-28752</Group>
|
|
||||||
</FirewallGroup>
|
|
||||||
</FirewallGroups>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Deployment" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<RunSynchronous>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
</RunSynchronous>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="oobeSystem">
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAccounts>
|
|
||||||
<LocalAccounts>
|
|
||||||
<LocalAccount wcm:action="add">
|
|
||||||
<Name>Docker</Name>
|
|
||||||
<Group>Administrators</Group>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</LocalAccount>
|
|
||||||
</LocalAccounts>
|
|
||||||
<AdministratorPassword>
|
|
||||||
<Value>password</Value>
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</AdministratorPassword>
|
|
||||||
</UserAccounts>
|
|
||||||
<AutoLogon>
|
|
||||||
<Username>Docker</Username>
|
|
||||||
<Enabled>true</Enabled>
|
|
||||||
<LogonCount>65432</LogonCount>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</AutoLogon>
|
|
||||||
<Display>
|
|
||||||
<ColorDepth>32</ColorDepth>
|
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
|
||||||
</Display>
|
|
||||||
<OOBE>
|
|
||||||
<HideEULAPage>true</HideEULAPage>
|
|
||||||
<HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
|
|
||||||
<NetworkLocation>Home</NetworkLocation>
|
|
||||||
<ProtectYourPC>3</ProtectYourPC>
|
|
||||||
<SkipUserOOBE>true</SkipUserOOBE>
|
|
||||||
<SkipMachineOOBE>true</SkipMachineOOBE>
|
|
||||||
</OOBE>
|
|
||||||
<RegisteredOrganization>Dockur</RegisteredOrganization>
|
|
||||||
<RegisteredOwner>Windows for Docker</RegisteredOwner>
|
|
||||||
<FirstLogonCommands>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Allow guest access to network shares</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
</FirstLogonCommands>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
</unattend>
|
|
||||||
@@ -0,0 +1,120 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteAPP to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -57,14 +57,14 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>2</PartitionID>
|
<PartitionID>2</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -156,8 +156,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -170,14 +170,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -185,14 +185,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -207,88 +207,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,120 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteAPP to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-95
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -57,14 +57,14 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>2</PartitionID>
|
<PartitionID>2</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -156,8 +156,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -170,14 +170,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -185,14 +185,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -207,88 +207,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,120 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteAPP to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-95
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -57,14 +57,14 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>2</PartitionID>
|
<PartitionID>2</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -156,8 +156,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -170,14 +170,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -185,14 +185,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -207,88 +207,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,123 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteAPP to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -57,14 +57,14 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>2</PartitionID>
|
<PartitionID>2</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -152,6 +152,15 @@
|
|||||||
</FirewallGroup>
|
</FirewallGroup>
|
||||||
</FirewallGroups>
|
</FirewallGroups>
|
||||||
</component>
|
</component>
|
||||||
|
<component name="Microsoft-Windows-Deployment" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
|
<RunSynchronous>
|
||||||
|
<RunSynchronousCommand wcm:action="add">
|
||||||
|
<Order>1</Order>
|
||||||
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
|
</RunSynchronousCommand>
|
||||||
|
</RunSynchronous>
|
||||||
|
</component>
|
||||||
</settings>
|
</settings>
|
||||||
<settings pass="oobeSystem">
|
<settings pass="oobeSystem">
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
@@ -161,14 +170,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -176,14 +185,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -198,88 +207,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,120 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteAPP to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+22
-93
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -57,14 +57,14 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>2</PartitionID>
|
<PartitionID>2</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -152,6 +152,15 @@
|
|||||||
</FirewallGroup>
|
</FirewallGroup>
|
||||||
</FirewallGroups>
|
</FirewallGroups>
|
||||||
</component>
|
</component>
|
||||||
|
<component name="Microsoft-Windows-Deployment" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
|
<RunSynchronous>
|
||||||
|
<RunSynchronousCommand wcm:action="add">
|
||||||
|
<Order>1</Order>
|
||||||
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
|
</RunSynchronousCommand>
|
||||||
|
</RunSynchronous>
|
||||||
|
</component>
|
||||||
</settings>
|
</settings>
|
||||||
<settings pass="oobeSystem">
|
<settings pass="oobeSystem">
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
@@ -161,14 +170,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -176,14 +185,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -198,88 +207,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,120 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteAPP to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+22
-93
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -57,14 +57,14 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>2</PartitionID>
|
<PartitionID>2</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -152,6 +152,15 @@
|
|||||||
</FirewallGroup>
|
</FirewallGroup>
|
||||||
</FirewallGroups>
|
</FirewallGroups>
|
||||||
</component>
|
</component>
|
||||||
|
<component name="Microsoft-Windows-Deployment" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
|
<RunSynchronous>
|
||||||
|
<RunSynchronousCommand wcm:action="add">
|
||||||
|
<Order>1</Order>
|
||||||
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
|
</RunSynchronousCommand>
|
||||||
|
</RunSynchronous>
|
||||||
|
</component>
|
||||||
</settings>
|
</settings>
|
||||||
<settings pass="oobeSystem">
|
<settings pass="oobeSystem">
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
@@ -161,14 +170,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -176,14 +185,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -198,88 +207,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteAPP to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -1,317 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<unattend xmlns="urn:schemas-microsoft-com:unattend" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
|
|
||||||
<settings pass="windowsPE">
|
|
||||||
<component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SetupUILanguage>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
</SetupUILanguage>
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DiskConfiguration>
|
|
||||||
<Disk wcm:action="add">
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
|
||||||
<CreatePartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Type>EFI</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Microsoft reserved partition (MSR) -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Type>MSR</Type>
|
|
||||||
<Size>128</Size>
|
|
||||||
</CreatePartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<CreatePartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<Type>Primary</Type>
|
|
||||||
<Extend>true</Extend>
|
|
||||||
</CreatePartition>
|
|
||||||
</CreatePartitions>
|
|
||||||
<ModifyPartitions>
|
|
||||||
<!-- System partition (ESP) -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<PartitionID>1</PartitionID>
|
|
||||||
<Label>System</Label>
|
|
||||||
<Format>FAT32</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- MSR partition does not need to be modified -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<PartitionID>2</PartitionID>
|
|
||||||
</ModifyPartition>
|
|
||||||
<!-- Windows partition -->
|
|
||||||
<ModifyPartition wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
<Label>Windows</Label>
|
|
||||||
<Letter>C</Letter>
|
|
||||||
<Format>NTFS</Format>
|
|
||||||
</ModifyPartition>
|
|
||||||
</ModifyPartitions>
|
|
||||||
</Disk>
|
|
||||||
</DiskConfiguration>
|
|
||||||
<ImageInstall>
|
|
||||||
<OSImage>
|
|
||||||
<InstallTo>
|
|
||||||
<DiskID>0</DiskID>
|
|
||||||
<PartitionID>3</PartitionID>
|
|
||||||
</InstallTo>
|
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
|
||||||
</OSImage>
|
|
||||||
</ImageInstall>
|
|
||||||
<DynamicUpdate>
|
|
||||||
<Enable>true</Enable>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</DynamicUpdate>
|
|
||||||
<UpgradeData>
|
|
||||||
<Upgrade>false</Upgrade>
|
|
||||||
<WillShowUI>Never</WillShowUI>
|
|
||||||
</UpgradeData>
|
|
||||||
<UserData>
|
|
||||||
<AcceptEula>true</AcceptEula>
|
|
||||||
<FullName>Docker</FullName>
|
|
||||||
<Organization>Windows for Docker</Organization>
|
|
||||||
</UserData>
|
|
||||||
<EnableFirewall>false</EnableFirewall>
|
|
||||||
<Diagnostics>
|
|
||||||
<OptIn>false</OptIn>
|
|
||||||
</Diagnostics>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="offlineServicing">
|
|
||||||
<component name="Microsoft-Windows-LUA-Settings" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<EnableLUA>false</EnableLUA>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="generalize">
|
|
||||||
<component name="Microsoft-Windows-PnPSysprep" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PersistAllDeviceInstalls>true</PersistAllDeviceInstalls>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Security-SPP" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipRearm>1</SkipRearm>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="specialize">
|
|
||||||
<component name="Microsoft-Windows-Security-SPP-UX" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<SkipAutoActivation>true</SkipAutoActivation>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<ComputerName>*</ComputerName>
|
|
||||||
<OEMInformation>
|
|
||||||
<Manufacturer>Dockur</Manufacturer>
|
|
||||||
<Model>Windows for Docker</Model>
|
|
||||||
</OEMInformation>
|
|
||||||
<OEMName>Windows for Docker</OEMName>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-ErrorReportingCore" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableWER>1</DisableWER>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-IE-InternetExplorer" processorArchitecture="wow64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableAccelerators>true</DisableAccelerators>
|
|
||||||
<DisableFirstRunWizard>true</DisableFirstRunWizard>
|
|
||||||
<Home_Page>https://google.com</Home_Page>
|
|
||||||
<Help_Page>about:blank</Help_Page>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SQMApi" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<CEIPEnabled>0</CEIPEnabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-SystemRestore-Main" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<DisableSR>1</DisableSR>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<InputLocale>0409:00000409</InputLocale>
|
|
||||||
<SystemLocale>en-US</SystemLocale>
|
|
||||||
<UILanguage>en-US</UILanguage>
|
|
||||||
<UserLocale>en-US</UserLocale>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Deployment" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<RunSynchronous>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
|
||||||
<Description>Set Network Location to Home</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
|
||||||
</RunSynchronous>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-TerminalServices-RDP-WinStationExtensions" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAuthentication>0</UserAuthentication>
|
|
||||||
</component>
|
|
||||||
<component name="Networking-MPSSVC-Svc" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<FirewallGroups>
|
|
||||||
<FirewallGroup wcm:action="add" wcm:keyValue="RemoteDesktop">
|
|
||||||
<Active>true</Active>
|
|
||||||
<Profile>all</Profile>
|
|
||||||
<Group>@FirewallAPI.dll,-28752</Group>
|
|
||||||
</FirewallGroup>
|
|
||||||
</FirewallGroups>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
<settings pass="oobeSystem">
|
|
||||||
<component name="Microsoft-Windows-SecureStartup-FilterDriver" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<PreventDeviceEncryption>true</PreventDeviceEncryption>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-EnhancedStorage-Adm" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<TCGSecurityActivationDisabled>1</TCGSecurityActivationDisabled>
|
|
||||||
</component>
|
|
||||||
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
|
||||||
<UserAccounts>
|
|
||||||
<LocalAccounts>
|
|
||||||
<LocalAccount wcm:action="add">
|
|
||||||
<Name>Docker</Name>
|
|
||||||
<Group>Administrators</Group>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</LocalAccount>
|
|
||||||
</LocalAccounts>
|
|
||||||
<AdministratorPassword>
|
|
||||||
<Value>password</Value>
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</AdministratorPassword>
|
|
||||||
</UserAccounts>
|
|
||||||
<AutoLogon>
|
|
||||||
<Username>Docker</Username>
|
|
||||||
<Enabled>true</Enabled>
|
|
||||||
<LogonCount>65432</LogonCount>
|
|
||||||
<Password>
|
|
||||||
<Value />
|
|
||||||
<PlainText>true</PlainText>
|
|
||||||
</Password>
|
|
||||||
</AutoLogon>
|
|
||||||
<Display>
|
|
||||||
<ColorDepth>32</ColorDepth>
|
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
|
||||||
</Display>
|
|
||||||
<OOBE>
|
|
||||||
<HideEULAPage>true</HideEULAPage>
|
|
||||||
<HideLocalAccountScreen>true</HideLocalAccountScreen>
|
|
||||||
<HideOEMRegistrationScreen>true</HideOEMRegistrationScreen>
|
|
||||||
<HideOnlineAccountScreens>true</HideOnlineAccountScreens>
|
|
||||||
<HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
|
|
||||||
<NetworkLocation>Home</NetworkLocation>
|
|
||||||
<ProtectYourPC>3</ProtectYourPC>
|
|
||||||
<SkipUserOOBE>true</SkipUserOOBE>
|
|
||||||
<SkipMachineOOBE>true</SkipMachineOOBE>
|
|
||||||
</OOBE>
|
|
||||||
<RegisteredOrganization>Dockur</RegisteredOrganization>
|
|
||||||
<RegisteredOwner>Windows for Docker</RegisteredOwner>
|
|
||||||
<FirstLogonCommands>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>1</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Allow guest access to network shares</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
</FirstLogonCommands>
|
|
||||||
</component>
|
|
||||||
</settings>
|
|
||||||
</unattend>
|
|
||||||
@@ -0,0 +1,120 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-105
@@ -13,7 +13,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -62,14 +62,14 @@
|
|||||||
<ImageInstall>
|
<ImageInstall>
|
||||||
<OSImage>
|
<OSImage>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -146,13 +146,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Set Network Location to Home</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -186,14 +181,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -201,14 +196,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -226,93 +221,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,120 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Set Network Location to Home
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable the option for passwordless sign-in.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+15
-105
@@ -13,7 +13,7 @@
|
|||||||
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<!-- System partition (ESP) -->
|
<!-- System partition (ESP) -->
|
||||||
@@ -68,14 +68,14 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>3</PartitionID>
|
<PartitionID>3</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
<InstallToAvailablePartition>false</InstallToAvailablePartition>
|
||||||
</OSImage>
|
</OSImage>
|
||||||
</ImageInstall>
|
</ImageInstall>
|
||||||
<DynamicUpdate>
|
<DynamicUpdate>
|
||||||
<Enable>true</Enable>
|
<Enable>false</Enable>
|
||||||
<WillShowUI>Never</WillShowUI>
|
<WillShowUI>Never</WillShowUI>
|
||||||
</DynamicUpdate>
|
</DynamicUpdate>
|
||||||
<UpgradeData>
|
<UpgradeData>
|
||||||
@@ -153,13 +153,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 1 /f</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Set Network Location to Home</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
|
||||||
<RunSynchronousCommand wcm:action="add">
|
|
||||||
<Order>2</Order>
|
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -193,14 +188,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -208,14 +203,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -233,93 +228,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\PasswordLess\Device" /v "DevicePasswordLessBuildVersion" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable option for passwordless sign-in</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v "NoAutoUpdate" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off Windows Update auto download</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,138 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Add RDP in firewall.
|
||||||
|
netsh.exe advfirewall firewall set rule group="@FirewallAPI.dll,-28752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable RDP.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Turn off sidebar.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Windows\Sidebar" /v "TurnOffSidebar" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable screensaver.
|
||||||
|
reg.exe add "HKCU\Control Panel\Desktop" /v "ScreenSaveActive" /t REG_SZ /d 0 /f
|
||||||
|
|
||||||
|
rem Disable screensaver.
|
||||||
|
reg.exe add "HKCU\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\System32\scrnsavex.scr /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -44,7 +44,7 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>1</PartitionID>
|
<PartitionID>1</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
@@ -94,8 +94,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -120,14 +120,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -135,14 +135,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -156,118 +156,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>netsh.exe advfirewall firewall set rule group="@FirewallAPI.dll,-28752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Add RDP in firewall</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable RDP</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Windows\Sidebar" /v "TurnOffSidebar" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off sidebar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\Desktop" /v "ScreenSaveActive" /t REG_SZ /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable screensaver</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\System32\scrnsavex.scr /f</CommandLine>
|
|
||||||
<Description>Disable screensaver</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,138 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Add RDP in firewall.
|
||||||
|
netsh.exe advfirewall firewall set rule group="@FirewallAPI.dll,-28752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable RDP.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Turn off sidebar.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Windows\Sidebar" /v "TurnOffSidebar" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable screensaver.
|
||||||
|
reg.exe add "HKCU\Control Panel\Desktop" /v "ScreenSaveActive" /t REG_SZ /d 0 /f
|
||||||
|
|
||||||
|
rem Disable screensaver.
|
||||||
|
reg.exe add "HKCU\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\System32\scrnsavex.scr /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+14
-124
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -44,7 +44,7 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>1</PartitionID>
|
<PartitionID>1</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
@@ -94,8 +94,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -120,14 +120,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -135,14 +135,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -156,118 +156,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>netsh.exe advfirewall firewall set rule group="@FirewallAPI.dll,-28752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Add RDP in firewall</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable RDP</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Windows\Sidebar" /v "TurnOffSidebar" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off sidebar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\Desktop" /v "ScreenSaveActive" /t REG_SZ /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable screensaver</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\System32\scrnsavex.scr /f</CommandLine>
|
|
||||||
<Description>Disable screensaver</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,138 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Add RDP in firewall.
|
||||||
|
netsh.exe advfirewall firewall set rule group="@FirewallAPI.dll,-28752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable RDP.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Turn off sidebar.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Windows\Sidebar" /v "TurnOffSidebar" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable screensaver.
|
||||||
|
reg.exe add "HKCU\Control Panel\Desktop" /v "ScreenSaveActive" /t REG_SZ /d 0 /f
|
||||||
|
|
||||||
|
rem Disable screensaver.
|
||||||
|
reg.exe add "HKCU\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\System32\scrnsavex.scr /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+14
-124
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -44,7 +44,7 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>1</PartitionID>
|
<PartitionID>1</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
@@ -94,8 +94,8 @@
|
|||||||
<RunSynchronous>
|
<RunSynchronous>
|
||||||
<RunSynchronousCommand wcm:action="add">
|
<RunSynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<Path>C:\Windows\Drivers\Balloon\blnsvr.exe -i</Path>
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
<Description>Install VirtIO Balloon service</Description>
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
</RunSynchronousCommand>
|
</RunSynchronousCommand>
|
||||||
</RunSynchronous>
|
</RunSynchronous>
|
||||||
</component>
|
</component>
|
||||||
@@ -120,14 +120,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -135,14 +135,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -156,118 +156,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>netsh.exe advfirewall firewall set rule group="@FirewallAPI.dll,-28752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Add RDP in firewall</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable RDP</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Windows\Sidebar" /v "TurnOffSidebar" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off sidebar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\Desktop" /v "ScreenSaveActive" /t REG_SZ /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable screensaver</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\System32\scrnsavex.scr /f</CommandLine>
|
|
||||||
<Description>Disable screensaver</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,138 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Add RDP in firewall.
|
||||||
|
netsh.exe advfirewall firewall set rule group="@FirewallAPI.dll,-28752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable RDP.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Turn off sidebar.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Windows\Sidebar" /v "TurnOffSidebar" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable screensaver.
|
||||||
|
reg.exe add "HKCU\Control Panel\Desktop" /v "ScreenSaveActive" /t REG_SZ /d 0 /f
|
||||||
|
|
||||||
|
rem Disable screensaver.
|
||||||
|
reg.exe add "HKCU\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\System32\scrnsavex.scr /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -44,7 +44,7 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>1</PartitionID>
|
<PartitionID>1</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
@@ -90,6 +90,15 @@
|
|||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
<fDenyTSConnections>false</fDenyTSConnections>
|
||||||
</component>
|
</component>
|
||||||
|
<component name="Microsoft-Windows-Deployment" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
|
<RunSynchronous>
|
||||||
|
<RunSynchronousCommand wcm:action="add">
|
||||||
|
<Order>1</Order>
|
||||||
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
|
</RunSynchronousCommand>
|
||||||
|
</RunSynchronous>
|
||||||
|
</component>
|
||||||
</settings>
|
</settings>
|
||||||
<settings pass="oobeSystem">
|
<settings pass="oobeSystem">
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-International-Core" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
@@ -111,14 +120,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -126,14 +135,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -147,118 +156,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>netsh.exe advfirewall firewall set rule group="@FirewallAPI.dll,-28752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Add RDP in firewall</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable RDP</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Windows\Sidebar" /v "TurnOffSidebar" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off sidebar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\Desktop" /v "ScreenSaveActive" /t REG_SZ /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable screensaver</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\System32\scrnsavex.scr /f</CommandLine>
|
|
||||||
<Description>Disable screensaver</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,138 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Add RDP in firewall.
|
||||||
|
netsh.exe advfirewall firewall set rule group="@FirewallAPI.dll,-28752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable RDP.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Turn off sidebar.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Windows\Sidebar" /v "TurnOffSidebar" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable screensaver.
|
||||||
|
reg.exe add "HKCU\Control Panel\Desktop" /v "ScreenSaveActive" /t REG_SZ /d 0 /f
|
||||||
|
|
||||||
|
rem Disable screensaver.
|
||||||
|
reg.exe add "HKCU\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\System32\scrnsavex.scr /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+21
-122
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -44,7 +44,7 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>1</PartitionID>
|
<PartitionID>1</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
@@ -90,6 +90,15 @@
|
|||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
<fDenyTSConnections>false</fDenyTSConnections>
|
||||||
</component>
|
</component>
|
||||||
|
<component name="Microsoft-Windows-Deployment" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
|
<RunSynchronous>
|
||||||
|
<RunSynchronousCommand wcm:action="add">
|
||||||
|
<Order>1</Order>
|
||||||
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
|
</RunSynchronousCommand>
|
||||||
|
</RunSynchronous>
|
||||||
|
</component>
|
||||||
</settings>
|
</settings>
|
||||||
<settings pass="oobeSystem">
|
<settings pass="oobeSystem">
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-International-Core" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
@@ -111,14 +120,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -126,14 +135,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -147,118 +156,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>netsh.exe advfirewall firewall set rule group="@FirewallAPI.dll,-28752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Add RDP in firewall</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable RDP</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Windows\Sidebar" /v "TurnOffSidebar" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off sidebar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\Desktop" /v "ScreenSaveActive" /t REG_SZ /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable screensaver</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\System32\scrnsavex.scr /f</CommandLine>
|
|
||||||
<Description>Disable screensaver</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -0,0 +1,138 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal
|
||||||
|
|
||||||
|
set "SCRIPT_DIR=%~dp0"
|
||||||
|
set "SETUP_STARTED=%SCRIPT_DIR%setup.started"
|
||||||
|
set "SETUP_COMPLETE=%SCRIPT_DIR%setup.complete"
|
||||||
|
|
||||||
|
if "%~1"=="" goto setup
|
||||||
|
if /i "%~1"=="setup" goto setup
|
||||||
|
if /i "%~1"=="logon" goto logon
|
||||||
|
if /i "%~1"=="specialize" goto specialize
|
||||||
|
exit /b 2
|
||||||
|
|
||||||
|
:specialize
|
||||||
|
|
||||||
|
rem Install the VMWare display driver before Windows Setup's final reboot.
|
||||||
|
certutil.exe -addstore -f Root "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
certutil.exe -addstore -f TrustedPublisher "%SystemRoot%\Drivers\vmsvga\vm3d.cer" >nul 2>&1
|
||||||
|
start "" /wait /b pnputil.exe -i -a "%SystemRoot%\Drivers\vmsvga\vm3d.inf" >nul 2>&1
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:setup
|
||||||
|
if exist "%SETUP_COMPLETE%" exit /b 0
|
||||||
|
|
||||||
|
type nul > "%SETUP_STARTED%"
|
||||||
|
|
||||||
|
rem Ignore unclean shutdowns when deciding whether to enter recovery.
|
||||||
|
bcdedit.exe /set {current} bootstatuspolicy IgnoreAllFailures
|
||||||
|
|
||||||
|
rem Keep the blue screen visible after a system crash.
|
||||||
|
bcdedit.exe /set {current} nocrashautoreboot on
|
||||||
|
|
||||||
|
rem Boot the default entry immediately without waiting at the boot menu.
|
||||||
|
bcdedit.exe /timeout 0
|
||||||
|
|
||||||
|
rem Disable automatic reboot after BSOD
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\CrashControl" /v "AutoReboot" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Allow guest access to network shares.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem BEGIN LOCAL_ACCOUNT
|
||||||
|
rem Prevent the local user password from expiring.
|
||||||
|
wmic useraccount where name="Docker" set PasswordExpires=false
|
||||||
|
rem END LOCAL_ACCOUNT
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
POWERCFG -H OFF
|
||||||
|
|
||||||
|
rem Disable monitor blanking.
|
||||||
|
POWERCFG -X -monitor-timeout-ac 0
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable Network Discovery popup.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f
|
||||||
|
|
||||||
|
rem Disable AutoPlay for all drives.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
|
||||||
|
|
||||||
|
rem Disable first-run experience in Edge.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable hibernation in the registry.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable hibernation.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable sleep.
|
||||||
|
POWERCFG -X -standby-timeout-ac 0
|
||||||
|
|
||||||
|
rem Add RDP in firewall.
|
||||||
|
netsh.exe advfirewall firewall set rule group="@FirewallAPI.dll,-28752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable RDP.
|
||||||
|
reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Turn off sidebar.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Windows\Sidebar" /v "TurnOffSidebar" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable RemoteApp to launch unlisted programs.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Disable RemoteApp allowlist.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Turn off automatic Windows Update downloads.
|
||||||
|
reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v "AUOptions" /t REG_DWORD /d 1 /f
|
||||||
|
|
||||||
|
rem Enable Network Discovery.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes
|
||||||
|
|
||||||
|
rem Enable File Sharing.
|
||||||
|
netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes
|
||||||
|
|
||||||
|
rem Install the VirtIO Balloon service once.
|
||||||
|
sc.exe query BalloonService >nul 2>&1
|
||||||
|
if errorlevel 1 "%SystemRoot%\Drivers\Balloon\blnsvr.exe" -i
|
||||||
|
|
||||||
|
rem BEGIN PRODUCT_KEY
|
||||||
|
rem Install the product key without activating Windows immediately.
|
||||||
|
cscript.exe //B //Nologo "%SystemRoot%\System32\slmgr.vbs" /ipk "XXX"
|
||||||
|
rem END PRODUCT_KEY
|
||||||
|
|
||||||
|
type nul > "%SETUP_COMPLETE%"
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
:logon
|
||||||
|
rem Run the machine setup here when the SetupComplete hook was skipped.
|
||||||
|
if not exist "%SETUP_COMPLETE%" call "%~f0" setup
|
||||||
|
|
||||||
|
rem Show file extensions in Explorer.
|
||||||
|
reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f
|
||||||
|
|
||||||
|
rem Disable screensaver.
|
||||||
|
reg.exe add "HKCU\Control Panel\Desktop" /v "ScreenSaveActive" /t REG_SZ /d 0 /f
|
||||||
|
|
||||||
|
rem Disable screensaver.
|
||||||
|
reg.exe add "HKCU\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\System32\scrnsavex.scr /f
|
||||||
|
|
||||||
|
rem BEGIN SHARED_FOLDER
|
||||||
|
rem Add the shared folder to the desktop and map it to drive Z:.
|
||||||
|
if not exist "%USERPROFILE%\Desktop\Shared" mklink /d "%USERPROFILE%\Desktop\Shared" \\host.lan\Data
|
||||||
|
net.exe use Z: \\host.lan\Data /persistent:yes
|
||||||
|
rem END SHARED_FOLDER
|
||||||
|
|
||||||
|
rem BEGIN OEM_SCRIPT
|
||||||
|
rem Launch the custom script asynchronously in a separate visible window.
|
||||||
|
if exist "C:\OEM\install.bat" start "Install" cmd.exe /d /c ""C:\OEM\install.bat""
|
||||||
|
rem END OEM_SCRIPT
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
+21
-122
@@ -14,7 +14,7 @@
|
|||||||
<DiskConfiguration>
|
<DiskConfiguration>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
<Disk wcm:action="add">
|
<Disk wcm:action="add">
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<WillWipeDisk>true</WillWipeDisk>
|
<WillWipeDisk>true</WillWipeDisk>
|
||||||
<CreatePartitions>
|
<CreatePartitions>
|
||||||
<CreatePartition wcm:action="add">
|
<CreatePartition wcm:action="add">
|
||||||
@@ -44,7 +44,7 @@
|
|||||||
</MetaData>
|
</MetaData>
|
||||||
</InstallFrom>
|
</InstallFrom>
|
||||||
<InstallTo>
|
<InstallTo>
|
||||||
<DiskID>0</DiskID>
|
<DiskID>1</DiskID>
|
||||||
<PartitionID>1</PartitionID>
|
<PartitionID>1</PartitionID>
|
||||||
</InstallTo>
|
</InstallTo>
|
||||||
<WillShowUI>OnError</WillShowUI>
|
<WillShowUI>OnError</WillShowUI>
|
||||||
@@ -90,6 +90,15 @@
|
|||||||
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-TerminalServices-LocalSessionManager" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
<fDenyTSConnections>false</fDenyTSConnections>
|
<fDenyTSConnections>false</fDenyTSConnections>
|
||||||
</component>
|
</component>
|
||||||
|
<component name="Microsoft-Windows-Deployment" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
|
<RunSynchronous>
|
||||||
|
<RunSynchronousCommand wcm:action="add">
|
||||||
|
<Order>1</Order>
|
||||||
|
<Path>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs specialize</Path>
|
||||||
|
<Description>Run the specialize pass of the unattended setup script</Description>
|
||||||
|
</RunSynchronousCommand>
|
||||||
|
</RunSynchronous>
|
||||||
|
</component>
|
||||||
</settings>
|
</settings>
|
||||||
<settings pass="oobeSystem">
|
<settings pass="oobeSystem">
|
||||||
<component name="Microsoft-Windows-International-Core" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
<component name="Microsoft-Windows-International-Core" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
|
||||||
@@ -111,14 +120,14 @@
|
|||||||
<Name>Docker</Name>
|
<Name>Docker</Name>
|
||||||
<Group>Administrators</Group>
|
<Group>Administrators</Group>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</LocalAccount>
|
</LocalAccount>
|
||||||
</LocalAccounts>
|
</LocalAccounts>
|
||||||
<AdministratorPassword>
|
<AdministratorPassword>
|
||||||
<Value>password</Value>
|
<Value>YQBkAG0AaQBuAEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</AdministratorPassword>
|
</AdministratorPassword>
|
||||||
</UserAccounts>
|
</UserAccounts>
|
||||||
<AutoLogon>
|
<AutoLogon>
|
||||||
@@ -126,14 +135,14 @@
|
|||||||
<Enabled>true</Enabled>
|
<Enabled>true</Enabled>
|
||||||
<LogonCount>65432</LogonCount>
|
<LogonCount>65432</LogonCount>
|
||||||
<Password>
|
<Password>
|
||||||
<Value />
|
<Value>YQBkAG0AaQBuAFAAYQBzAHMAdwBvAHIAZAA=</Value>
|
||||||
<PlainText>true</PlainText>
|
<PlainText>false</PlainText>
|
||||||
</Password>
|
</Password>
|
||||||
</AutoLogon>
|
</AutoLogon>
|
||||||
<Display>
|
<Display>
|
||||||
<ColorDepth>32</ColorDepth>
|
<ColorDepth>32</ColorDepth>
|
||||||
<HorizontalResolution>1920</HorizontalResolution>
|
<HorizontalResolution>1280</HorizontalResolution>
|
||||||
<VerticalResolution>1080</VerticalResolution>
|
<VerticalResolution>720</VerticalResolution>
|
||||||
</Display>
|
</Display>
|
||||||
<OOBE>
|
<OOBE>
|
||||||
<HideEULAPage>true</HideEULAPage>
|
<HideEULAPage>true</HideEULAPage>
|
||||||
@@ -147,118 +156,8 @@
|
|||||||
<FirstLogonCommands>
|
<FirstLogonCommands>
|
||||||
<SynchronousCommand wcm:action="add">
|
<SynchronousCommand wcm:action="add">
|
||||||
<Order>1</Order>
|
<Order>1</Order>
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "AllowInsecureGuestAuth" /t REG_DWORD /d 1 /f</CommandLine>
|
<CommandLine>wscript.exe //B //NoLogo %WINDIR%\Setup\Scripts\Unattend.vbs logon</CommandLine>
|
||||||
<Description>Allow guest access to network shares</Description>
|
<Description>Configure Windows after logon</Description>
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>3</Order>
|
|
||||||
<CommandLine>cmd /C wmic useraccount where name="Docker" set PasswordExpires=false</CommandLine>
|
|
||||||
<Description>Password Never Expires</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>4</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -H OFF</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>5</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -monitor-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable monitor blanking</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>6</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NewNetworkWindowOff" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>7</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Network\NetworkLocationWizard" /v "HideWizard" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>8</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkList\NewNetworks" /v NetworkList /t REG_MULTI_SZ /d "" /f</CommandLine>
|
|
||||||
<Description>Disable Network Discovery popup</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>9</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Edge" /v "HideFirstRunExperience" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable first-run experience in Edge</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>10</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "HideFileExt" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Show file extensions in Explorer</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>11</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateFileSizePercent" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Zero Hibernation File</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>12</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Power" /v "HibernateEnabled" /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable Hibernation</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>13</Order>
|
|
||||||
<CommandLine>cmd /C POWERCFG -X -standby-timeout-ac 0</CommandLine>
|
|
||||||
<Description>Disable Sleep</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>14</Order>
|
|
||||||
<CommandLine>netsh.exe advfirewall firewall set rule group="@FirewallAPI.dll,-28752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Add RDP in firewall</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>15</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f</CommandLine>
|
|
||||||
<Description>Enable RDP</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>16</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Windows\Sidebar" /v "TurnOffSidebar" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Turn off sidebar</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>17</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\Desktop" /v "ScreenSaveActive" /t REG_SZ /d 0 /f</CommandLine>
|
|
||||||
<Description>Disable screensaver</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>18</Order>
|
|
||||||
<CommandLine>reg.exe add "HKCU\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\System32\scrnsavex.scr /f</CommandLine>
|
|
||||||
<Description>Disable screensaver</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>19</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "fAllowUnlistedRemotePrograms" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Enable RemoteApp to launch unlisted programs</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>20</Order>
|
|
||||||
<CommandLine>reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TSAppAllowList" /v "fDisabledAllowList" /t REG_DWORD /d 1 /f</CommandLine>
|
|
||||||
<Description>Disable RemoteApp allowlist</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>21</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-32752" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable Network Discovery</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>22</Order>
|
|
||||||
<CommandLine>netsh advfirewall firewall set rule group="@FirewallAPI.dll,-28502" new enable=Yes</CommandLine>
|
|
||||||
<Description>Enable File Sharing</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>23</Order>
|
|
||||||
<CommandLine>cmd /C mklink /d %userprofile%\Desktop\Shared \\host.lan\Data</CommandLine>
|
|
||||||
<Description>Create desktop shortcut to shared folder</Description>
|
|
||||||
</SynchronousCommand>
|
|
||||||
<SynchronousCommand wcm:action="add">
|
|
||||||
<Order>24</Order>
|
|
||||||
<CommandLine>cmd /C if exist "C:\OEM\install.bat" start "Install" "cmd /C C:\OEM\install.bat"</CommandLine>
|
|
||||||
<Description>Execute custom script from the OEM folder if exists</Description>
|
|
||||||
</SynchronousCommand>
|
</SynchronousCommand>
|
||||||
</FirstLogonCommands>
|
</FirstLogonCommands>
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
+46
-24
@@ -11,14 +11,15 @@ An empty default means the variable is unset and its value is determined automat
|
|||||||
| `VERSION` | `11` | Windows version to install, such as `10` or `11`. |
|
| `VERSION` | `11` | Windows version to install, such as `10` or `11`. |
|
||||||
| `EDITION` | | Windows edition to install, such as `core` for Windows Server Core. |
|
| `EDITION` | | Windows edition to install, such as `core` for Windows Server Core. |
|
||||||
| `LANGUAGE` | `en-US` | Windows display language, such as `English`, `en-US`, or `en`. |
|
| `LANGUAGE` | `en-US` | Windows display language, such as `English`, `en-US`, or `en`. |
|
||||||
| `REGION` | | Windows regional format. Uses `LANGUAGE` when unset. |
|
| `KEY` | | Windows product key used to install and activate Windows. |
|
||||||
|
| `REGION` | | Regional format. Uses `LANGUAGE` when unset. |
|
||||||
| `KEYBOARD` | | Keyboard layout. Uses `LANGUAGE` when unset. |
|
| `KEYBOARD` | | Keyboard layout. Uses `LANGUAGE` when unset. |
|
||||||
| `USERNAME` | `Docker` | Name of the Windows user account. |
|
| `USERNAME` | `Docker` | Name of the Windows user account. |
|
||||||
| `PASSWORD` | `admin` | Password for the Windows account. |
|
| `PASSWORD` | `admin` | Password for the Windows account. |
|
||||||
| `KEY` | | Windows product key used to install and activate Windows. |
|
| `AUTOLOGIN` | `Y` | Automatically signs in to Windows after startup. |
|
||||||
| `MANUAL` | `N` | Enables manual installation instead of unattended installation. |
|
| `DOMAIN` | | Active Directory domain to join during installation. |
|
||||||
| `VERIFY` | `N` | Verifies downloaded images against a predefined list of checksums. |
|
| `DOMAIN_OU` | | Distinguished name of the organizational unit. |
|
||||||
| `REMOVE` | `Y` | Deletes the downloaded Windows ISO after installation to save space. |
|
| `WORKGROUP` | | Name of the Windows workgroup to join. |
|
||||||
|
|
||||||
## 🧠 CPU and Memory
|
## 🧠 CPU and Memory
|
||||||
|
|
||||||
@@ -27,10 +28,12 @@ An empty default means the variable is unset and its value is determined automat
|
|||||||
| `CPU_CORES` | `2` | Number of virtual CPU cores, such as `4`, `half`, or `max`. |
|
| `CPU_CORES` | `2` | Number of virtual CPU cores, such as `4`, `half`, or `max`. |
|
||||||
| `CPU_MODEL` | `host` | QEMU CPU model. |
|
| `CPU_MODEL` | `host` | QEMU CPU model. |
|
||||||
| `CPU_FLAGS` | | Additional QEMU CPU flags. |
|
| `CPU_FLAGS` | | Additional QEMU CPU flags. |
|
||||||
|
| `SMP` | | Custom CPU topology. Determined from `CPU_CORES` when unset. |
|
||||||
| `KVM` | `Y` | Enables KVM hardware acceleration. |
|
| `KVM` | `Y` | Enables KVM hardware acceleration. |
|
||||||
| `VMX` | `N` | Exposes Intel VMX virtualization extensions to the guest. |
|
| `VMX` | `N` | Exposes Intel VMX virtualization extensions to the guest. |
|
||||||
| `HV` | `Y` | Enables Hyper-V enlightenments for Windows guests. |
|
| `HV` | `Y` | Enables Hyper-V enlightenments for Windows guests. |
|
||||||
| `RAM_SIZE` | `4G` | Amount of RAM assigned to Windows, such as `8G`, `half`, or `max`. |
|
| `RAM_SIZE` | `4G` | Amount of RAM assigned to Windows, such as `8G`, `half`, or `max`. |
|
||||||
|
| `RAM_BACKEND` | | Guest RAM backing mechanism, set `memfd` for memfd-backed memory. |
|
||||||
| `RAM_CHECK` | `Y` | Checks whether enough host memory is available before starting Windows. |
|
| `RAM_CHECK` | `Y` | Checks whether enough host memory is available before starting Windows. |
|
||||||
|
|
||||||
## 💾 Storage
|
## 💾 Storage
|
||||||
@@ -39,12 +42,13 @@ An empty default means the variable is unset and its value is determined automat
|
|||||||
|---|---|---|
|
|---|---|---|
|
||||||
| `DISK_SIZE` | `64G` | Size of the primary disk. |
|
| `DISK_SIZE` | `64G` | Size of the primary disk. |
|
||||||
| `DISK_FMT` | `raw` | Disk image format: `raw` or `qcow2`. |
|
| `DISK_FMT` | `raw` | Disk image format: `raw` or `qcow2`. |
|
||||||
| `DISK_TYPE` | `scsi` | Disk device type, such as `sata`, `scsi`, `nvme`, or `blk`. |
|
| `DISK_TYPE` | `scsi` | Disk device type, such as `ide`, `scsi`, or `blk`. |
|
||||||
| `DISK_CACHE` | `none` | Disk cache mode, such as `none` or `writeback`. |
|
| `DISK_CACHE` | `none` | Disk cache mode, such as `none` or `writeback`. |
|
||||||
| `DISK_IO` | `native` | Disk I/O mode, such as `native`, `threads`, or `io_uring`. |
|
| `DISK_IO` | `native` | Disk I/O mode, such as `native`, `threads`, or `io_uring`. |
|
||||||
| `DISK_DISCARD` | `unmap` | Discard/TRIM mode for the primary disk. |
|
| `DISK_DISCARD` | `unmap` | Discard/TRIM mode for the primary disk. |
|
||||||
| `DISK_ROTATION` | `1` | Rotation rate reported to the guest. Use `1` to identify the disk as an SSD. |
|
| `DISK_ROTATION` | `1` | Rotation rate reported to the guest. Use `1` to identify the disk as an SSD. |
|
||||||
| `DISK_FLAGS` | | Additional options used when creating `qcow2` disks. |
|
| `DISK_FLAGS` | | Additional options used when creating `qcow2` disks. |
|
||||||
|
| `DISK_OPTIONS` | | Additional options appended to QEMU disk devices. |
|
||||||
| `ALLOCATE` | `N` | Preallocates space for the primary disk. |
|
| `ALLOCATE` | `N` | Preallocates space for the primary disk. |
|
||||||
| `STORAGE` | `/storage` | Storage directory used for disks, firmware variables, and downloads. |
|
| `STORAGE` | `/storage` | Storage directory used for disks, firmware variables, and downloads. |
|
||||||
|
|
||||||
@@ -52,15 +56,15 @@ An empty default means the variable is unset and its value is determined automat
|
|||||||
|
|
||||||
| Variable | Default | Description |
|
| Variable | Default | Description |
|
||||||
|---|---|---|
|
|---|---|---|
|
||||||
| `NETWORK` | | Network mode, such as `nat`, `passt`, `slirp`, or `N` to disable networking. |
|
| `NETWORK` | | Network mode, such as `nat`, `user`, or `N` to disable networking. |
|
||||||
| `DHCP` | `N` | Enables macvtap networking so Windows receives an address from the external LAN through DHCP. |
|
| `DHCP` | `N` | Enables macvtap networking so Windows receives a DHCP address. |
|
||||||
| `HOST` | `Windows` | Hostname assigned to Windows. |
|
| `HOST` | | Optional Windows computer name and advertised network hostname. |
|
||||||
| `IP` | | Overrides the automatically selected guest IPv4 address. |
|
| `IP` | | Overrides the automatically selected guest IPv4 address. |
|
||||||
| `MAC` | | Guest network adapter MAC address. |
|
| `MAC` | | Guest network adapter MAC address. |
|
||||||
| `ADAPTER` | `virtio-net-pci` | QEMU network adapter model. |
|
| `ADAPTER` | `virtio-net-pci` | QEMU network adapter model. |
|
||||||
| `DEV` | `eth0` | Container network interface used as the uplink. |
|
| `DEV` | `eth0` | Container network interface used as the uplink. |
|
||||||
| `MTU` | | MTU assigned to the guest network interface. |
|
| `MTU` | | MTU assigned to the guest network interface. |
|
||||||
| `MASK` | `255.255.255.0` | IPv4 netmask. |
|
| `MASK` | `255.255.255.0` | IPv4 netmask for guest network. |
|
||||||
| `TAP` | `qemu` | TAP or macvtap interface name. |
|
| `TAP` | `qemu` | TAP or macvtap interface name. |
|
||||||
| `BRIDGE` | `docker` | Bridge name used for NAT networking. |
|
| `BRIDGE` | `docker` | Bridge name used for NAT networking. |
|
||||||
| `HOST_PORTS` | | Ports excluded from guest forwarding. |
|
| `HOST_PORTS` | | Ports excluded from guest forwarding. |
|
||||||
@@ -77,9 +81,10 @@ An empty default means the variable is unset and its value is determined automat
|
|||||||
|---|---|---|
|
|---|---|---|
|
||||||
| `DISPLAY` | `web` | Display backend, such as `web`, `vnc`, `disabled`, or `none`. |
|
| `DISPLAY` | `web` | Display backend, such as `web`, `vnc`, `disabled`, or `none`. |
|
||||||
| `VGA` | `virtio` | QEMU video adapter model. |
|
| `VGA` | `virtio` | QEMU video adapter model. |
|
||||||
| `WIDTH` | `1920` | Display width configured in Windows. |
|
| `WIDTH` | `1280` | Display width configured in Windows. |
|
||||||
| `HEIGHT` | `1080` | Display height configured in Windows. |
|
| `HEIGHT` | `720` | Display height configured in Windows. |
|
||||||
| `GPU` | `N` | Enables experimental Intel iGPU acceleration. |
|
| `GPU` | `N` | Enables GPU acceleration. |
|
||||||
|
| `VRAM_SIZE` | `4G` | Virtual GPU memory budget. |
|
||||||
| `RENDERNODE` | `/dev/dri/renderD128` | Render node used for GPU acceleration. |
|
| `RENDERNODE` | `/dev/dri/renderD128` | Render node used for GPU acceleration. |
|
||||||
|
|
||||||
## 🌍 Web UI
|
## 🌍 Web UI
|
||||||
@@ -89,11 +94,8 @@ An empty default means the variable is unset and its value is determined automat
|
|||||||
| `WEB` | `Y` | Enables the web interface. |
|
| `WEB` | `Y` | Enables the web interface. |
|
||||||
| `WEB_PORT` | `8006` | Port for the web interface. |
|
| `WEB_PORT` | `8006` | Port for the web interface. |
|
||||||
| `VNC_PORT` | `5900` | Port for the VNC server. |
|
| `VNC_PORT` | `5900` | Port for the VNC server. |
|
||||||
| `WSS_PORT` | `5700` | WebSocket port used by noVNC. |
|
| `LOSSY` | `N` | Enables lossy VNC compression to reduce bandwidth usage. |
|
||||||
| `WSD_PORT` | `8004` | Internal websocketd port used for the display stream. |
|
|
||||||
| `AUDIO` | `N` | Streams guest audio to the web viewer. |
|
| `AUDIO` | `N` | Streams guest audio to the web viewer. |
|
||||||
| `SOUND` | `intel-hda` | QEMU audio device used by the web viewer. |
|
|
||||||
| `AUX_PORT` | `8003` | Internal WebSocket port used for the audio stream. |
|
|
||||||
| `PROTECT` | `N` | Enables password protection for the web interface. |
|
| `PROTECT` | `N` | Enables password protection for the web interface. |
|
||||||
|
|
||||||
## 📁 File Sharing
|
## 📁 File Sharing
|
||||||
@@ -102,15 +104,21 @@ An empty default means the variable is unset and its value is determined automat
|
|||||||
|---|---|---|
|
|---|---|---|
|
||||||
| `SAMBA` | `Y` | Enables the Samba shared folder. |
|
| `SAMBA` | `Y` | Enables the Samba shared folder. |
|
||||||
| `SAMBA_DEBUG` | `N` | Enables Samba debug output. |
|
| `SAMBA_DEBUG` | `N` | Enables Samba debug output. |
|
||||||
|
| `SAMBA_READONLY` | `N` | Enables read-only mode for the shared folder. |
|
||||||
|
| `SHORTCUT` | `Y` | Creates desktop and drive shortcuts to the shared folder. |
|
||||||
|
|
||||||
## ⚙️ System
|
## ⚙️ System
|
||||||
|
|
||||||
| Variable | Default | Description |
|
| Variable | Default | Description |
|
||||||
|---|---|---|
|
|---|---|---|
|
||||||
| `MACHINE` | `q35` | QEMU machine type. |
|
| `MACHINE` | `q35` | QEMU machine type. |
|
||||||
|
| `PCI_BUS` | `pcie.0` | Overrides the PCI bus used for attached devices. |
|
||||||
|
| `RNG` | `Y` | Adds the Virtio RNG device to the machine. |
|
||||||
| `UUID` | | UUID assigned to Windows. |
|
| `UUID` | | UUID assigned to Windows. |
|
||||||
| `HPET` | `off` | QEMU HPET timer setting. |
|
| `HPET` | `N` | HPET timer setting. |
|
||||||
| `VMPORT` | `off` | QEMU VMware port setting. |
|
| `VMPORT` | `N` | VMware port setting. |
|
||||||
|
| `MOUSE` | `usb-tablet` | Pointing device used by the machine. |
|
||||||
|
| `SOUND` | `intel-hda` | Audio device used when `AUDIO=Y`. |
|
||||||
| `SM_BIOS` | | Additional arguments passed to QEMU’s `-smbios` option. |
|
| `SM_BIOS` | | Additional arguments passed to QEMU’s `-smbios` option. |
|
||||||
| `ARGUMENTS` | | Additional raw arguments appended to the QEMU command line. |
|
| `ARGUMENTS` | | Additional raw arguments appended to the QEMU command line. |
|
||||||
|
|
||||||
@@ -120,12 +128,13 @@ An empty default means the variable is unset and its value is determined automat
|
|||||||
|---|---|---|
|
|---|---|---|
|
||||||
| `BOOT_MODE` | `windows` | Boot configuration, such as `windows`, `windows_secure`, or `windows_legacy`. |
|
| `BOOT_MODE` | `windows` | Boot configuration, such as `windows`, `windows_secure`, or `windows_legacy`. |
|
||||||
| `BOOT_INDEX` | `9` | Boot priority index for the installation media. |
|
| `BOOT_INDEX` | `9` | Boot priority index for the installation media. |
|
||||||
|
| `MEDIA_TYPE` | | Device type used for installation media. |
|
||||||
|
| `USB` | `qemu-xhci,id=xhci` | QEMU USB controller configuration. |
|
||||||
| `BIOS` | | Custom firmware file. |
|
| `BIOS` | | Custom firmware file. |
|
||||||
| `TPM` | `N` | Enables the TPM emulator, usually set by `BOOT_MODE`. |
|
| `TPM` | `N` | Enables the TPM emulator, usually set by `BOOT_MODE`. |
|
||||||
| `SMM` | `N` | Enables System Management Mode, usually set by `BOOT_MODE`. |
|
| `SMM` | `N` | Enables System Management Mode, usually set by `BOOT_MODE`. |
|
||||||
| `LOGO` | `Y` | Enables the custom boot logo. |
|
| `LOGO` | `Y` | Enables the custom boot logo. |
|
||||||
| `CLEAR` | `N` | Resets the NVRAM variables on the next boot. |
|
| `CLEAR` | `N` | Resets the NVRAM variables on the next boot. |
|
||||||
| `USB` | `qemu-xhci,id=xhci` | QEMU USB controller configuration. |
|
|
||||||
|
|
||||||
## 🎈 Memory Ballooning
|
## 🎈 Memory Ballooning
|
||||||
|
|
||||||
@@ -145,12 +154,23 @@ Also see [Dynamic memory allocation](https://github.com/qemus/qemu/blob/master/d
|
|||||||
| `BALLOONING_INTERVAL` | `5` | Polling interval in seconds. |
|
| `BALLOONING_INTERVAL` | `5` | Polling interval in seconds. |
|
||||||
| `BALLOONING_DEBUG` | `N` | Enables debug output for the ballooning monitor. |
|
| `BALLOONING_DEBUG` | `N` | Enables debug output for the ballooning monitor. |
|
||||||
|
|
||||||
|
## 💿 Installation
|
||||||
|
|
||||||
|
| Variable | Default | Description |
|
||||||
|
|---|---|---|
|
||||||
|
| `CONNECTIONS` | `4` | Number of connections used for ISO file downloads. |
|
||||||
|
| `MIDO` | `Y` | Enables downloading Windows ISO files directly from Microsoft. |
|
||||||
|
| `ESD` | `Y` | Enables downloading Windows through the ESD-based installation method. |
|
||||||
|
| `VERIFY` | `N` | Verifies downloaded installation media against predefined checksums. |
|
||||||
|
| `REMOVE` | `Y` | Deletes the downloaded Windows ISO after installation to save space. |
|
||||||
|
| `COMMAND` | | Command to be executed during the final step of automatic installation. |
|
||||||
|
|
||||||
## 🔌 Shutdown
|
## 🔌 Shutdown
|
||||||
|
|
||||||
| Variable | Default | Description |
|
| Variable | Default | Description |
|
||||||
|---|---|---|
|
|---|---|---|
|
||||||
| `SHUTDOWN` | `Y` | Enables graceful ACPI shutdown. |
|
| `SHUTDOWN` | `Y` | Enables graceful ACPI shutdown. |
|
||||||
| `TIMEOUT` | `115` | Maximum time, in seconds, to wait before forcing Windows to stop. |
|
| `TIMEOUT` | `105` | Maximum time, in seconds, to wait before forcing Windows to stop. |
|
||||||
|
|
||||||
## 🐞 Debugging
|
## 🐞 Debugging
|
||||||
|
|
||||||
@@ -158,6 +178,8 @@ Also see [Dynamic memory allocation](https://github.com/qemus/qemu/blob/master/d
|
|||||||
|---|---|---|
|
|---|---|---|
|
||||||
| `DEBUG` | `N` | Enables verbose debug output. |
|
| `DEBUG` | `N` | Enables verbose debug output. |
|
||||||
| `TRACE` | `N` | Enables shell command tracing. |
|
| `TRACE` | `N` | Enables shell command tracing. |
|
||||||
| `DETECTED` | | Overrides the automatically detected Windows image identifier. |
|
| `LOG` | `N` | Saves all output from `install.bat` to `C:\OEM\install.log` for troubleshooting. |
|
||||||
| `SERIAL` | `mon:stdio` | QEMU serial device configuration. |
|
| `SERIAL` | `mon:stdio` | QEMU serial device, such as `/storage/serial.sock` or `4444`. |
|
||||||
| `MONITOR` | `unix:$QEMU_DIR/monitor.sock,server,wait=off,nodelay` | QEMU monitor configuration. |
|
| `MONITOR` | | QEMU monitor, such as `/storage/monitor.sock` or `4444`. |
|
||||||
|
| `QMP` | | QEMU Machine Protocol, such as `/storage/qmp.sock` or `4444`. |
|
||||||
|
| `QGA` | | QEMU Guest Agent, such as `/storage/qga.sock` or `4444`. |
|
||||||
|
|||||||
@@ -18,6 +18,8 @@ metadata:
|
|||||||
name: windows
|
name: windows
|
||||||
spec:
|
spec:
|
||||||
replicas: 1
|
replicas: 1
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
app: windows
|
app: windows
|
||||||
|
|||||||
@@ -67,20 +67,20 @@ docker run -it --rm --name windows -e "VERSION=11" -p 8006:8006 --device=/dev/kv
|
|||||||
kubectl apply -f https://raw.githubusercontent.com/dockur/windows/refs/heads/master/kubernetes.yml
|
kubectl apply -f https://raw.githubusercontent.com/dockur/windows/refs/heads/master/kubernetes.yml
|
||||||
```
|
```
|
||||||
|
|
||||||
|
##### Desktop applications
|
||||||
|
|
||||||
|
For a complete graphical desktop experience, see [WinBoat](https://winboat.app), [WinPodX](https://www.winpodx.org), or [WinApps](https://github.com/winapps-org/winapps). Each of these projects uses this container as its backend.
|
||||||
|
|
||||||
##### GitHub Codespaces:
|
##### GitHub Codespaces:
|
||||||
|
|
||||||
[](https://codespaces.new/dockur/windows)
|
[](https://codespaces.new/dockur/windows)
|
||||||
|
|
||||||
##### Graphical installer:
|
|
||||||
|
|
||||||
[](https://winboat.app)
|
|
||||||
|
|
||||||
## Requirements ⚙️
|
## Requirements ⚙️
|
||||||
|
|
||||||
- Docker or Podman on a Linux host with KVM support.
|
- Docker or Podman on a Linux host with KVM support.
|
||||||
- Docker Desktop or Podman (Desktop) on Windows 11 with nested virtualization enabled.
|
- Docker Desktop or Podman (Desktop) on Windows 11 with nested virtualization enabled.
|
||||||
- At least 4 GB of available RAM.
|
- At least 2 GB of available RAM.
|
||||||
- At least 64 GB of free disk space.
|
- At least 32 GB of free disk space.
|
||||||
|
|
||||||
> [!NOTE]
|
> [!NOTE]
|
||||||
> Docker Desktop on Linux, macOS, and Windows 10 does not currently provide KVM access to containers and is therefore not supported.
|
> Docker Desktop on Linux, macOS, and Windows 10 does not currently provide KVM access to containers and is therefore not supported.
|
||||||
@@ -125,6 +125,9 @@ kubectl apply -f https://raw.githubusercontent.com/dockur/windows/refs/heads/mas
|
|||||||
| `vu` | Windows Vista Ultimate | 3.0 GB |
|
| `vu` | Windows Vista Ultimate | 3.0 GB |
|
||||||
| `xp` | Windows XP Professional | 0.6 GB |
|
| `xp` | Windows XP Professional | 0.6 GB |
|
||||||
| `2k` | Windows 2000 Professional | 0.4 GB |
|
| `2k` | Windows 2000 Professional | 0.4 GB |
|
||||||
|
| `me` | Windows ME | 0.5 GB |
|
||||||
|
| `98` | Windows 98 | 0.7 GB |
|
||||||
|
| `95` | Windows 95 | 0.6 GB |
|
||||||
||||
|
||||
|
||||||
| `2025` | Windows Server 2025 | 7.6 GB |
|
| `2025` | Windows Server 2025 | 7.6 GB |
|
||||||
| `2022` | Windows Server 2022 | 6.0 GB |
|
| `2022` | Windows Server 2022 | 6.0 GB |
|
||||||
@@ -133,6 +136,11 @@ kubectl apply -f https://raw.githubusercontent.com/dockur/windows/refs/heads/mas
|
|||||||
| `2012` | Windows Server 2012 | 4.3 GB |
|
| `2012` | Windows Server 2012 | 4.3 GB |
|
||||||
| `2008` | Windows Server 2008 | 3.0 GB |
|
| `2008` | Windows Server 2008 | 3.0 GB |
|
||||||
| `2003` | Windows Server 2003 | 0.6 GB |
|
| `2003` | Windows Server 2003 | 0.6 GB |
|
||||||
|
||||
|
||||||
|
| `core11` | Tiny11 Core | 3.0 GB |
|
||||||
|
| `tiny11` | Tiny11 | 5.3 GB |
|
||||||
|
| `tiny10` | Tiny10 | 3.6 GB |
|
||||||
|
| `reactos` | ReactOS | 0.1 GB |
|
||||||
|
|
||||||
> [!TIP]
|
> [!TIP]
|
||||||
> To install ARM64 versions of Windows use [dockur/windows-arm](https://github.com/dockur/windows-arm/).
|
> To install ARM64 versions of Windows use [dockur/windows-arm](https://github.com/dockur/windows-arm/).
|
||||||
@@ -171,7 +179,7 @@ kubectl apply -f https://raw.githubusercontent.com/dockur/windows/refs/heads/mas
|
|||||||
- ./example:/shared
|
- ./example:/shared
|
||||||
```
|
```
|
||||||
|
|
||||||
Replace the example path `./example` with your desired shared folder, which then will become visible as `Shared`.
|
Replace the example path `./example` with your desired shared folder, which then will become visible as `Shared` on the desktop and as drive `Z:`.
|
||||||
|
|
||||||
### How do I change the amount of CPU or RAM?
|
### How do I change the amount of CPU or RAM?
|
||||||
|
|
||||||
@@ -216,6 +224,22 @@ kubectl apply -f https://raw.githubusercontent.com/dockur/windows/refs/heads/mas
|
|||||||
PASSWORD: "gates"
|
PASSWORD: "gates"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
When `DOMAIN` is set, these variables are used as domain credentials instead.
|
||||||
|
|
||||||
|
### How do I join an Active Directory domain?
|
||||||
|
|
||||||
|
Windows can automatically join an Active Directory domain during installation. Specify the domain name in your compose file:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
environment:
|
||||||
|
DOMAIN: "example.com"
|
||||||
|
DOMAIN_OU: "OU=Virtual Machines,OU=Servers,DC=example,DC=com"
|
||||||
|
```
|
||||||
|
|
||||||
|
Use the domain name, such as `example.com`, rather than a URL. The supplied account is added to the local Administrators group and automatically signed in after installation. `DOMAIN_OU` is optional and specifies where the computer account should be created.
|
||||||
|
|
||||||
|
Windows must be able to resolve and reach the domain controller through the domain's DNS server.
|
||||||
|
|
||||||
### How do I select the Windows language?
|
### How do I select the Windows language?
|
||||||
|
|
||||||
By default, the English version of Windows will be downloaded.
|
By default, the English version of Windows will be downloaded.
|
||||||
@@ -257,9 +281,16 @@ kubectl apply -f https://raw.githubusercontent.com/dockur/windows/refs/heads/mas
|
|||||||
|
|
||||||
Replace the example path `./example.iso` with the filename of your desired ISO file. The value of `VERSION` will be ignored in this case.
|
Replace the example path `./example.iso` with the filename of your desired ISO file. The value of `VERSION` will be ignored in this case.
|
||||||
|
|
||||||
### How do I run a script after installation?
|
### How do I run a command after installation?
|
||||||
|
|
||||||
To run your own script after installation, you can create a file called `install.bat` and place it in a folder together with any additional files it needs (software to be installed for example).
|
To execute a single command during the final step of the automatic installation, add the `COMMAND` environment variable:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
environment:
|
||||||
|
COMMAND: 'reg add "HKLM\Software\Example" /v Enabled /t REG_DWORD /d 1 /f'
|
||||||
|
```
|
||||||
|
|
||||||
|
To run a script or include additional files, create a file called `install.bat` and place it in a folder together with any files it needs, such as software to be installed.
|
||||||
|
|
||||||
Then bind that folder in your compose file like this:
|
Then bind that folder in your compose file like this:
|
||||||
|
|
||||||
@@ -268,18 +299,7 @@ kubectl apply -f https://raw.githubusercontent.com/dockur/windows/refs/heads/mas
|
|||||||
- ./example:/oem
|
- ./example:/oem
|
||||||
```
|
```
|
||||||
|
|
||||||
The example folder `./example` will be copied to `C:\OEM` and the `install.bat` file inside that folder will be executed during the last step of the automatic installation.
|
The example folder `./example` will be copied to `C:\OEM` and the `install.bat` file inside it will be executed during the final step of the automatic installation.
|
||||||
|
|
||||||
### How do I perform a manual installation?
|
|
||||||
|
|
||||||
It's recommended to stick to the automatic installation, as it adjusts various settings to prevent common issues when running Windows inside a virtual environment.
|
|
||||||
|
|
||||||
However, if you insist on performing the installation manually (at your own risk), add the following environment variable to your compose file:
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
environment:
|
|
||||||
MANUAL: "Y"
|
|
||||||
```
|
|
||||||
|
|
||||||
### How do I assign an individual IP address to the container?
|
### How do I assign an individual IP address to the container?
|
||||||
|
|
||||||
|
|||||||
+2234
File diff suppressed because it is too large
Load Diff
+3437
File diff suppressed because it is too large
Load Diff
+1485
-1185
File diff suppressed because it is too large
Load Diff
+1106
File diff suppressed because it is too large
Load Diff
+21
-5
@@ -10,10 +10,17 @@ cd /run
|
|||||||
|
|
||||||
. start.sh # Startup hook
|
. start.sh # Startup hook
|
||||||
. utils.sh # Load functions
|
. utils.sh # Load functions
|
||||||
. reset.sh # Initialize system
|
. init.sh # Initialize system
|
||||||
|
. memory.sh # Check memory
|
||||||
. server.sh # Start webserver
|
. server.sh # Start webserver
|
||||||
|
. download.sh # Load functions
|
||||||
. define.sh # Define versions
|
. define.sh # Define versions
|
||||||
. mido.sh # Download Windows
|
. mido.sh # Download Windows
|
||||||
|
. answer.sh # Modern unattended
|
||||||
|
. batch.sh # Win9x unattended
|
||||||
|
. sif.sh # NT5 unattended
|
||||||
|
. legacy.sh # Legacy installs
|
||||||
|
. image.sh # Detect image files
|
||||||
. install.sh # Run installation
|
. install.sh # Run installation
|
||||||
. disk.sh # Initialize disks
|
. disk.sh # Initialize disks
|
||||||
. display.sh # Initialize graphics
|
. display.sh # Initialize graphics
|
||||||
@@ -23,7 +30,6 @@ cd /run
|
|||||||
. boot.sh # Configure boot
|
. boot.sh # Configure boot
|
||||||
. proc.sh # Initialize processor
|
. proc.sh # Initialize processor
|
||||||
. power.sh # Configure shutdown
|
. power.sh # Configure shutdown
|
||||||
. memory.sh # Check available memory
|
|
||||||
. balloon.sh # Initialize ballooning
|
. balloon.sh # Initialize ballooning
|
||||||
. config.sh # Configure arguments
|
. config.sh # Configure arguments
|
||||||
. finish.sh # Finish initialization
|
. finish.sh # Finish initialization
|
||||||
@@ -47,17 +53,27 @@ sed -u \
|
|||||||
-e 's/failed to load Boot/skipped Boot/g' \
|
-e 's/failed to load Boot/skipped Boot/g' \
|
||||||
-e 's/0): Not Found/0)/g' &
|
-e 's/0): Not Found/0)/g' &
|
||||||
|
|
||||||
|
output=$!
|
||||||
|
|
||||||
if ! enabled "$SHUTDOWN"; then
|
if ! enabled "$SHUTDOWN"; then
|
||||||
exec "${cmd[@]}" ${ARGS:+ $ARGS} >"$pipe"
|
exec "${cmd[@]}" ${ARGS:+ $ARGS} >"$pipe" 2>&1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
"${cmd[@]}" ${ARGS:+ $ARGS} >"$pipe" &
|
if ! interactive; then
|
||||||
|
"${cmd[@]}" ${ARGS:+ $ARGS} >"$pipe" 2>&1 &
|
||||||
|
else
|
||||||
|
startConsole "$pipe"
|
||||||
|
startQemu "${cmd[@]}" ${ARGS:+ $ARGS} >"$pipe" 2>&1
|
||||||
|
fi
|
||||||
|
|
||||||
pid=$!
|
pid=$!
|
||||||
( sleep 30; boot ) &
|
waitForBoot "$pid" 30 &
|
||||||
|
|
||||||
rc=0
|
rc=0
|
||||||
wait "$pid" || rc=$?
|
wait "$pid" || rc=$?
|
||||||
|
interactive && stopConsole
|
||||||
|
wait "$output" || :
|
||||||
|
|
||||||
[ -f "$QEMU_END" ] && exit "$rc"
|
[ -f "$QEMU_END" ] && exit "$rc"
|
||||||
|
|
||||||
sleep 1 & wait $!
|
sleep 1 & wait $!
|
||||||
|
|||||||
+2035
File diff suppressed because it is too large
Load Diff
+1532
-1129
File diff suppressed because it is too large
Load Diff
+375
@@ -0,0 +1,375 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
set -Eeuo pipefail
|
||||||
|
|
||||||
|
setMachine() {
|
||||||
|
|
||||||
|
local id="$1"
|
||||||
|
local iso="$2"
|
||||||
|
local dir="$3"
|
||||||
|
local desc="$4"
|
||||||
|
|
||||||
|
if isLegacy "$id"; then
|
||||||
|
|
||||||
|
if ! legacyInstall "$id" "$iso" "$dir" "$desc"; then
|
||||||
|
error "Failed to prepare $desc ISO!"
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
writeState "mode" "windows_legacy" || return 1
|
||||||
|
|
||||||
|
case "${id,,}" in
|
||||||
|
|
||||||
|
"win9"* | "winnt4" | "win2k"* | "reactos" )
|
||||||
|
|
||||||
|
writeState "old" "pc" || return 1
|
||||||
|
writeState "type" "auto" || return 1 ;;
|
||||||
|
|
||||||
|
esac
|
||||||
|
|
||||||
|
case "${id,,}" in
|
||||||
|
|
||||||
|
"win9"* | "winnt4" )
|
||||||
|
|
||||||
|
writeState "hv" "N" || return 1
|
||||||
|
writeState "usb" "N" || return 1
|
||||||
|
writeState "port" "on" || return 1
|
||||||
|
writeState "net" "pcnet" || return 1
|
||||||
|
writeState "sound" "AC97" || return 1 ;;
|
||||||
|
|
||||||
|
"win2k"* )
|
||||||
|
|
||||||
|
writeState "hv" "N" || return 1
|
||||||
|
writeState "net" "rtl8139" || return 1
|
||||||
|
writeState "usb" "pci-ohci" || return 1
|
||||||
|
writeState "sound" "usb-audio" || return 1 ;;
|
||||||
|
|
||||||
|
"winxpx"* | "win2003"* )
|
||||||
|
|
||||||
|
writeState "hv" "N" || return 1
|
||||||
|
writeState "type" "blk" || return 1
|
||||||
|
writeState "net" "rtl8139" || return 1
|
||||||
|
writeState "sound" "usb-audio" || return 1 ;;
|
||||||
|
|
||||||
|
"reactos" )
|
||||||
|
|
||||||
|
writeState "sound" "AC97" || return 1
|
||||||
|
writeState "net" "rtl8139" || return 1
|
||||||
|
writeState "usb" "pci-ohci" || return 1
|
||||||
|
|
||||||
|
if isReactOSLiveCD "$iso"; then
|
||||||
|
SYSTEM="$iso"
|
||||||
|
createMarker "kill" || return 1
|
||||||
|
fi ;;
|
||||||
|
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
|
||||||
|
case "${id,,}" in
|
||||||
|
|
||||||
|
"winnt4" )
|
||||||
|
writeState "vga" "cirrus" || return 1 ;;
|
||||||
|
|
||||||
|
"win9"* | "win2k"* )
|
||||||
|
writeState "vga" "vmware" || return 1 ;;
|
||||||
|
|
||||||
|
"winxp"* | "win2003"* | "win2008"* | "win2012"* | \
|
||||||
|
"winvista"* | "win7"* | "win8"* | "reactos" )
|
||||||
|
|
||||||
|
writeState "vga" "std" || return 1 ;;
|
||||||
|
|
||||||
|
esac
|
||||||
|
|
||||||
|
restoreMachine || return 1
|
||||||
|
restoreBootMode || return 1
|
||||||
|
|
||||||
|
case "${id,,}" in
|
||||||
|
|
||||||
|
"win95" | "winnt4" )
|
||||||
|
|
||||||
|
# Windows 95 does not support ACPI so disable graceful shutdown
|
||||||
|
createMarker "kill" || return 1 ;;
|
||||||
|
|
||||||
|
esac
|
||||||
|
|
||||||
|
case "${id,,}" in
|
||||||
|
|
||||||
|
"win9"* | "winnt4" | "win2k"* | *"x86"* )
|
||||||
|
|
||||||
|
# Legacy 32-bit Windows may enter an incompatible PAE/DEP path when the
|
||||||
|
# NX flag is exposed, causing installation failures or repeated resets.
|
||||||
|
#
|
||||||
|
# Long mode is unusable by 32-bit guests and may cause the firmware to
|
||||||
|
# allocate PCI resources above 4 GB, which older systems may not handle.
|
||||||
|
|
||||||
|
writeState "flag" "nx=off,lm=off" || return 1 ;;
|
||||||
|
|
||||||
|
esac
|
||||||
|
|
||||||
|
case "${id,,}" in
|
||||||
|
|
||||||
|
"win9"* | "winnt4" | "win2k"* | "winxp"* | "win2003"* | \
|
||||||
|
"winvistax86"* | "win7x86"* | "reactos" )
|
||||||
|
|
||||||
|
if isQ35 "$MACHINE"; then
|
||||||
|
|
||||||
|
# pc-q35-2.11 began advertising a synthetic 64-bit PCI MMIO aperture.
|
||||||
|
# Older Windows ACPI implementations may reject that resource layout,
|
||||||
|
# so retain the pre-2.11 behavior for these guests to prevent a
|
||||||
|
# blue screen on XP and others if the 64 bit PCI hole size is >2G.
|
||||||
|
|
||||||
|
writeState "args" "-global q35-pcihost.x-pci-hole64-fix=false" || return 1
|
||||||
|
|
||||||
|
fi ;;
|
||||||
|
|
||||||
|
esac
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
restoreMachine() {
|
||||||
|
|
||||||
|
isPlatform "x64" || return 0
|
||||||
|
|
||||||
|
# Restore the saved machine only when q35 is still the default;
|
||||||
|
# an explicit user-selected machine must remain untouched.
|
||||||
|
[[ "${MACHINE,,}" != "q35" ]] && return 0
|
||||||
|
|
||||||
|
MACHINE=""
|
||||||
|
restoreState "MACHINE" "old" || return 1
|
||||||
|
|
||||||
|
# Migrate existing Win9x installs to QEMU 11
|
||||||
|
if [[ "${MACHINE,,}" == "pc-i440fx-2.4" ]]; then
|
||||||
|
MACHINE="pc"
|
||||||
|
writeState "old" "$MACHINE" || return 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
[ -z "$MACHINE" ] && MACHINE="q35"
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
restoreMachineState() {
|
||||||
|
|
||||||
|
restoreState "HV" "hv" || return 1
|
||||||
|
restoreState "VGA" "vga" || return 1
|
||||||
|
restoreState "USB" "usb" || return 1
|
||||||
|
restoreState "SOUND" "sound" || return 1
|
||||||
|
restoreState "ADAPTER" "net" || return 1
|
||||||
|
restoreState "VMPORT" "port" || return 1
|
||||||
|
restoreState "CPU_MODEL" "cpu" || return 1
|
||||||
|
restoreState "DISK_TYPE" "type" || return 1
|
||||||
|
|
||||||
|
if [ -z "${BIOS:-}" ] && [ -s "$(stateFile "bios")" ]; then
|
||||||
|
BIOS="$(stateFile "bios")"
|
||||||
|
fi
|
||||||
|
|
||||||
|
mergeState "CPU_FLAGS" "flag" "," || return 1
|
||||||
|
mergeState "ARGUMENTS" "args" " " || return 1
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
restoreBootMode() {
|
||||||
|
|
||||||
|
local current="${BOOT_MODE:-}"
|
||||||
|
|
||||||
|
local mode
|
||||||
|
mode=$(readState "mode") || return 1
|
||||||
|
|
||||||
|
[ -n "$mode" ] || return 0
|
||||||
|
|
||||||
|
# A saved legacy mode always wins. A saved modern mode only replaces the
|
||||||
|
# default mode and never an explicit user-selected boot configuration.
|
||||||
|
if [[ "${mode,,}" == "windows_legacy" ]]; then
|
||||||
|
BOOT_MODE="$mode"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
case "${current,,}" in
|
||||||
|
"" | "windows" | "windows_plain" )
|
||||||
|
BOOT_MODE="$mode" ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
extractDrivers() {
|
||||||
|
|
||||||
|
local drivers="$1"
|
||||||
|
|
||||||
|
rm -rf "$drivers" || return 1
|
||||||
|
mkdir -p "$drivers" || return 1
|
||||||
|
|
||||||
|
if ! bsdtar -xf /var/drivers.txz -C "$drivers"; then
|
||||||
|
error "Failed to extract drivers!"
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
legacyInstall() {
|
||||||
|
|
||||||
|
local id="$1"
|
||||||
|
local iso="$2"
|
||||||
|
local dir="$3"
|
||||||
|
local desc="$4"
|
||||||
|
|
||||||
|
case "${id,,}" in
|
||||||
|
"win9"* )
|
||||||
|
Win9xInstall "$id" "$iso" "$dir" "$desc" || return 1 ;;
|
||||||
|
"win2k"* )
|
||||||
|
SIFInstall "$iso" "$dir" "$desc" "2k" || return 1 ;;
|
||||||
|
"winxp"* )
|
||||||
|
SIFInstall "$iso" "$dir" "$desc" "xp" || return 1 ;;
|
||||||
|
"win2003"* )
|
||||||
|
SIFInstall "$iso" "$dir" "$desc" "2k3" || return 1 ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
isReactOSLiveCD() {
|
||||||
|
|
||||||
|
local iso="$1"
|
||||||
|
local files
|
||||||
|
|
||||||
|
files=$(bsdtar -tf "$iso" 2>/dev/null) || return 1
|
||||||
|
|
||||||
|
! grep -Ei '(^|/)reactos/txtsetup\.sif(;1)?$' <<< "$files" >/dev/null
|
||||||
|
}
|
||||||
|
|
||||||
|
detectReactOS() {
|
||||||
|
|
||||||
|
local dir="$1"
|
||||||
|
local marker
|
||||||
|
|
||||||
|
marker=$(find "$dir" -maxdepth 2 -type f \
|
||||||
|
\( -ipath '*/reactos/reactos.inf' -o -ipath '*/reactos/unattend.inf' \) -print -quit) || return 2
|
||||||
|
|
||||||
|
[ -n "$marker" ] || return 1
|
||||||
|
|
||||||
|
DETECTED="reactos"
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
detectLegacy() {
|
||||||
|
|
||||||
|
local dir="$1"
|
||||||
|
local marker
|
||||||
|
|
||||||
|
isPlatform "x64" || return 1
|
||||||
|
|
||||||
|
# Legacy media is identified from setup marker files rather than WIM
|
||||||
|
# metadata. The order is intentional because several releases share markers.
|
||||||
|
marker=$(find "$dir" -maxdepth 1 -type d -iname 'ia64' -print -quit) || return 2
|
||||||
|
|
||||||
|
if [ -n "$marker" ]; then
|
||||||
|
error "Windows IA-64 (Itanium) images are not supported by this container!"
|
||||||
|
return 2
|
||||||
|
fi
|
||||||
|
|
||||||
|
marker=$(find "$dir" -maxdepth 1 -type d -iname WIN95 -print -quit) || return 2
|
||||||
|
|
||||||
|
if [ -n "$marker" ]; then
|
||||||
|
DETECTED="win95"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
marker=$(find "$dir" -maxdepth 1 -type d -iname WIN98 -print -quit) || return 2
|
||||||
|
|
||||||
|
if [ -n "$marker" ]; then
|
||||||
|
DETECTED="win98"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
marker=$(find "$dir" -maxdepth 1 -type d -iname WIN9X -print -quit) || return 2
|
||||||
|
|
||||||
|
if [ -n "$marker" ]; then
|
||||||
|
DETECTED="win9x"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
marker=$(find "$dir" -maxdepth 1 -type f \
|
||||||
|
\( \
|
||||||
|
-iname CDROM_W.40 -o \
|
||||||
|
-iname CDROM_S.40 -o \
|
||||||
|
-iname CDROM_TS.40 \
|
||||||
|
\) \
|
||||||
|
-print -quit) || return 2
|
||||||
|
|
||||||
|
if [ -n "$marker" ]; then
|
||||||
|
DETECTED="winnt4"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
marker=$(find "$dir" -maxdepth 1 -type f -iname CDROM_NT.5 -print -quit) || return 2
|
||||||
|
|
||||||
|
if [ -n "$marker" ]; then
|
||||||
|
|
||||||
|
marker=$(find "$dir" -maxdepth 1 -type f \
|
||||||
|
\( \
|
||||||
|
-iname CDROM_IA.5 -o \
|
||||||
|
-iname CDROM_ID.5 -o \
|
||||||
|
-iname CDROM_IP.5 -o \
|
||||||
|
-iname CDROM_IS.5 \
|
||||||
|
\) \
|
||||||
|
-print -quit) || return 2
|
||||||
|
|
||||||
|
if [ -n "$marker" ]; then
|
||||||
|
DETECTED="win2k"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
# WIN51 identifies the NT 5.1/5.2 media family; the companion marker then
|
||||||
|
# distinguishes XP x86, XP x64, and Server 2003.
|
||||||
|
marker=$(find "$dir" -maxdepth 1 -iname WIN51 -print -quit) || return 2
|
||||||
|
[ -n "$marker" ] || return 1
|
||||||
|
|
||||||
|
marker=$(find "$dir" -maxdepth 1 -type f -iname WIN51AP -print -quit) || return 2
|
||||||
|
|
||||||
|
if [ -n "$marker" ]; then
|
||||||
|
DETECTED="winxpx64"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
marker=$(find "$dir" -maxdepth 1 -type f \
|
||||||
|
\( \
|
||||||
|
-iname WIN51IC -o \
|
||||||
|
-iname WIN51IP -o \
|
||||||
|
-iname setupxp.htm \
|
||||||
|
\) \
|
||||||
|
-print -quit) || return 2
|
||||||
|
|
||||||
|
if [ -n "$marker" ]; then
|
||||||
|
DETECTED="winxpx86"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
marker=$(find "$dir" -maxdepth 1 -type f \
|
||||||
|
\( \
|
||||||
|
-iname WIN51IS -o \
|
||||||
|
-iname WIN51IA -o \
|
||||||
|
-iname WIN51IB -o \
|
||||||
|
-iname WIN51ID -o \
|
||||||
|
-iname WIN51IL -o \
|
||||||
|
-iname WIN51AA -o \
|
||||||
|
-iname WIN51AD -o \
|
||||||
|
-iname WIN51AS -o \
|
||||||
|
-iname WIN51MA -o \
|
||||||
|
-iname WIN51MD -o \
|
||||||
|
-iname WIN51MP \
|
||||||
|
\) \
|
||||||
|
-print -quit) || return 2
|
||||||
|
|
||||||
|
if [ -n "$marker" ]; then
|
||||||
|
DETECTED="win2003r2"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
|
return 0
|
||||||
+955
-422
File diff suppressed because it is too large
Load Diff
+414
-212
@@ -2,330 +2,532 @@
|
|||||||
set -Eeuo pipefail
|
set -Eeuo pipefail
|
||||||
|
|
||||||
: "${SHUTDOWN:="Y"}" # Graceful ACPI shutdown
|
: "${SHUTDOWN:="Y"}" # Graceful ACPI shutdown
|
||||||
: "${TIMEOUT:="115"}" # QEMU termination timeout
|
: "${TIMEOUT:="105"}" # QEMU termination timeout
|
||||||
|
|
||||||
# Configure QEMU for graceful shutdown
|
# Configure QEMU for graceful shutdown
|
||||||
|
|
||||||
|
SHUTDOWN_SKIP=0
|
||||||
|
SHUTDOWN_SIGNAL=0
|
||||||
|
|
||||||
QEMU_PTY="$QEMU_DIR/qemu.pty"
|
QEMU_PTY="$QEMU_DIR/qemu.pty"
|
||||||
QEMU_END="$QEMU_DIR/qemu.end"
|
QEMU_END="$QEMU_DIR/qemu.end"
|
||||||
|
ACPI_SOCKET="$QEMU_DIR/monitor.sock"
|
||||||
|
CONSOLE_PID="$QEMU_DIR/console.pid"
|
||||||
|
CONSOLE_SOCKET="$QEMU_DIR/console.sock"
|
||||||
|
QEMU_START_PID="$QEMU_DIR/qemu.start.pid"
|
||||||
|
|
||||||
_trap() {
|
UEFI_SHELL_MESSAGE='UEFI Interactive Shell'
|
||||||
|
LEGACY_BOOT_PATTERN='^Booting from (Hard Disk|DVD/CD)'
|
||||||
|
UEFI_BOOT_PATTERN='BdsDxe: starting Boot[[:xdigit:]]{4} '
|
||||||
|
UEFI_NO_BOOT_MESSAGE='BdsDxe: No bootable option or device was found.'
|
||||||
|
UEFI_DVD_BOOT_PATTERN='BdsDxe: starting Boot[[:xdigit:]]{4} "UEFI QEMU .*DVD-ROM'
|
||||||
|
UEFI_USB_BOOT_PATTERN='BdsDxe: starting Boot[[:xdigit:]]{4} "UEFI QEMU .*USB HARDDRIVE'
|
||||||
|
UEFI_WINDOWS_BOOT_PATTERN='BdsDxe: starting Boot[[:xdigit:]]{4} "Windows Boot Manager" from .*HD\('
|
||||||
|
|
||||||
local func="$1"; shift
|
bootStatus() {
|
||||||
local sig
|
|
||||||
TRAP_PID=$BASHPID
|
|
||||||
|
|
||||||
for sig; do
|
[ ! -s "$QEMU_PTY" ] && return 1
|
||||||
trap "$func $sig" "$sig"
|
|
||||||
done
|
|
||||||
|
|
||||||
return 0
|
if isLegacyBoot; then
|
||||||
}
|
local line last recent
|
||||||
|
|
||||||
signalCode() {
|
# Only inspect output produced after the most recent BIOS boot attempt so
|
||||||
|
# stale failures from an earlier device do not affect the current state.
|
||||||
|
line=$(getBootMarker)
|
||||||
|
[ -z "$line" ] && return 1
|
||||||
|
|
||||||
local sig="$1"
|
last="${line#*:}"
|
||||||
|
recent=$(tail -n +"${line%%:*}" "$QEMU_PTY")
|
||||||
|
|
||||||
case "$sig" in
|
grep -Fq "Loading FreeLoader..." <<< "$recent" && return 0
|
||||||
SIGHUP) echo 129 ;;
|
|
||||||
SIGINT) echo 130 ;;
|
|
||||||
SIGQUIT) echo 131 ;;
|
|
||||||
SIGABRT) echo 134 ;;
|
|
||||||
SIGTERM) echo 143 ;;
|
|
||||||
*) echo 0 ;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
return 0
|
if grep -Fq \
|
||||||
}
|
-e "No bootable device." \
|
||||||
|
-e "BOOTMGR is missing" \
|
||||||
|
-e "Replace the disk, and then press any key" \
|
||||||
|
-e "The following file is missing or corrupted:" \
|
||||||
|
-e "Type the name of the Windows loader" \
|
||||||
|
<<< "$recent"; then
|
||||||
|
return 2
|
||||||
|
fi
|
||||||
|
|
||||||
displayReason() {
|
# These BIOS messages only describe the failed device attempt. QEMU may
|
||||||
|
# immediately continue with another boot target, so clear pending success
|
||||||
|
# instead of treating them as a terminal failure.
|
||||||
|
if grep -Fq \
|
||||||
|
-e "Boot failed: not a bootable disk" \
|
||||||
|
-e "Boot failed: Could not read from CDROM" \
|
||||||
|
-e "Boot failed: could not read the boot disk" \
|
||||||
|
<<< "$recent"; then
|
||||||
|
return 5
|
||||||
|
fi
|
||||||
|
|
||||||
local reason="$1"
|
if [[ "$last" == "Booting from Hard Disk"* ]]; then
|
||||||
|
return 3
|
||||||
|
fi
|
||||||
|
|
||||||
case "$reason" in
|
if [[ "$last" == "Booting from DVD/CD"* ]]; then
|
||||||
129 ) echo "SIGHUP" ;;
|
return 4
|
||||||
130 ) echo "SIGINT" ;;
|
fi
|
||||||
131 ) echo "SIGQUIT" ;;
|
|
||||||
134 ) echo "SIGABRT" ;;
|
|
||||||
143 ) echo "SIGTERM" ;;
|
|
||||||
* ) echo "$reason" ;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
readQemuPid() {
|
|
||||||
|
|
||||||
local -n _pid="$1"
|
|
||||||
|
|
||||||
if [ ! -s "$QEMU_PID" ] || ! read -r _pid <"$QEMU_PID"; then
|
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
return 0
|
local line last recent
|
||||||
|
|
||||||
|
# OVMF logs every boot option it tries. Track the newest attempt and only
|
||||||
|
# evaluate messages emitted from that point onward.
|
||||||
|
line=$(getBootMarker)
|
||||||
|
[ -z "$line" ] && return 1
|
||||||
|
|
||||||
|
last="${line#*:}"
|
||||||
|
recent=$(tail -n +"${line%%:*}" "$QEMU_PTY")
|
||||||
|
|
||||||
|
grep -Eq \
|
||||||
|
'BdsDxe: failed to start Boot[[:xdigit:]]{4} "UEFI QEMU .*DVD-ROM.*: Time out' \
|
||||||
|
<<< "$recent" && return 2
|
||||||
|
|
||||||
|
grep -Fq "$UEFI_NO_BOOT_MESSAGE" <<< "$recent" && return 2
|
||||||
|
grep -Fq "$UEFI_SHELL_MESSAGE" <<< "$recent" && return 2
|
||||||
|
|
||||||
|
# A failed device attempt is transitional because OVMF may immediately try
|
||||||
|
# another boot target. Clear pending success and wait for the next attempt.
|
||||||
|
grep -Eq \
|
||||||
|
'BdsDxe: failed to start Boot[[:xdigit:]]{4} ' \
|
||||||
|
<<< "$recent" && return 5
|
||||||
|
|
||||||
|
grep -Eq "$UEFI_WINDOWS_BOOT_PATTERN" <<< "$last" && return 3
|
||||||
|
|
||||||
|
grep -Eq \
|
||||||
|
-e '"UEFI QEMU .*DVD-ROM' \
|
||||||
|
-e 'CDROM\(' \
|
||||||
|
-e 'USB\(' \
|
||||||
|
<<< "$last" && return 4
|
||||||
|
|
||||||
|
return 1
|
||||||
}
|
}
|
||||||
|
|
||||||
bootFailed() {
|
waitForBoot() {
|
||||||
|
|
||||||
local fail=""
|
local pid="$1"
|
||||||
|
local timeout="${2:-30}"
|
||||||
|
local keySent=0
|
||||||
|
local keyWait=0
|
||||||
|
local pendingType=0
|
||||||
|
local pendingLine=""
|
||||||
|
local pendingDeadline=0
|
||||||
|
local status marker
|
||||||
|
local deadline=$((SECONDS + timeout))
|
||||||
|
local screen="visit http://127.0.0.1:$WEB_PORT/ to view the screen..."
|
||||||
|
|
||||||
if [[ "${BOOT_MODE,,}" == "windows_legacy" ]]; then
|
while isAlive "$pid"; do
|
||||||
grep -Fq "No bootable device." "$QEMU_PTY" && fail="y"
|
|
||||||
grep -Fq "BOOTMGR is missing" "$QEMU_PTY" && fail="y"
|
# The boot prompt is only an opportunistic early trigger because some
|
||||||
|
# Windows versions do not expose it on the PTY until much later.
|
||||||
|
if (( ! keySent )) && needsBootKey; then
|
||||||
|
|
||||||
|
if [ -s "$QEMU_PTY" ] && grep -Fq "Press any key to boot from" "$QEMU_PTY"; then
|
||||||
|
if sendKey ret 0 500; then
|
||||||
|
keySent=1
|
||||||
|
fi
|
||||||
|
elif bootKeyReady; then
|
||||||
|
(( keyWait += 1 ))
|
||||||
|
|
||||||
|
if isLegacyBoot; then
|
||||||
|
# Keep the legacy fallback at about one second after the DVD marker.
|
||||||
|
if (( keyWait >= 5 )); then
|
||||||
|
if sendKey ret 0 100 6 0.25; then
|
||||||
|
keySent=1
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
elif (( keyWait >= 1 )); then
|
||||||
|
# Modern Windows usually needs blind timing, so start earlier.
|
||||||
|
if sendKey ret 0 100 6 0.25; then
|
||||||
|
keySent=1
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
keyWait=0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
[ -n "$fail" ]
|
fi
|
||||||
}
|
|
||||||
|
|
||||||
boot() {
|
if bootStatus; then
|
||||||
|
status=0
|
||||||
|
else
|
||||||
|
status=$?
|
||||||
|
fi
|
||||||
|
|
||||||
|
case "$status" in
|
||||||
|
|
||||||
|
0) echo
|
||||||
|
|
||||||
|
if [[ "${DISPLAY,,}" == "web" ]] && ! disabled "${WEB:-Y}"; then
|
||||||
|
info "$(app) started successfully, $screen"
|
||||||
|
else
|
||||||
|
info "$(app) started successfully."
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo && return 0 ;;
|
||||||
|
|
||||||
|
2) echo
|
||||||
|
|
||||||
|
error "$(app) could not boot, terminating..."
|
||||||
|
terminateQemu
|
||||||
|
return 0 ;;
|
||||||
|
|
||||||
|
3 | 4)
|
||||||
|
|
||||||
|
marker=$(getBootMarker)
|
||||||
|
|
||||||
|
# A firmware boot line alone is not proof that the guest started. Wait
|
||||||
|
# briefly for a more definitive success or failure message, restarting
|
||||||
|
# the grace period whenever firmware begins a different boot attempt.
|
||||||
|
if [[ "$marker" != "$pendingLine" ]] || (( status != pendingType )); then
|
||||||
|
pendingLine="$marker"
|
||||||
|
pendingType=$status
|
||||||
|
|
||||||
|
pendingDeadline=$((SECONDS + 6))
|
||||||
|
fi
|
||||||
|
|
||||||
|
if (( pendingDeadline > 0 && SECONDS >= pendingDeadline )); then
|
||||||
|
echo
|
||||||
|
|
||||||
|
if [[ "${DISPLAY,,}" == "web" ]] && ! disabled "${WEB:-Y}"; then
|
||||||
|
info "$(app) started successfully, $screen"
|
||||||
|
else
|
||||||
|
info "$(app) started successfully."
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo && return 0
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
|
||||||
|
5)
|
||||||
|
|
||||||
|
# A failed device attempt is transitional because firmware may continue
|
||||||
|
# with another target. Discard any pending success decision.
|
||||||
|
pendingType=0
|
||||||
|
pendingLine=""
|
||||||
|
pendingDeadline=0
|
||||||
|
;;
|
||||||
|
|
||||||
|
*)
|
||||||
|
|
||||||
|
pendingType=0
|
||||||
|
pendingLine=""
|
||||||
|
pendingDeadline=0
|
||||||
|
;;
|
||||||
|
|
||||||
|
esac
|
||||||
|
|
||||||
|
(( SECONDS >= deadline )) && break
|
||||||
|
|
||||||
|
sleep 0.25
|
||||||
|
done
|
||||||
|
|
||||||
|
isAlive "$pid" || return 0
|
||||||
[ -f "$QEMU_END" ] && return 0
|
[ -f "$QEMU_END" ] && return 0
|
||||||
|
|
||||||
if [ -s "$QEMU_PTY" ]; then
|
error "Timeout while waiting for QEMU to boot the machine, terminating..."
|
||||||
if [ "$(stat -c%s "$QEMU_PTY")" -gt 7 ]; then
|
terminateQemu
|
||||||
if ! bootFailed; then
|
|
||||||
info "$(app) started successfully, visit http://127.0.0.1:8006/ to view the screen..."
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
error "Timeout while waiting for QEMU to boot the machine, aborting..."
|
|
||||||
sKill "$QEMU_PID"
|
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
legacyBootReady() {
|
legacyBootReady() {
|
||||||
|
|
||||||
local last
|
local line last recent
|
||||||
local bios="Booting from Hard"
|
local hard="Booting from Hard"
|
||||||
|
local cdrom="Booting from DVD/CD"
|
||||||
|
|
||||||
last=$(grep "^Booting.*" "$QEMU_PTY" | tail -1)
|
line=$(grep -n "^Booting.*" "$QEMU_PTY" | tail -1)
|
||||||
[[ "${last,,}" != "${bios,,}"* ]] && return 1
|
[ -z "$line" ] && return 1
|
||||||
grep -Fq "No bootable device." "$QEMU_PTY" && return 1
|
|
||||||
grep -Fq "BOOTMGR is missing" "$QEMU_PTY" && return 1
|
last="${line#*:}"
|
||||||
|
recent=$(tail -n +"${line%%:*}" "$QEMU_PTY")
|
||||||
|
|
||||||
|
# ACPI shutdown is safe once BIOS has handed control to the hard disk, unless
|
||||||
|
# the same attempt already produced a known boot failure.
|
||||||
|
[[ "${last,,}" != "${hard,,}"* ]] && return 1
|
||||||
|
|
||||||
|
grep -Fq "Loading FreeLoader..." <<< "$recent" && return 0
|
||||||
|
grep -Fq "No bootable device." <<< "$recent" && return 1
|
||||||
|
grep -Fq "BOOTMGR is missing" <<< "$recent" && return 1
|
||||||
|
grep -Fq "Replace the disk, and then press any key" <<< "$recent" && return 1
|
||||||
|
grep -Fq "Boot failed: not a bootable disk" <<< "$recent" && return 1
|
||||||
|
grep -Fq "Boot failed: could not read the boot disk" <<< "$recent" && return 1
|
||||||
|
grep -Fq "The following file is missing or corrupted:" <<< "$recent" && return 1
|
||||||
|
grep -Fq "Type the name of the Windows loader" <<< "$recent" && return 1
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
ready() {
|
ready() {
|
||||||
|
|
||||||
[ -f "$STORAGE/windows.boot" ] && return 0
|
# The marker means installation completed previously, so shutdown
|
||||||
|
# no longer needs to infer guest readiness from firmware output.
|
||||||
|
hasBootMarker && return 0
|
||||||
|
|
||||||
[ ! -s "$QEMU_PTY" ] && return 1
|
[ ! -s "$QEMU_PTY" ] && return 1
|
||||||
|
|
||||||
if [[ "${BOOT_MODE,,}" == "windows_legacy" ]]; then
|
if isLegacyBoot; then
|
||||||
legacyBootReady && return 0
|
legacyBootReady && return 0
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
local line="\"Windows Boot Manager\""
|
local line last recent
|
||||||
grep -Fq "$line" "$QEMU_PTY" && return 0
|
|
||||||
|
|
||||||
return 1
|
line=$(getBootMarker)
|
||||||
|
[ -z "$line" ] && return 1
|
||||||
|
|
||||||
|
last="${line#*:}"
|
||||||
|
recent=$(tail -n +"${line%%:*}" "$QEMU_PTY")
|
||||||
|
|
||||||
|
# Only a Windows Boot Manager entry loaded from a hard disk proves that setup
|
||||||
|
# has progressed far enough for an ACPI shutdown request to be appropriate.
|
||||||
|
grep -Eq "$UEFI_WINDOWS_BOOT_PATTERN" <<< "$last" || return 1
|
||||||
|
|
||||||
|
# Reject failures emitted after this exact boot attempt. Without these checks,
|
||||||
|
# a failed Windows Boot Manager entry remains classified as ready indefinitely.
|
||||||
|
grep -Eq \
|
||||||
|
'BdsDxe: failed to start Boot[[:xdigit:]]{4} "Windows Boot Manager"' \
|
||||||
|
<<< "$recent" && return 1
|
||||||
|
|
||||||
|
grep -Fq "$UEFI_NO_BOOT_MESSAGE" <<< "$recent" && return 1
|
||||||
|
grep -Fq "$UEFI_SHELL_MESSAGE" <<< "$recent" && return 1
|
||||||
|
|
||||||
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
forceKillQemu() {
|
sendKey() {
|
||||||
|
|
||||||
local reason="$1"
|
local key="$1"
|
||||||
local pid=""
|
local delay="${2:-0}"
|
||||||
local display
|
local hold="${3:-100}"
|
||||||
|
local repeat="${4:-1}"
|
||||||
|
local interval="${5:-0}"
|
||||||
|
local i output
|
||||||
|
|
||||||
! readQemuPid pid && return 0
|
[ ! -S "$ACPI_SOCKET" ] && return 1
|
||||||
! isAlive "$pid" && return 0
|
[[ "$delay" != "0" ]] && sleep "$delay"
|
||||||
|
|
||||||
display=$(displayReason "$reason")
|
# Send all repeats through one monitor connection so timing remains stable
|
||||||
error "Forcefully terminating $(app), reason: $display..."
|
# and QEMU receives the sequence as one operation.
|
||||||
{ disown "$pid" || :; kill -9 -- "$pid" || :; } 2>/dev/null
|
if ! output=$(
|
||||||
|
{
|
||||||
|
for ((i = 1; i <= repeat; i++)); do
|
||||||
|
printf 'sendkey %s %s\n' "$key" "$hold"
|
||||||
|
|
||||||
|
if (( i < repeat )); then
|
||||||
|
sleep "$interval"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
} | nc -q 1 -w 1 -U "$ACPI_SOCKET" 2>&1
|
||||||
|
); then
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# The human monitor may return success at the transport level while reporting
|
||||||
|
# a command error in its text response, so inspect that output explicitly.
|
||||||
|
if grep -Eqi \
|
||||||
|
-e 'unknown command' \
|
||||||
|
-e 'unknown key' \
|
||||||
|
-e 'invalid parameter' \
|
||||||
|
-e 'invalid key' \
|
||||||
|
-e '^error:' \
|
||||||
|
<<< "$output"; then
|
||||||
|
|
||||||
|
warn "failed to send boot key through QEMU monitor!"
|
||||||
|
|
||||||
|
if enabled "${DEBUG:-}"; then
|
||||||
|
echo "$output"
|
||||||
|
fi
|
||||||
|
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
needsBootKey() {
|
||||||
|
|
||||||
|
hasImage "$BOOT" || return 1
|
||||||
|
|
||||||
|
hasCompletedInstall && return 1
|
||||||
|
supportsBootKey "$DETECTED" || return 1
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
bootKeyReady() {
|
||||||
|
|
||||||
|
[ ! -s "$QEMU_PTY" ] && return 1
|
||||||
|
|
||||||
|
if isLegacyBoot; then
|
||||||
|
grep -Fq "Booting from DVD/CD" "$QEMU_PTY"
|
||||||
|
return $?
|
||||||
|
fi
|
||||||
|
|
||||||
|
if isPlatform "arm64"; then
|
||||||
|
grep -Eq "$UEFI_USB_BOOT_PATTERN" "$QEMU_PTY"
|
||||||
|
else
|
||||||
|
grep -Eq "$UEFI_DVD_BOOT_PATTERN" "$QEMU_PTY"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
getBootMarker() {
|
||||||
|
|
||||||
|
if isLegacyBoot; then
|
||||||
|
grep -nE "$LEGACY_BOOT_PATTERN" "$QEMU_PTY" | tail -1
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
grep -nE "$UEFI_BOOT_PATTERN" "$QEMU_PTY" | tail -1
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
markWindowsBooted() {
|
markWindowsBooted() {
|
||||||
|
|
||||||
local file="$STORAGE/windows.boot"
|
if hasBootMarker || [ ! -f "$BOOT" ]; then
|
||||||
|
|
||||||
if [ -f "$file" ] || [ ! -f "$BOOT" ]; then
|
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Remove CD-ROM ISO after install
|
# Do not remove installation media until firmware output confirms Windows is
|
||||||
! ready && return 0
|
# now booting from the installed disk rather than from setup media.
|
||||||
|
ready || return 0
|
||||||
|
|
||||||
touch "$file"
|
createMarker "boot" || return 0
|
||||||
! setOwner "$file" && error "Failed to set the owner for \"$file\" !"
|
|
||||||
|
|
||||||
if ! disabled "$REMOVE"; then
|
if ! disabled "$REMOVE"; then
|
||||||
rm -f "$BOOT" 2>/dev/null || true
|
case "${BOOT,,}" in
|
||||||
|
*.img | *.raw | *.qcow2 ) ;;
|
||||||
|
* ) removeImage "$BOOT" || : ;;
|
||||||
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
return 0
|
rm -f "$STORAGE/setup.img" 2>/dev/null || :
|
||||||
}
|
|
||||||
|
|
||||||
cleanupHelpers() {
|
|
||||||
|
|
||||||
local pids=( "${SMB_PID:-}" "${NMB_PID:-}" "${DDN_PID:-}" \
|
|
||||||
"${TPM_PID:-}" "${WSD_PID:-}" "${WEB_PID:-}" \
|
|
||||||
"${AUX_PID:-}" "${AUDIO_PID:-}" "${PASST_PID:-}" \
|
|
||||||
"${DNSMASQ_PID:-}" "${BALLOONING_PID:-}" )
|
|
||||||
|
|
||||||
mKill "${pids[@]}"
|
|
||||||
|
|
||||||
closeNetwork
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
finish() {
|
finish() {
|
||||||
|
|
||||||
local reason=$1
|
local reason=$1 failed=0
|
||||||
touch "$QEMU_END"
|
|
||||||
|
# A nonzero exit is unexpected only when QEMU_END is missing.
|
||||||
|
if [ ! -f "$QEMU_END" ] && (( reason != 0 )); then
|
||||||
|
failed=1
|
||||||
|
fi
|
||||||
|
|
||||||
|
touch "$QEMU_END" || :
|
||||||
|
|
||||||
forceKillQemu "$reason"
|
forceKillQemu "$reason"
|
||||||
|
|
||||||
if [ ! -f "$STORAGE/windows.boot" ]; then
|
if ! hasBootMarker; then
|
||||||
markWindowsBooted
|
markWindowsBooted
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cleanupHelpers
|
cleanupHelpers "${SMB_PID:-}" "${NMB_PID:-}" "${DDN_PID:-}"
|
||||||
|
|
||||||
if ! waitPidFile "$QEMU_PID" 10; then
|
if ! waitQemuExit 10; then
|
||||||
warn "Timed out while waiting for $(app) to exit!"
|
warn "Timed out while waiting for $(app) to exit!"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
(( reason != 1 )) && echo && echo "❯ Shutdown completed!"
|
stopConsole
|
||||||
|
echo
|
||||||
|
|
||||||
|
if (( failed == 0 )); then
|
||||||
|
echo "❯ Shutdown completed!"
|
||||||
|
else
|
||||||
|
error "QEMU exited unexpectedly!"
|
||||||
|
fi
|
||||||
|
|
||||||
exit "$reason"
|
exit "$reason"
|
||||||
}
|
}
|
||||||
|
|
||||||
normalizeTimeout() {
|
gracefulShutdown() {
|
||||||
|
|
||||||
local term_grace=3 # seconds before loop ends to send SIGTERM
|
|
||||||
local cleanup_grace=3 # seconds reserved after the loop for cleanup
|
|
||||||
local min
|
|
||||||
|
|
||||||
TIMEOUT=$(strip "$TIMEOUT")
|
|
||||||
if [[ ! "$TIMEOUT" =~ ^[0-9]+$ ]]; then
|
|
||||||
TIMEOUT=115
|
|
||||||
fi
|
|
||||||
|
|
||||||
if (( TIMEOUT >= 30 )); then
|
|
||||||
term_grace=5
|
|
||||||
cleanup_grace=5
|
|
||||||
elif (( TIMEOUT >= 15 )); then
|
|
||||||
term_grace=4
|
|
||||||
cleanup_grace=4
|
|
||||||
fi
|
|
||||||
|
|
||||||
min=$((term_grace + cleanup_grace + 1))
|
|
||||||
(( TIMEOUT < min )) && (( TIMEOUT = min ))
|
|
||||||
|
|
||||||
wait_until=$((TIMEOUT - cleanup_grace))
|
|
||||||
sigterm_at=$((wait_until - term_grace))
|
|
||||||
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
sendAcpiShutdown() {
|
|
||||||
|
|
||||||
[ ! -S "$QEMU_DIR/monitor.sock" ] && return 0
|
|
||||||
|
|
||||||
# Send ACPI shutdown signal
|
|
||||||
nc -q 1 -w 1 -U "$QEMU_DIR/monitor.sock" &> /dev/null <<<'system_powerdown' || :
|
|
||||||
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
abortDuringSetup() {
|
|
||||||
|
|
||||||
local code="$1"
|
|
||||||
info "Cannot send ACPI signal during $(app) setup, aborting..."
|
|
||||||
|
|
||||||
sKill "$QEMU_PID"
|
|
||||||
|
|
||||||
if ! waitPidFile "$QEMU_PID" 5; then
|
|
||||||
warn "Timed out while waiting for $(app) to exit!"
|
|
||||||
fi
|
|
||||||
|
|
||||||
finish "$code"
|
|
||||||
}
|
|
||||||
|
|
||||||
waitForShutdown() {
|
|
||||||
|
|
||||||
local cnt=0
|
|
||||||
local pid="$1"
|
|
||||||
local name="$APP"
|
|
||||||
local slp
|
|
||||||
|
|
||||||
while (( cnt <= wait_until )); do
|
|
||||||
|
|
||||||
sleep 1 &
|
|
||||||
slp=$!
|
|
||||||
|
|
||||||
# Stop waiting if the process has exited
|
|
||||||
! isAlive "$pid" && break
|
|
||||||
|
|
||||||
# Workaround for stale/zombie QEMU pid file
|
|
||||||
[ ! -s "$QEMU_PID" ] && break
|
|
||||||
|
|
||||||
if (( cnt == sigterm_at )); then
|
|
||||||
info "${name^} is still running, sending SIGTERM... ($cnt/$wait_until)"
|
|
||||||
kill -15 -- "$pid" 2>/dev/null || :
|
|
||||||
elif (( cnt > 0 )); then
|
|
||||||
info "Waiting for $name to shut down... ($cnt/$wait_until)"
|
|
||||||
fi
|
|
||||||
|
|
||||||
sendAcpiShutdown
|
|
||||||
|
|
||||||
wait "$slp"
|
|
||||||
(( cnt++ ))
|
|
||||||
|
|
||||||
done
|
|
||||||
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
graceful_shutdown() {
|
|
||||||
|
|
||||||
local sig="$1"
|
local sig="$1"
|
||||||
local pid=""
|
local pid code
|
||||||
local code=0
|
|
||||||
|
|
||||||
|
# Traps can run in subshells created by pipelines or command substitutions;
|
||||||
|
# only the original shell may coordinate QEMU shutdown.
|
||||||
[[ $BASHPID != "$TRAP_PID" ]] && return
|
[[ $BASHPID != "$TRAP_PID" ]] && return
|
||||||
|
|
||||||
code=$(signalCode "$sig")
|
code=$(signalCode "$sig")
|
||||||
|
|
||||||
if [ -f "$QEMU_END" ]; then
|
if (( SHUTDOWN_SIGNAL != 0 )); then
|
||||||
echo && info "Received $1 signal while already shutting down..."
|
|
||||||
|
# A second Ctrl-C during an active shutdown skips the remaining grace period
|
||||||
|
# and lets the shutdown loop force QEMU down immediately.
|
||||||
|
if (( code == 130 && SHUTDOWN_SIGNAL == code )); then
|
||||||
|
SHUTDOWN_SKIP=1
|
||||||
|
echo && info "Received SIGINT again, forcing shutdown..."
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
|
|
||||||
set +e
|
echo && info "Received $sig signal while already shutting down..."
|
||||||
touch "$QEMU_END"
|
return
|
||||||
echo && info "Received $1 signal, sending ACPI shutdown signal..."
|
|
||||||
|
|
||||||
if ! readQemuPid pid; then
|
|
||||||
warn "QEMU PID file ($QEMU_PID) does not exist?"
|
|
||||||
finish "$code"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if ! isAlive "$pid"; then
|
SHUTDOWN_SIGNAL=$code
|
||||||
|
|
||||||
|
# Signal handlers must complete their own error handling and cleanup without
|
||||||
|
# errexit terminating the shell partway through the shutdown sequence.
|
||||||
|
set +e
|
||||||
|
touch "$QEMU_END"
|
||||||
|
|
||||||
|
echo && info "Received $sig signal, sending ACPI shutdown signal..."
|
||||||
|
|
||||||
|
# Interactive startup may receive a signal before the PID file appears, so
|
||||||
|
# briefly wait for it there; non-interactive operation fails immediately.
|
||||||
|
if ! readQemuPid pid; then
|
||||||
|
if ! interactive || ! waitQemuPid pid; then
|
||||||
|
warn "QEMU PID file does not exist?"
|
||||||
|
finish "$code"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z "$pid" ] || ! isAlive "$pid"; then
|
||||||
warn "QEMU process with PID $pid does not exist?"
|
warn "QEMU process with PID $pid does not exist?"
|
||||||
finish "$code"
|
finish "$code"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if ! ready; then
|
if hasMarker "kill"; then
|
||||||
abortDuringSetup "$code"
|
|
||||||
|
info "This $(app) version does not support ACPI shutdown, decreasing timeout to 1 second..."
|
||||||
|
TIMEOUT=7
|
||||||
|
|
||||||
|
elif ! ready || { hasSystemImage && ! hasBootMarker; }; then
|
||||||
|
|
||||||
|
info "$(app) will ignore ACPI signals during setup, decreasing timeout to 10 seconds..."
|
||||||
|
TIMEOUT=13
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
normalizeTimeout
|
normalizeTimeout 105
|
||||||
waitForShutdown "$pid"
|
waitForShutdown "$pid"
|
||||||
|
|
||||||
finish "$code"
|
finish "$code"
|
||||||
}
|
}
|
||||||
|
|
||||||
! enabled "$SHUTDOWN" && return 0
|
enableTrap() {
|
||||||
|
|
||||||
|
enabled "$SHUTDOWN" || return 0
|
||||||
|
|
||||||
|
# Keep Ctrl-C available to interactive users without installing an unnecessary
|
||||||
|
# SIGINT handler for background/container execution.
|
||||||
|
if interactive; then
|
||||||
|
_trap gracefulShutdown SIGINT
|
||||||
|
fi
|
||||||
|
|
||||||
|
_trap gracefulShutdown SIGTERM SIGHUP SIGABRT SIGQUIT
|
||||||
|
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
[ -n "${QEMU_TIMEOUT:-}" ] && TIMEOUT="$QEMU_TIMEOUT"
|
[ -n "${QEMU_TIMEOUT:-}" ] && TIMEOUT="$QEMU_TIMEOUT"
|
||||||
|
|
||||||
_trap graceful_shutdown SIGTERM SIGHUP SIGABRT SIGQUIT
|
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
|
|||||||
+152
-53
@@ -3,15 +3,17 @@ set -Eeuo pipefail
|
|||||||
|
|
||||||
: "${SAMBA:="Y"}" # Enable Samba
|
: "${SAMBA:="Y"}" # Enable Samba
|
||||||
: "${SAMBA_DEBUG:="N"}" # Disable debug
|
: "${SAMBA_DEBUG:="N"}" # Disable debug
|
||||||
|
: "${SAMBA_READONLY:="N"}" # Disable writes
|
||||||
tmp="/tmp/smb"
|
: "${SAMBA_CONFIG:="/etc/samba/smb.conf"}"
|
||||||
rm -rf "$tmp"
|
|
||||||
|
|
||||||
DDN_PID="/var/run/wsdd.pid"
|
DDN_PID="/var/run/wsdd.pid"
|
||||||
NMB_PID="/var/run/samba/nmbd.pid"
|
NMB_PID="/var/run/samba/nmbd.pid"
|
||||||
SMB_PID="/var/run/samba/smbd.pid"
|
SMB_PID="/var/run/samba/smbd.pid"
|
||||||
|
|
||||||
rm -f "$SMB_PID" "$NMB_PID" "$DDN_PID"
|
if ! rm -f "$SMB_PID" "$NMB_PID" "$DDN_PID"; then
|
||||||
|
error "Failed to clean Samba PID files!"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
disabled "$SAMBA" && return 0
|
disabled "$SAMBA" && return 0
|
||||||
disabled "$NETWORK" && return 0
|
disabled "$NETWORK" && return 0
|
||||||
@@ -19,25 +21,34 @@ disabled "$NETWORK" && return 0
|
|||||||
configureNetwork() {
|
configureNetwork() {
|
||||||
|
|
||||||
if enabled "$DHCP"; then
|
if enabled "$DHCP"; then
|
||||||
socket="$UPLINK"
|
|
||||||
hostname="$UPLINK"
|
|
||||||
interfaces="$DEV"
|
|
||||||
else
|
|
||||||
hostname="host.lan"
|
|
||||||
|
|
||||||
if isUserMode; then
|
SAMBA_HOSTNAME="$UPLINK"
|
||||||
interfaces="lo"
|
SAMBA_INTERFACES="$DEV"
|
||||||
socket="127.0.0.1"
|
|
||||||
else
|
else
|
||||||
socket="$IP"
|
|
||||||
interfaces="$BRIDGE"
|
SAMBA_HOSTNAME="host.lan"
|
||||||
|
|
||||||
|
# User-mode networking has no host bridge to bind to, so expose Samba only
|
||||||
|
# through loopback and let QEMU's forwarding provide guest access.
|
||||||
|
if isUserMode; then
|
||||||
|
SAMBA_INTERFACES="lo"
|
||||||
|
else
|
||||||
|
SAMBA_INTERFACES="$BRIDGE"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -n "${SAMBA_INTERFACE:-}" ]; then
|
if [ -n "${SAMBA_INTERFACE:-}" ]; then
|
||||||
interfaces+=",$SAMBA_INTERFACE"
|
SAMBA_INTERFACES+=",$SAMBA_INTERFACE"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# NetBIOS names are limited to 15 visible characters.
|
||||||
|
SAMBA_NETBIOS="${SAMBA_HOSTNAME%%.*}"
|
||||||
|
SAMBA_NETBIOS="${SAMBA_NETBIOS:0:15}"
|
||||||
|
|
||||||
|
[ -z "$SAMBA_NETBIOS" ] && SAMBA_NETBIOS="host"
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -46,7 +57,8 @@ writeReadme() {
|
|||||||
local dir="$1"
|
local dir="$1"
|
||||||
local ref="$2"
|
local ref="$2"
|
||||||
|
|
||||||
{ echo "--------------------------------------------------------"
|
if ! {
|
||||||
|
echo "--------------------------------------------------------"
|
||||||
echo " $APP for $ENGINE v$(</etc/version)..."
|
echo " $APP for $ENGINE v$(</etc/version)..."
|
||||||
echo " For support visit $SUPPORT"
|
echo " For support visit $SUPPORT"
|
||||||
echo "--------------------------------------------------------"
|
echo "--------------------------------------------------------"
|
||||||
@@ -64,7 +76,10 @@ writeReadme() {
|
|||||||
echo ""
|
echo ""
|
||||||
echo "Replace the example path ./example with your desired shared folder, which then will become visible here."
|
echo "Replace the example path ./example with your desired shared folder, which then will become visible here."
|
||||||
echo ""
|
echo ""
|
||||||
} | unix2dos > "$dir/readme.txt"
|
} | unix2dos > "$dir/readme.txt"; then
|
||||||
|
error "Failed to write shared folder readme!"
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
@@ -76,7 +91,11 @@ addShare() {
|
|||||||
local name="$3"
|
local name="$3"
|
||||||
local comment="$4"
|
local comment="$4"
|
||||||
local cfg="$5"
|
local cfg="$5"
|
||||||
local owner=""
|
local owner probe
|
||||||
|
local empty="N"
|
||||||
|
local writable="N"
|
||||||
|
local readonly="N"
|
||||||
|
local tmp="/tmp/smb"
|
||||||
|
|
||||||
if [ ! -d "$dir" ]; then
|
if [ ! -d "$dir" ]; then
|
||||||
if ! mkdir -p "$dir"; then
|
if ! mkdir -p "$dir"; then
|
||||||
@@ -85,18 +104,58 @@ addShare() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if ! ls -A "$dir" >/dev/null 2>&1; then
|
if ! ls -A "$dir" >/dev/null 2>&1; then
|
||||||
msg="No permission to access shared folder ($dir)."
|
local msg="No permission to access shared folder ($dir)."
|
||||||
msg+=" If SELinux is active, you need to add the \":Z\" flag to the bind mount."
|
msg+=" If SELinux is active, you need to add the \":Z\" flag to the bind mount."
|
||||||
error "$msg" && return 1
|
error "$msg" && return 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -w "$dir" ]; then
|
if [ -z "$(ls -A "$dir")" ]; then
|
||||||
msg="shared folder ($dir) is not writeable!"
|
empty="Y"
|
||||||
warn "$msg"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -z "$(ls -A "$dir")" ]; then
|
# The generated fallback share contains only instructions and must never be
|
||||||
|
# writable from the guest.
|
||||||
|
if [[ "$dir" == "$tmp" ]]; then
|
||||||
|
|
||||||
|
readonly="Y"
|
||||||
|
|
||||||
|
elif enabled "$SAMBA_READONLY"; then
|
||||||
|
|
||||||
|
readonly="Y"
|
||||||
|
|
||||||
|
# Test actual write access instead of relying on mount flags or mode bits,
|
||||||
|
# which may not reflect bind-mount and host filesystem restrictions.
|
||||||
|
elif probe=$(mktemp "$dir/.samba-write-test.XXXXXX" 2>/dev/null); then
|
||||||
|
|
||||||
|
writable="Y"
|
||||||
|
|
||||||
|
if ! rm -f "$probe"; then
|
||||||
|
error "Failed to remove write test file ($probe)."
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Empty bind mounts are safe to initialize with shared-directory permissions.
|
||||||
|
# Retry the write probe afterward because the original mode may have blocked it.
|
||||||
|
elif [[ "$empty" == "Y" ]] && chmod 2777 "$dir" 2>/dev/null; then
|
||||||
|
|
||||||
|
if probe=$(mktemp "$dir/.samba-write-test.XXXXXX" 2>/dev/null); then
|
||||||
|
|
||||||
|
writable="Y"
|
||||||
|
|
||||||
|
if ! rm -f "$probe"; then
|
||||||
|
error "Failed to remove write test file ($probe)."
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "$writable" == "Y" ]]; then
|
||||||
|
|
||||||
|
if [[ "$empty" == "Y" ]]; then
|
||||||
|
|
||||||
|
# Keep newly created content in the shared group through the setgid bit.
|
||||||
if ! chmod 2777 "$dir"; then
|
if ! chmod 2777 "$dir"; then
|
||||||
error "Failed to set permissions for directory $dir" && return 1
|
error "Failed to set permissions for directory $dir" && return 1
|
||||||
fi
|
fi
|
||||||
@@ -106,6 +165,8 @@ addShare() {
|
|||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Docker commonly creates a missing bind source as root. Transfer an empty
|
||||||
|
# directory to the default non-root owner used for shared content.
|
||||||
if [[ "$owner" == "0" ]]; then
|
if [[ "$owner" == "0" ]]; then
|
||||||
if ! chown "1000:1000" "$dir"; then
|
if ! chown "1000:1000" "$dir"; then
|
||||||
error "Failed to set ownership for directory $dir" && return 1
|
error "Failed to set ownership for directory $dir" && return 1
|
||||||
@@ -114,6 +175,13 @@ addShare() {
|
|||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
elif [[ "$readonly" != "Y" ]]; then
|
||||||
|
|
||||||
|
# Preserve access to non-writable mounts by exporting them read-only.
|
||||||
|
readonly="Y"
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
if [[ "$dir" == "$tmp" ]]; then
|
if [[ "$dir" == "$tmp" ]]; then
|
||||||
writeReadme "$dir" "$ref" || return 1
|
writeReadme "$dir" "$ref" || return 1
|
||||||
fi
|
fi
|
||||||
@@ -123,7 +191,13 @@ addShare() {
|
|||||||
echo "[$name]"
|
echo "[$name]"
|
||||||
echo " path = $dir"
|
echo " path = $dir"
|
||||||
echo " comment = $comment"
|
echo " comment = $comment"
|
||||||
echo " writable = yes"
|
|
||||||
|
if [[ "$readonly" == "Y" ]]; then
|
||||||
|
echo " read only = yes"
|
||||||
|
else
|
||||||
|
echo " read only = no"
|
||||||
|
fi
|
||||||
|
|
||||||
echo " guest ok = yes"
|
echo " guest ok = yes"
|
||||||
echo " guest only = yes"
|
echo " guest only = yes"
|
||||||
} >> "$cfg"; then
|
} >> "$cfg"; then
|
||||||
@@ -136,23 +210,30 @@ addShare() {
|
|||||||
|
|
||||||
writeConfig() {
|
writeConfig() {
|
||||||
|
|
||||||
{ echo "[global]"
|
if ! {
|
||||||
|
echo "[global]"
|
||||||
echo " server string = Dockur"
|
echo " server string = Dockur"
|
||||||
echo " netbios name = $hostname"
|
echo " netbios name = $SAMBA_NETBIOS"
|
||||||
echo " workgroup = WORKGROUP"
|
echo " workgroup = WORKGROUP"
|
||||||
echo " interfaces = $interfaces"
|
echo " interfaces = $SAMBA_INTERFACES"
|
||||||
echo " bind interfaces only = yes"
|
echo " bind interfaces only = yes"
|
||||||
echo " socket address = $socket"
|
|
||||||
echo " security = user"
|
echo " security = user"
|
||||||
echo " guest account = nobody"
|
echo " guest account = nobody"
|
||||||
echo " map to guest = Bad User"
|
echo " map to guest = Bad User"
|
||||||
|
|
||||||
|
# Retain SMB1 negotiation for legacy Windows guests.
|
||||||
echo " server min protocol = NT1"
|
echo " server min protocol = NT1"
|
||||||
|
|
||||||
|
# Allow bind-mounted shares to follow symlinks outside their share root.
|
||||||
echo " follow symlinks = yes"
|
echo " follow symlinks = yes"
|
||||||
echo " wide links = yes"
|
echo " wide links = yes"
|
||||||
echo " unix extensions = no"
|
echo " unix extensions = no"
|
||||||
echo " inherit owner = yes"
|
echo " inherit owner = yes"
|
||||||
echo " create mask = 0666"
|
echo " create mask = 0666"
|
||||||
echo " directory mask = 02777"
|
echo " directory mask = 02777"
|
||||||
|
|
||||||
|
# Perform guest filesystem access as root so bind mounts with differing host
|
||||||
|
# ownership remain usable; share-level read-only checks still apply.
|
||||||
echo " force user = root"
|
echo " force user = root"
|
||||||
echo " force group = root"
|
echo " force group = root"
|
||||||
echo " force create mode = 0666"
|
echo " force create mode = 0666"
|
||||||
@@ -163,18 +244,30 @@ writeConfig() {
|
|||||||
echo " printing = bsd"
|
echo " printing = bsd"
|
||||||
echo " printcap name = /dev/null"
|
echo " printcap name = /dev/null"
|
||||||
echo " disable spoolss = yes"
|
echo " disable spoolss = yes"
|
||||||
} > "$SAMBA_CONFIG"
|
} > "$SAMBA_CONFIG"; then
|
||||||
|
error "Failed to write Samba config \"$SAMBA_CONFIG\" !"
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
selectPrimaryShare() {
|
selectPrimaryShare() {
|
||||||
|
|
||||||
share="/shared"
|
local tmp="/tmp/smb"
|
||||||
[ ! -d "$share" ] && [ -d "$STORAGE/shared" ] && share="$STORAGE/shared"
|
|
||||||
[ ! -d "$share" ] && [ -d "/data" ] && share="/data"
|
if ! rm -rf "$tmp"; then
|
||||||
[ ! -d "$share" ] && [ -d "$STORAGE/data" ] && share="$STORAGE/data"
|
error "Failed to clean temporary Samba folder!"
|
||||||
[ ! -d "$share" ] && share="$tmp"
|
return 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Prefer explicit root-level bind mounts, then storage-local compatibility
|
||||||
|
# paths. When none exist, publish an instructional read-only share.
|
||||||
|
SAMBA_SHARE="/shared"
|
||||||
|
[ ! -d "$SAMBA_SHARE" ] && [ -d "$STORAGE/shared" ] && SAMBA_SHARE="$STORAGE/shared"
|
||||||
|
[ ! -d "$SAMBA_SHARE" ] && [ -d "/data" ] && SAMBA_SHARE="/data"
|
||||||
|
[ ! -d "$SAMBA_SHARE" ] && [ -d "$STORAGE/data" ] && SAMBA_SHARE="$STORAGE/data"
|
||||||
|
[ ! -d "$SAMBA_SHARE" ] && SAMBA_SHARE="$tmp"
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
@@ -185,6 +278,8 @@ addOptionalShare() {
|
|||||||
local ref="/shared$index"
|
local ref="/shared$index"
|
||||||
local name="Data$index"
|
local name="Data$index"
|
||||||
|
|
||||||
|
# Optional shares are best-effort and must not prevent the primary share or
|
||||||
|
# Samba service from starting.
|
||||||
if [ -d "$ref" ]; then
|
if [ -d "$ref" ]; then
|
||||||
addShare "$ref" "$ref" "$name" "Shared" "$SAMBA_CONFIG" || :
|
addShare "$ref" "$ref" "$name" "Shared" "$SAMBA_CONFIG" || :
|
||||||
elif [ -d "/data$index" ]; then
|
elif [ -d "/data$index" ]; then
|
||||||
@@ -196,13 +291,13 @@ addOptionalShare() {
|
|||||||
|
|
||||||
prepareSambaDirs() {
|
prepareSambaDirs() {
|
||||||
|
|
||||||
# Create directories if missing
|
|
||||||
mkdir -p \
|
mkdir -p \
|
||||||
/var/lib/samba/sysvol \
|
/var/lib/samba/sysvol \
|
||||||
/var/lib/samba/private \
|
/var/lib/samba/private \
|
||||||
/var/lib/samba/bind-dns || return 1
|
/var/lib/samba/bind-dns || return 1
|
||||||
|
|
||||||
# Try to repair Samba permissions
|
# Runtime directories may retain restrictive modes from earlier daemon runs
|
||||||
|
# or package defaults, so repair only the known Samba lock and core paths.
|
||||||
[ -d /run/samba/msg.lock ] && chmod -R 0755 /run/samba/msg.lock 2>/dev/null || :
|
[ -d /run/samba/msg.lock ] && chmod -R 0755 /run/samba/msg.lock 2>/dev/null || :
|
||||||
[ -d /var/log/samba/cores ] && chmod -R 0700 /var/log/samba/cores 2>/dev/null || :
|
[ -d /var/log/samba/cores ] && chmod -R 0700 /var/log/samba/cores 2>/dev/null || :
|
||||||
[ -d /var/cache/samba/msg.lock ] && chmod -R 0755 /var/cache/samba/msg.lock 2>/dev/null || :
|
[ -d /var/cache/samba/msg.lock ] && chmod -R 0755 /var/cache/samba/msg.lock 2>/dev/null || :
|
||||||
@@ -227,8 +322,10 @@ startDaemon() {
|
|||||||
local log="$2"
|
local log="$2"
|
||||||
shift 2
|
shift 2
|
||||||
|
|
||||||
rm -f "$log"
|
rm -f "$log" || :
|
||||||
|
|
||||||
|
# Keep initialization alive after a daemon startup failure so its log can be
|
||||||
|
# streamed and the actual Samba error remains visible to the user.
|
||||||
if ! "$@"; then
|
if ! "$@"; then
|
||||||
SAMBA_DEBUG="Y"
|
SAMBA_DEBUG="Y"
|
||||||
error "Failed to start $name daemon!"
|
error "Failed to start $name daemon!"
|
||||||
@@ -248,7 +345,6 @@ startSamba() {
|
|||||||
|
|
||||||
startNetbios() {
|
startNetbios() {
|
||||||
|
|
||||||
# Enable NetBIOS on Windows 7 and lower
|
|
||||||
enabled "$DEBUG" && echo "Starting NetBIOS daemon..."
|
enabled "$DEBUG" && echo "Starting NetBIOS daemon..."
|
||||||
|
|
||||||
startDaemon "NetBIOS" "/var/log/samba/log.nmbd" \
|
startDaemon "NetBIOS" "/var/log/samba/log.nmbd" \
|
||||||
@@ -259,40 +355,43 @@ startNetbios() {
|
|||||||
|
|
||||||
startWsddn() {
|
startWsddn() {
|
||||||
|
|
||||||
# Enable Web Service Discovery on Vista and up
|
|
||||||
enabled "$DEBUG" && echo "Starting wsddn daemon..."
|
enabled "$DEBUG" && echo "Starting wsddn daemon..."
|
||||||
|
|
||||||
|
# wsddn accepts one interface, while Samba may bind to an additional
|
||||||
|
# user-supplied interface as well.
|
||||||
startDaemon "wsddn" "/var/log/wsddn.log" \
|
startDaemon "wsddn" "/var/log/wsddn.log" \
|
||||||
wsddn -i "${interfaces%%,*}" -H "$hostname" \
|
wsddn -i "${SAMBA_INTERFACES%%,*}" -H "$SAMBA_HOSTNAME" \
|
||||||
--unixd --log-file=/var/log/wsddn.log --pid-file="$DDN_PID"
|
--unixd --log-file=/var/log/wsddn.log --pid-file="$DDN_PID"
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
configureNetwork
|
configureNetwork || return 0
|
||||||
|
|
||||||
html "Initializing shared folder..."
|
html "Initializing shared folder..."
|
||||||
SAMBA_CONFIG="/etc/samba/smb.conf"
|
|
||||||
enabled "$DEBUG" && echo "Starting Samba daemon..."
|
enabled "$DEBUG" && echo "Starting Samba daemon..."
|
||||||
|
|
||||||
writeConfig || return 1
|
writeConfig || return 0
|
||||||
|
selectPrimaryShare || return 0
|
||||||
|
|
||||||
# Add shared folders
|
addShare "$SAMBA_SHARE" "/shared" "Data" "Shared" "$SAMBA_CONFIG" || return 0
|
||||||
selectPrimaryShare
|
addOptionalShare "2" || :
|
||||||
! addShare "$share" "/shared" "Data" "Shared" "$SAMBA_CONFIG" && return 0
|
addOptionalShare "3" || :
|
||||||
|
|
||||||
addOptionalShare "2"
|
prepareSambaDirs || return 0
|
||||||
addOptionalShare "3"
|
|
||||||
|
|
||||||
prepareSambaDirs || return 1
|
startSamba || return 0
|
||||||
startSamba
|
|
||||||
|
|
||||||
|
# User-mode networking does not expose a LAN interface where discovery
|
||||||
|
# broadcasts would be useful.
|
||||||
isUserMode && return 0
|
isUserMode && return 0
|
||||||
|
|
||||||
if [[ "${BOOT_MODE:-}" == "windows_legacy" ]]; then
|
# Older Windows versions discover shares through NetBIOS, while modern Windows
|
||||||
startNetbios
|
# uses Web Services Discovery.
|
||||||
|
if isLegacyBoot; then
|
||||||
|
startNetbios || :
|
||||||
else
|
else
|
||||||
startWsddn
|
startWsddn || :
|
||||||
fi
|
fi
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user