-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathubuntu-kickstart.cfg
88 lines (64 loc) · 1.92 KB
/
ubuntu-kickstart.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
# System language
lang en_US
# Language modules to install
langsupport en_US
# System keyboard
keyboard us
# System mouse
mouse
# System timezone
timezone America/New_York
# Root password
rootpw --disabled
# Initial user (will have sudo so no need for root)
# Allow weak password
preseed user-setup/allow-password-weak boolean true
user ubuntu --fullname "Ubuntu User" --password ubuntu
# Shutdown after installation
poweroff
# Use text mode install
text
# Install OS instead of upgrade
install
# Installation media
url --url http://archive.ubuntu.com/ubuntu
# System bootloader configuration
bootloader --location=mbr
# Clear the Master Boot Record
zerombr yes
# Partition clearing information
clearpart --all --initlabel
# Basic disk partition
part / --fstype ext4 --size 1 --grow --asprimary
part swap --size 1024
# Make minimalistic install
preseed tasksel/first multiselect
preseed tasksel/skip-tasks multiselect server
preseed pkgsel/ubuntu-standard boolean false
preseed base-installer/install-recommends boolean false
preseed base-installer/kernel/override-image string linux-virtual
preseed pkgsel/install-language-support boolean false
# System authorization infomation
# The enablemd5 has to be there although it will still use salted sha256
auth --useshadow --enablemd5
# Network information
network --bootproto=dhcp --device=eth0
# Firewall configuration
firewall --disabled --trust=eth0 --ssh
# Policy for applying updates. May be "none" (no automatic updates),
# "unattended-upgrades" (install security updates automatically), or
# "landscape" (manage system with Landscape).
preseed pkgsel/update-policy select unattended-upgrades
# Do not configure the X Window System
skipx
%packages
# Install openssh
ca-certificates
openssl
openssh-server
%post --nochroot
# Clean up
rm -f /target/var/cache/apt/*
rm -f /target/var/lib/apt/lists/*
# Set passwordless sudo
sed -i -e '/%sudo/s/ALL$/NOPASSWD:ALL/' /target/etc/sudoers