forked from hiragashi/ubuntu-unattended-install
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathks.preseed
66 lines (56 loc) · 2.48 KB
/
ks.preseed
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
# # Partitioning removal of keys to prevent file sys error
ubiquity partman-auto/disk string /dev/sda
ubiquity partman-auto/method string regular
ubiquity partman-lvm/device_remove_lvm boolean true
ubiquity partman-md/device_remove_md boolean true
ubiquity partman-auto/choose_recipe select atomic
# automatically partition without confirmation
d-i partman-partitioning/confirm_write_new_label boolean true
d-i partman/choose_partition select finish
d-i partman/confirm boolean true
d-i partman/confirm_nooverwrite boolean true
# Locale
d-i debian-installer/locale string en_US
d-i console-setup/ask_detect boolean false
d-i console-setup/layoutcode string us
# Network
d-i netcfg/get_hostname string unassigned-hostname
d-i netcfg/get_domain string unassigned-domain
d-i netcfg/choose_interface select auto
# Clock
d-i clock-setup/utc-auto boolean true
d-i clock-setup/utc boolean true
d-i time/zone string US/Pacific
d-i clock-setup/ntp boolean true
# Packages, Mirrors, Image
d-i mirror/country string US
d-i apt-setup/multiverse boolean true
d-i apt-setup/restricted boolean true
d-i apt-setup/universe boolean true
# Users
d-i passwd/user-fullname string REPLACETHISTEXTWITHYOURNAME
d-i passwd/username string REPLACETHISTEXTWITHYOURUSERNAME
d-i passwd/user-password-crypted password PASSWORDGOESHERE
d-i passwd/user-default-groups string adm audio cdrom dip lpadmin sudo plugdev sambashare video
d-i passwd/root-login boolean true
d-i passwd/root-password-crypted password PASSWORDGOESHERE
d-i user-setup/allow-password-weak boolean true
d-i pkgsel/include string openssh-server
d-i preseed/late_command string \
in-target sh -c 'sed -i "s/^#PermitRootLogin.*\$/PermitRootLogin yes/g" /etc/ssh/sshd_config';
# Grub
# Due notably to potential USB sticks, the location of the MBR can not be
# determined safely in general, so this needs to be specified:
d-i grub-installer/bootdev string /dev/sda
# To install to the first device (assuming it is not a USB stick):
#d-i grub-installer/bootdev string default
d-i grub-installer/grub2_instead_of_grub_legacy boolean true
d-i grub-installer/only_debian boolean true
d-i finish-install/reboot_in_progress note
# Custom Commands (ssh access on install - change network device name as applicaple)
ubiquity ubiquity/success_command \
string echo "auto enp2s0" >> /etc/network/interfaces; \
echo "iface enp2s0 inet dhcp" >> /etc/network/interfaces; \
ifup enp2s0; \
apt-get update -y; \
in-target apt-get install -y openssh-server;