penguins-eggs 9.2.5 → 9.2.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.oclif.manifest.json +1 -0
- package/README.md +34 -30
- package/conf/distros/jessie/krill/settings.yml +48 -9
- package/conf/distros/kinetic/README.md +41 -0
- package/conf/tools.yaml +1 -1
- package/{lib → dist}/classes/bleach.js +0 -0
- package/{lib → dist}/classes/compressors.js +0 -0
- package/{lib → dist}/classes/daddy.js +0 -0
- package/{lib → dist}/classes/distro.js +16 -30
- package/{lib → dist}/classes/family/archlinux.js +0 -0
- package/{lib → dist}/classes/family/debian.js +0 -0
- package/{lib → dist}/classes/family/fedora.js +0 -0
- package/{lib → dist}/classes/family/suse.js +0 -0
- package/{lib → dist}/classes/incubation/branding.js +0 -0
- package/{lib → dist}/classes/incubation/distros/bionic.js +0 -0
- package/{lib → dist}/classes/incubation/distros/buster.js +0 -0
- package/{lib → dist}/classes/incubation/distros/focal.js +0 -0
- package/{lib → dist}/classes/incubation/distros/jessie.js +1 -1
- package/{lib → dist}/classes/incubation/distros/rolling.js +0 -0
- package/{lib → dist}/classes/incubation/fisherman-helper/displaymanager.js +0 -0
- package/{lib → dist}/classes/incubation/fisherman-helper/packages.js +0 -0
- package/{lib → dist}/classes/incubation/fisherman.js +1 -1
- package/{lib → dist}/classes/incubation/incubator.js +9 -19
- package/{lib → dist}/classes/incubation/installer.js +0 -0
- package/{lib → dist}/classes/initrd.js +0 -0
- package/{lib → dist}/classes/keyboards.js +0 -0
- package/{lib → dist}/classes/locales.js +0 -0
- package/{lib → dist}/classes/n8.js +0 -0
- package/dist/classes/network.js +99 -0
- package/{lib → dist}/classes/ovary.js +0 -0
- package/{lib → dist}/classes/pacman.js +16 -1
- package/{lib → dist}/classes/pve-live.js +0 -0
- package/dist/classes/pxe.js +337 -0
- package/{lib → dist}/classes/settings.js +0 -0
- package/{lib → dist}/classes/sources_list.js +0 -0
- package/{lib → dist}/classes/systemctl.js +0 -0
- package/{lib → dist}/classes/tailor.js +0 -0
- package/{lib → dist}/classes/tools.js +0 -0
- package/{lib → dist}/classes/users.js +0 -0
- package/{lib → dist}/classes/utils.js +82 -17
- package/{lib → dist}/classes/xdg.js +24 -26
- package/{lib → dist}/classes/yolk.js +0 -0
- package/{lib → dist}/commands/adapt.js +0 -0
- package/{lib → dist}/commands/analyze.js +0 -0
- package/{lib → dist}/commands/calamares.js +0 -0
- package/{lib → dist}/commands/config.js +0 -0
- package/dist/commands/cuckoo.js +63 -0
- package/{lib → dist}/commands/dad.js +0 -0
- package/{lib → dist}/commands/export/deb.js +0 -0
- package/{lib → dist}/commands/export/docs.js +0 -0
- package/{lib → dist}/commands/export/iso.js +0 -0
- package/{lib → dist}/commands/install.js +27 -4
- package/{lib → dist}/commands/kill.js +0 -0
- package/{lib → dist}/commands/mom.js +0 -0
- package/{lib → dist}/commands/produce.js +0 -0
- package/{lib → dist}/commands/status.js +0 -0
- package/{lib → dist}/commands/syncfrom.js +0 -0
- package/{lib → dist}/commands/syncto.js +0 -0
- package/{lib → dist}/commands/tools/clean.js +0 -0
- package/{lib → dist}/commands/tools/skel.js +0 -0
- package/{lib → dist}/commands/tools/stat.js +0 -0
- package/{lib → dist}/commands/tools/yolk.js +0 -0
- package/{lib → dist}/commands/update.js +0 -0
- package/{lib → dist}/commands/wardrobe/get.js +0 -0
- package/{lib → dist}/commands/wardrobe/ironing.js +0 -0
- package/{lib → dist}/commands/wardrobe/list.js +0 -0
- package/{lib → dist}/commands/wardrobe/show.js +0 -0
- package/{lib → dist}/commands/wardrobe/wear.js +0 -0
- package/{lib → dist}/components/elements/information.js +0 -0
- package/{lib → dist}/components/elements/steps.js +0 -0
- package/{lib → dist}/components/elements/title.js +0 -0
- package/{lib → dist}/components/finished.js +0 -0
- package/{lib → dist}/components/install.js +0 -0
- package/{lib → dist}/components/keyboard.js +0 -0
- package/{lib → dist}/components/location.js +0 -0
- package/{lib → dist}/components/network.js +0 -0
- package/{lib → dist}/components/partitions.js +0 -0
- package/{lib → dist}/components/summary.js +2 -2
- package/{lib → dist}/components/users.js +0 -0
- package/{lib → dist}/components/welcome.js +0 -0
- package/dist/dhcpd/dhcpd.js +222 -0
- package/dist/dhcpd/index.js +7 -0
- package/dist/dhcpd/packet/converters.js +377 -0
- package/dist/dhcpd/packet/options.js +2 -0
- package/dist/dhcpd/packet/types.js +2 -0
- package/dist/dhcpd/packet.js +251 -0
- package/dist/dhcpd/proxy.js +152 -0
- package/dist/dhcpd/server.js +152 -0
- package/dist/dhcpd/sprintf.js +170 -0
- package/dist/dhcpd/utils.js +190 -0
- package/{lib → dist}/index.js +0 -0
- package/{lib → dist}/interfaces/i-addons.js +0 -0
- package/{lib → dist}/interfaces/i-analyze.js +0 -0
- package/{lib → dist}/interfaces/i-app.js +0 -0
- package/{lib → dist}/interfaces/i-branding.js +0 -0
- package/{lib → dist}/interfaces/i-config-tools.js +0 -0
- package/{lib → dist}/interfaces/i-devices.js +0 -0
- package/{lib → dist}/interfaces/i-distro.js +0 -0
- package/{lib → dist}/interfaces/i-drive-list.js +0 -0
- package/{lib → dist}/interfaces/i-eggs-config.js +0 -0
- package/{lib → dist}/interfaces/i-exec.js +0 -0
- package/{lib → dist}/interfaces/i-initrd.js +0 -0
- package/{lib → dist}/interfaces/i-install.js +0 -0
- package/{lib → dist}/interfaces/i-installer.js +0 -0
- package/{lib → dist}/interfaces/i-krill-config.js +0 -0
- package/{lib → dist}/interfaces/i-krill.js +0 -0
- package/{lib → dist}/interfaces/i-materia.js +0 -0
- package/{lib → dist}/interfaces/i-net.js +0 -0
- package/{lib → dist}/interfaces/i-packages.js +0 -0
- package/{lib → dist}/interfaces/i-partitions.js +0 -0
- package/{lib/interfaces/i-remix.js → dist/interfaces/i-pxe-options.js} +0 -0
- package/{lib/interfaces/i-settings.js → dist/interfaces/i-remix.js} +0 -0
- package/{lib/interfaces/i-user.js → dist/interfaces/i-settings.js} +0 -0
- package/{lib/interfaces/i-workdir.js → dist/interfaces/i-user.js} +0 -0
- package/{lib/interfaces/i-xkb-model.js → dist/interfaces/i-workdir.js} +0 -0
- package/{lib/interfaces/index.js → dist/interfaces/i-xkb-model.js} +0 -0
- package/dist/interfaces/index.js +2 -0
- package/{lib → dist}/krill/krill-prepare.js +25 -6
- package/{lib → dist}/krill/krill-sequence.js +69 -77
- package/{lib → dist}/krill/modules/add-user.js +0 -0
- package/{lib → dist}/krill/modules/bootloader-config-ubuntu.js +0 -0
- package/{lib → dist}/krill/modules/bootloader-config.js +1 -1
- package/{lib → dist}/krill/modules/bootloader.js +0 -5
- package/{lib → dist}/krill/modules/change-password.js +0 -0
- package/{lib → dist}/krill/modules/del-live-user.js +0 -0
- package/{lib → dist}/krill/modules/fstab.js +0 -0
- package/{lib → dist}/krill/modules/grubcfg.js +0 -0
- package/dist/krill/modules/hostname.js +48 -0
- package/{lib → dist}/krill/modules/initramfs-cfg.js +0 -0
- package/{lib → dist}/krill/modules/initramfs.js +0 -0
- package/{lib → dist}/krill/modules/locale-cfg.js +0 -0
- package/{lib → dist}/krill/modules/locale.js +1 -1
- package/{lib/krill/modules/set-keyboard.js → dist/krill/modules/m-keyboard.js} +12 -4
- package/{lib/krill/modules/set-timezone.js → dist/krill/modules/m-timezone.js} +2 -2
- package/{lib → dist}/krill/modules/machine-id.js +0 -0
- package/{lib → dist}/krill/modules/mkfs.js +0 -0
- package/{lib → dist}/krill/modules/mount-fs.js +0 -0
- package/{lib → dist}/krill/modules/mount-vfs.js +0 -0
- package/{lib → dist}/krill/modules/network-cfg.js +0 -0
- package/{lib → dist}/krill/modules/packages.js +0 -0
- package/{lib → dist}/krill/modules/partition.js +25 -14
- package/{lib → dist}/krill/modules/remove-installer-link.js +0 -0
- package/{lib → dist}/krill/modules/umount.js +0 -0
- package/{lib → dist}/krill/modules/unpackfs.js +0 -0
- package/{lib → dist}/lib/cli-autologin.js +1 -1
- package/{lib → dist}/lib/dependencies.js +0 -0
- package/{lib → dist}/lib/get_address.js +0 -0
- package/{lib → dist}/lib/get_dns.js +0 -0
- package/{lib → dist}/lib/get_domain.js +0 -0
- package/{lib → dist}/lib/get_gateway.js +0 -0
- package/{lib → dist}/lib/get_hostname.js +0 -0
- package/{lib → dist}/lib/get_netmask.js +0 -0
- package/{lib → dist}/lib/get_password.js +0 -0
- package/{lib → dist}/lib/get_root_password.js +0 -0
- package/{lib → dist}/lib/get_userfullname.js +0 -0
- package/{lib → dist}/lib/get_username.js +0 -0
- package/{lib → dist}/lib/select_address_type.js +0 -0
- package/{lib → dist}/lib/select_filesystem_type.js +0 -0
- package/{lib → dist}/lib/select_installation_device.js +0 -0
- package/{lib → dist}/lib/select_installation_mode.js +0 -0
- package/{lib → dist}/lib/select_interface.js +0 -0
- package/{lib → dist}/lib/select_keyboard_layout.js +0 -0
- package/{lib → dist}/lib/select_keyboard_model.js +0 -0
- package/{lib → dist}/lib/select_keyboard_option.js +0 -0
- package/{lib → dist}/lib/select_keyboard_variant.js +0 -0
- package/{lib → dist}/lib/select_languages.js +0 -0
- package/{lib → dist}/lib/select_regions.js +0 -0
- package/{lib → dist}/lib/select_user_swap_choice.js +0 -0
- package/{lib → dist}/lib/select_zones.js +0 -0
- package/{lib → dist}/lib/utils.js +1 -2
- package/ipxe/ipxe.efi +0 -0
- package/package.json +20 -17
- package/scripts/_eggs +11 -7
- package/scripts/eggs.bash +2 -2
- package/lib/classes/bleach.d.ts +0 -40
- package/lib/classes/compressors.d.ts +0 -24
- package/lib/classes/daddy.d.ts +0 -11
- package/lib/classes/distro.d.ts +0 -31
- package/lib/classes/family/archlinux.d.ts +0 -69
- package/lib/classes/family/debian.d.ts +0 -68
- package/lib/classes/family/fedora.d.ts +0 -63
- package/lib/classes/family/suse.d.ts +0 -63
- package/lib/classes/incubation/branding.d.ts +0 -8
- package/lib/classes/incubation/distros/bionic.d.ts +0 -29
- package/lib/classes/incubation/distros/buster.d.ts +0 -31
- package/lib/classes/incubation/distros/focal.d.ts +0 -29
- package/lib/classes/incubation/distros/jessie.d.ts +0 -32
- package/lib/classes/incubation/distros/rolling.d.ts +0 -31
- package/lib/classes/incubation/fisherman-helper/displaymanager.d.ts +0 -7
- package/lib/classes/incubation/fisherman-helper/packages.d.ts +0 -19
- package/lib/classes/incubation/fisherman.d.ts +0 -77
- package/lib/classes/incubation/incubator.d.ts +0 -35
- package/lib/classes/incubation/installer.d.ts +0 -15
- package/lib/classes/initrd.d.ts +0 -42
- package/lib/classes/keyboards.d.ts +0 -43
- package/lib/classes/locales.d.ts +0 -14
- package/lib/classes/n8.d.ts +0 -16
- package/lib/classes/ovary.d.ts +0 -179
- package/lib/classes/pacman.d.ts +0 -164
- package/lib/classes/pve-live.d.ts +0 -42
- package/lib/classes/pxe.d.ts +0 -64
- package/lib/classes/pxe.js +0 -352
- package/lib/classes/settings.d.ts +0 -55
- package/lib/classes/sources_list.d.ts +0 -27
- package/lib/classes/systemctl.d.ts +0 -46
- package/lib/classes/tailor.d.ts +0 -43
- package/lib/classes/tools.d.ts +0 -29
- package/lib/classes/users.d.ts +0 -21
- package/lib/classes/utils.d.ts +0 -299
- package/lib/classes/xdg.d.ts +0 -44
- package/lib/classes/yolk.d.ts +0 -26
- package/lib/commands/adapt.d.ts +0 -9
- package/lib/commands/analyze.d.ts +0 -25
- package/lib/commands/calamares.d.ts +0 -26
- package/lib/commands/config.d.ts +0 -34
- package/lib/commands/cuckoo.d.ts +0 -24
- package/lib/commands/cuckoo.js +0 -70
- package/lib/commands/dad.d.ts +0 -17
- package/lib/commands/export/deb.d.ts +0 -14
- package/lib/commands/export/docs.d.ts +0 -8
- package/lib/commands/export/iso.d.ts +0 -13
- package/lib/commands/install.d.ts +0 -25
- package/lib/commands/kill.d.ts +0 -20
- package/lib/commands/mom.d.ts +0 -14
- package/lib/commands/produce.d.ts +0 -28
- package/lib/commands/status.d.ts +0 -18
- package/lib/commands/syncfrom.d.ts +0 -42
- package/lib/commands/syncto.d.ts +0 -67
- package/lib/commands/tools/clean.d.ts +0 -15
- package/lib/commands/tools/skel.d.ts +0 -17
- package/lib/commands/tools/stat.d.ts +0 -14
- package/lib/commands/tools/yolk.d.ts +0 -23
- package/lib/commands/update.d.ts +0 -46
- package/lib/commands/wardrobe/get.d.ts +0 -17
- package/lib/commands/wardrobe/ironing.d.ts +0 -18
- package/lib/commands/wardrobe/list.d.ts +0 -17
- package/lib/commands/wardrobe/show.d.ts +0 -19
- package/lib/commands/wardrobe/wear.d.ts +0 -21
- package/lib/components/elements/information.d.ts +0 -4
- package/lib/components/elements/steps.d.ts +0 -6
- package/lib/components/elements/title.d.ts +0 -4
- package/lib/components/finished.d.ts +0 -8
- package/lib/components/install.d.ts +0 -8
- package/lib/components/keyboard.d.ts +0 -12
- package/lib/components/location.d.ts +0 -12
- package/lib/components/network.d.ts +0 -12
- package/lib/components/partitions.d.ts +0 -9
- package/lib/components/summary.d.ts +0 -16
- package/lib/components/users.d.ts +0 -20
- package/lib/components/welcome.d.ts +0 -6
- package/lib/index.d.ts +0 -1
- package/lib/interfaces/i-addons.d.ts +0 -8
- package/lib/interfaces/i-analyze.d.ts +0 -13
- package/lib/interfaces/i-app.d.ts +0 -7
- package/lib/interfaces/i-branding.d.ts +0 -29
- package/lib/interfaces/i-config-tools.d.ts +0 -11
- package/lib/interfaces/i-devices.d.ts +0 -13
- package/lib/interfaces/i-distro.d.ts +0 -19
- package/lib/interfaces/i-drive-list.d.ts +0 -29
- package/lib/interfaces/i-eggs-config.d.ts +0 -24
- package/lib/interfaces/i-exec.d.ts +0 -4
- package/lib/interfaces/i-initrd.d.ts +0 -6
- package/lib/interfaces/i-install.d.ts +0 -9
- package/lib/interfaces/i-installer.d.ts +0 -20
- package/lib/interfaces/i-krill-config.d.ts +0 -26
- package/lib/interfaces/i-krill.d.ts +0 -35
- package/lib/interfaces/i-materia.d.ts +0 -36
- package/lib/interfaces/i-net.d.ts +0 -9
- package/lib/interfaces/i-packages.d.ts +0 -10
- package/lib/interfaces/i-partitions.d.ts +0 -9
- package/lib/interfaces/i-remix.d.ts +0 -14
- package/lib/interfaces/i-settings.d.ts +0 -10
- package/lib/interfaces/i-user.d.ts +0 -7
- package/lib/interfaces/i-workdir.d.ts +0 -8
- package/lib/interfaces/i-xkb-model.d.ts +0 -17
- package/lib/interfaces/index.d.ts +0 -17
- package/lib/krill/krill-prepare.d.ts +0 -60
- package/lib/krill/krill-sequence.d.ts +0 -151
- package/lib/krill/modules/add-user.d.ts +0 -15
- package/lib/krill/modules/bootloader-config-arch.d.ts +0 -9
- package/lib/krill/modules/bootloader-config-arch.js +0 -13
- package/lib/krill/modules/bootloader-config-ubuntu.d.ts +0 -9
- package/lib/krill/modules/bootloader-config.d.ts +0 -9
- package/lib/krill/modules/bootloader.d.ts +0 -10
- package/lib/krill/modules/change-password.d.ts +0 -10
- package/lib/krill/modules/del-live-user.d.ts +0 -9
- package/lib/krill/modules/fstab.d.ts +0 -14
- package/lib/krill/modules/grubcfg.d.ts +0 -17
- package/lib/krill/modules/hostname.d.ts +0 -13
- package/lib/krill/modules/hostname.js +0 -18
- package/lib/krill/modules/hosts.d.ts +0 -14
- package/lib/krill/modules/hosts.js +0 -35
- package/lib/krill/modules/initramfs-cfg.d.ts +0 -14
- package/lib/krill/modules/initramfs.d.ts +0 -13
- package/lib/krill/modules/locale-cfg.d.ts +0 -10
- package/lib/krill/modules/locale.d.ts +0 -13
- package/lib/krill/modules/machine-id.d.ts +0 -15
- package/lib/krill/modules/mkfs.d.ts +0 -13
- package/lib/krill/modules/mount-fs.d.ts +0 -17
- package/lib/krill/modules/mount-vfs.d.ts +0 -17
- package/lib/krill/modules/network-cfg.d.ts +0 -19
- package/lib/krill/modules/packages.d.ts +0 -14
- package/lib/krill/modules/partition.d.ts +0 -20
- package/lib/krill/modules/remove-installer-link.d.ts +0 -13
- package/lib/krill/modules/set-keyboard.d.ts +0 -10
- package/lib/krill/modules/set-timezone.d.ts +0 -14
- package/lib/krill/modules/umount.d.ts +0 -14
- package/lib/krill/modules/unpackfs.d.ts +0 -13
- package/lib/lib/cli-autologin.d.ts +0 -27
- package/lib/lib/dependencies.d.ts +0 -49
- package/lib/lib/get_address.d.ts +0 -1
- package/lib/lib/get_dns.d.ts +0 -1
- package/lib/lib/get_domain.d.ts +0 -1
- package/lib/lib/get_gateway.d.ts +0 -1
- package/lib/lib/get_hostname.d.ts +0 -1
- package/lib/lib/get_netmask.d.ts +0 -1
- package/lib/lib/get_password.d.ts +0 -1
- package/lib/lib/get_root_password.d.ts +0 -1
- package/lib/lib/get_userfullname.d.ts +0 -1
- package/lib/lib/get_username.d.ts +0 -1
- package/lib/lib/select_address_type.d.ts +0 -1
- package/lib/lib/select_filesystem_type.d.ts +0 -1
- package/lib/lib/select_installation_device.d.ts +0 -1
- package/lib/lib/select_installation_mode.d.ts +0 -1
- package/lib/lib/select_interface.d.ts +0 -1
- package/lib/lib/select_keyboard_layout.d.ts +0 -4
- package/lib/lib/select_keyboard_model.d.ts +0 -4
- package/lib/lib/select_keyboard_option.d.ts +0 -4
- package/lib/lib/select_keyboard_variant.d.ts +0 -4
- package/lib/lib/select_languages.d.ts +0 -1
- package/lib/lib/select_regions.d.ts +0 -1
- package/lib/lib/select_user_swap_choice.d.ts +0 -1
- package/lib/lib/select_zones.d.ts +0 -1
- package/lib/lib/utils.d.ts +0 -43
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -25,6 +25,7 @@ const tslib_1 = require("tslib");
|
|
|
25
25
|
* - summary
|
|
26
26
|
*/
|
|
27
27
|
const js_yaml_1 = tslib_1.__importDefault(require("js-yaml"));
|
|
28
|
+
const os_1 = tslib_1.__importDefault(require("os"));
|
|
28
29
|
const react_1 = tslib_1.__importDefault(require("react"));
|
|
29
30
|
const ink_1 = require("ink");
|
|
30
31
|
const utils_1 = tslib_1.__importDefault(require("../classes/utils"));
|
|
@@ -79,7 +80,7 @@ class Krill {
|
|
|
79
80
|
/**
|
|
80
81
|
* @param cryped
|
|
81
82
|
*/
|
|
82
|
-
async prepare(unattended = false, cryped = false, pve = false, verbose = false) {
|
|
83
|
+
async prepare(unattended = false, ip = false, random = false, domain = 'local', suspend = false, small = false, none = false, cryped = false, pve = false, verbose = false) {
|
|
83
84
|
/**
|
|
84
85
|
* Check for disk presence
|
|
85
86
|
*/
|
|
@@ -138,10 +139,28 @@ class Krill {
|
|
|
138
139
|
filesystemType: this.krillConfig.filesystemType,
|
|
139
140
|
userSwapChoice: this.krillConfig.userSwapChoice
|
|
140
141
|
};
|
|
142
|
+
if (suspend) {
|
|
143
|
+
oPartitions.userSwapChoice = 'suspend';
|
|
144
|
+
}
|
|
145
|
+
else if (small) {
|
|
146
|
+
oPartitions.userSwapChoice = 'small';
|
|
147
|
+
}
|
|
148
|
+
else if (none) {
|
|
149
|
+
oPartitions.userSwapChoice = 'none';
|
|
150
|
+
}
|
|
141
151
|
let hostname = this.krillConfig.hostname;
|
|
142
152
|
if (hostname === '') {
|
|
143
153
|
hostname = shelljs_1.default.exec('cat /etc/hostname').trim();
|
|
144
154
|
}
|
|
155
|
+
if (ip) {
|
|
156
|
+
hostname = 'ip-' + utils_1.default.address().replaceAll('.', '-');
|
|
157
|
+
}
|
|
158
|
+
if (random) {
|
|
159
|
+
const fl = shelljs_1.default.exec(`tr -dc a-z </dev/urandom | head -c 2 ; echo ''`, { silent: true }).trim();
|
|
160
|
+
const n = shelljs_1.default.exec(`tr -dc 0-9 </dev/urandom | head -c 3 ; echo ''`, { silent: true }).trim();
|
|
161
|
+
const sl = shelljs_1.default.exec(`tr -dc a-z </dev/urandom | head -c 2 ; echo ''`, { silent: true }).trim();
|
|
162
|
+
hostname = `${os_1.default.hostname()}-${fl}${n}${sl}`;
|
|
163
|
+
}
|
|
145
164
|
oUsers = {
|
|
146
165
|
name: this.krillConfig.name,
|
|
147
166
|
fullname: this.krillConfig.fullname,
|
|
@@ -176,7 +195,7 @@ class Krill {
|
|
|
176
195
|
/**
|
|
177
196
|
* installation
|
|
178
197
|
*/
|
|
179
|
-
await this.install(oLocation, oKeyboard, oPartitions, oUsers, oNetwork, unattended, verbose);
|
|
198
|
+
await this.install(oLocation, oKeyboard, oPartitions, oUsers, oNetwork, unattended, domain, verbose);
|
|
180
199
|
}
|
|
181
200
|
/**
|
|
182
201
|
* WELCOME
|
|
@@ -434,13 +453,13 @@ class Krill {
|
|
|
434
453
|
let summaryElem;
|
|
435
454
|
let message = "";
|
|
436
455
|
if (unattended) {
|
|
437
|
-
message = "Unattended installation will start in
|
|
456
|
+
message = "Unattended installation will start in 5 seconds, press CTRL-C to abort!";
|
|
438
457
|
}
|
|
439
458
|
while (true) {
|
|
440
459
|
summaryElem = react_1.default.createElement(summary_1.default, { name: users.name, password: users.password, rootPassword: users.rootPassword, hostname: users.hostname, region: location.region, zone: location.zone, language: location.language, keyboardModel: keyboard.keyboardModel, keyboardLayout: keyboard.keyboardLayout, installationDevice: partitions.installationDevice, message: message });
|
|
441
460
|
if (unattended) {
|
|
442
461
|
redraw(summaryElem);
|
|
443
|
-
await sleep(
|
|
462
|
+
await sleep(5000);
|
|
444
463
|
break;
|
|
445
464
|
}
|
|
446
465
|
else if (await confirm(summaryElem, "Confirm Summary datas?")) {
|
|
@@ -451,9 +470,9 @@ class Krill {
|
|
|
451
470
|
/**
|
|
452
471
|
* INSTALL
|
|
453
472
|
*/
|
|
454
|
-
async install(location, keyboard, partitions, users, network, unattended = false, verbose = false) {
|
|
473
|
+
async install(location, keyboard, partitions, users, network, unattended = false, domain = 'local', verbose = false) {
|
|
455
474
|
const sequence = new krill_sequence_1.default(location, keyboard, partitions, users, network);
|
|
456
|
-
await sequence.
|
|
475
|
+
await sequence.start(unattended, domain, verbose);
|
|
457
476
|
}
|
|
458
477
|
/**
|
|
459
478
|
* return true if pv exist
|
|
@@ -31,7 +31,7 @@ const unpackfs_1 = tslib_1.__importDefault(require("./modules/unpackfs"));
|
|
|
31
31
|
const machine_id_1 = tslib_1.__importDefault(require("./modules/machine-id"));
|
|
32
32
|
const fstab_1 = tslib_1.__importDefault(require("./modules/fstab"));
|
|
33
33
|
const locale_1 = tslib_1.__importDefault(require("./modules/locale"));
|
|
34
|
-
const
|
|
34
|
+
const m_keyboard_1 = tslib_1.__importDefault(require("./modules/m-keyboard"));
|
|
35
35
|
const locale_cfg_1 = tslib_1.__importDefault(require("./modules/locale-cfg"));
|
|
36
36
|
// users
|
|
37
37
|
const add_user_1 = tslib_1.__importDefault(require("./modules/add-user"));
|
|
@@ -42,7 +42,6 @@ const network_cfg_1 = tslib_1.__importDefault(require("./modules/network-cfg"));
|
|
|
42
42
|
// services-systemd:
|
|
43
43
|
// bootloader-config
|
|
44
44
|
const bootloader_config_1 = tslib_1.__importDefault(require("./modules/bootloader-config"));
|
|
45
|
-
const bootloader_config_arch_1 = tslib_1.__importDefault(require("./modules/bootloader-config-arch"));
|
|
46
45
|
const bootloader_config_ubuntu_1 = tslib_1.__importDefault(require("./modules/bootloader-config-ubuntu"));
|
|
47
46
|
//
|
|
48
47
|
const grubcfg_1 = tslib_1.__importDefault(require("./modules/grubcfg"));
|
|
@@ -56,11 +55,10 @@ const initramfs_1 = tslib_1.__importDefault(require("./modules/initramfs"));
|
|
|
56
55
|
const del_live_user_1 = tslib_1.__importDefault(require("./modules/del-live-user"));
|
|
57
56
|
// umount already imported
|
|
58
57
|
// to order in same wat
|
|
59
|
-
const
|
|
58
|
+
const m_timezone_1 = tslib_1.__importDefault(require("./modules/m-timezone"));
|
|
60
59
|
const umount_1 = tslib_1.__importDefault(require("./modules/umount"));
|
|
61
60
|
const mkfs_1 = tslib_1.__importDefault(require("./modules/mkfs"));
|
|
62
61
|
const hostname_1 = tslib_1.__importDefault(require("./modules/hostname"));
|
|
63
|
-
const hosts_1 = tslib_1.__importDefault(require("./modules/hosts"));
|
|
64
62
|
/**
|
|
65
63
|
* hatching: installazione o cova!!!
|
|
66
64
|
*/
|
|
@@ -78,7 +76,7 @@ class Sequence {
|
|
|
78
76
|
this.machineId = machine_id_1.default;
|
|
79
77
|
this.fstab = fstab_1.default;
|
|
80
78
|
this.locale = locale_1.default;
|
|
81
|
-
this.
|
|
79
|
+
this.keyboard = m_keyboard_1.default;
|
|
82
80
|
this.localeCfg = locale_cfg_1.default;
|
|
83
81
|
// users
|
|
84
82
|
this.addUser = add_user_1.default;
|
|
@@ -89,7 +87,6 @@ class Sequence {
|
|
|
89
87
|
// services-systemd:
|
|
90
88
|
// bootloader-config
|
|
91
89
|
this.bootloaderConfig = bootloader_config_1.default;
|
|
92
|
-
this.bootloaderConfigArch = bootloader_config_arch_1.default;
|
|
93
90
|
this.bootloaderConfigUbuntu = bootloader_config_ubuntu_1.default;
|
|
94
91
|
//
|
|
95
92
|
this.grubcfg = grubcfg_1.default;
|
|
@@ -103,12 +100,11 @@ class Sequence {
|
|
|
103
100
|
this.delLiveUser = del_live_user_1.default;
|
|
104
101
|
this.umountFs = mount_fs_1.umountFs;
|
|
105
102
|
this.umountVfs = mount_vfs_1.umountVfs;
|
|
106
|
-
// to order in same
|
|
107
|
-
this.
|
|
103
|
+
// to order in same way
|
|
104
|
+
this.timezone = m_timezone_1.default;
|
|
108
105
|
this.umount = umount_1.default;
|
|
109
106
|
this.mkfs = mkfs_1.default;
|
|
110
107
|
this.hostname = hostname_1.default;
|
|
111
|
-
this.hosts = hosts_1.default;
|
|
112
108
|
this.installer = {};
|
|
113
109
|
this.installTarget = '/tmp/calamares-krill-root';
|
|
114
110
|
this.verbose = false;
|
|
@@ -133,6 +129,7 @@ class Sequence {
|
|
|
133
129
|
this.luksDevice = '';
|
|
134
130
|
this.luksMountpoint = '';
|
|
135
131
|
this.personalFile = '';
|
|
132
|
+
this.unattended = false;
|
|
136
133
|
this.installer = (0, installer_1.installer)();
|
|
137
134
|
this.settings = new settings_1.default();
|
|
138
135
|
this.language = location.language;
|
|
@@ -165,7 +162,8 @@ class Sequence {
|
|
|
165
162
|
* @param umount
|
|
166
163
|
* @returns
|
|
167
164
|
*/
|
|
168
|
-
async
|
|
165
|
+
async start(unattended = false, domain = 'local', verbose = false) {
|
|
166
|
+
this.unattended = unattended;
|
|
169
167
|
this.verbose = verbose;
|
|
170
168
|
this.echo = utils_1.default.setEcho(this.verbose);
|
|
171
169
|
if (this.verbose) {
|
|
@@ -289,7 +287,7 @@ class Sequence {
|
|
|
289
287
|
message = "settings keyboard ";
|
|
290
288
|
percent = 0.48;
|
|
291
289
|
try {
|
|
292
|
-
this.
|
|
290
|
+
this.keyboard();
|
|
293
291
|
}
|
|
294
292
|
catch (error) {
|
|
295
293
|
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
@@ -317,64 +315,14 @@ class Sequence {
|
|
|
317
315
|
percent = 0.53;
|
|
318
316
|
try {
|
|
319
317
|
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
320
|
-
await this.hostname();
|
|
321
|
-
}
|
|
322
|
-
catch (error) {
|
|
323
|
-
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
324
|
-
}
|
|
325
|
-
// hosts
|
|
326
|
-
message = "Creating hosts ";
|
|
327
|
-
percent = 0.60;
|
|
328
|
-
try {
|
|
329
|
-
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
330
|
-
await this.hosts();
|
|
331
|
-
}
|
|
332
|
-
catch (error) {
|
|
333
|
-
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
334
|
-
}
|
|
335
|
-
// bootloader-config
|
|
336
|
-
message = "bootloader-config ";
|
|
337
|
-
percent = 0.62;
|
|
338
|
-
try {
|
|
339
|
-
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
340
|
-
await this.bootloaderConfig();
|
|
341
|
-
}
|
|
342
|
-
catch (error) {
|
|
343
|
-
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
344
|
-
}
|
|
345
|
-
// grubcfg
|
|
346
|
-
message = "grubcfg ";
|
|
347
|
-
percent = 0.63;
|
|
348
|
-
try {
|
|
349
|
-
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
350
|
-
await this.grubcfg();
|
|
351
|
-
}
|
|
352
|
-
catch (error) {
|
|
353
|
-
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
354
|
-
}
|
|
355
|
-
// bootloader
|
|
356
|
-
message = "bootloader ";
|
|
357
|
-
percent = 0.64;
|
|
358
|
-
try {
|
|
359
|
-
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
360
|
-
await this.bootloader();
|
|
361
|
-
}
|
|
362
|
-
catch (error) {
|
|
363
|
-
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
364
|
-
}
|
|
365
|
-
// packages
|
|
366
|
-
message = "add/remove packages";
|
|
367
|
-
percent = 0.65;
|
|
368
|
-
try {
|
|
369
|
-
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
370
|
-
await this.packages();
|
|
318
|
+
await this.hostname(domain);
|
|
371
319
|
}
|
|
372
320
|
catch (error) {
|
|
373
321
|
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
374
322
|
}
|
|
375
323
|
// initramfsCfg
|
|
376
324
|
message = "initramfs configure";
|
|
377
|
-
percent = 0.
|
|
325
|
+
percent = 0.55;
|
|
378
326
|
try {
|
|
379
327
|
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
380
328
|
this.initramfsCfg(this.partitions.installationDevice);
|
|
@@ -384,7 +332,7 @@ class Sequence {
|
|
|
384
332
|
}
|
|
385
333
|
// initramfs
|
|
386
334
|
message = "initramfs ";
|
|
387
|
-
percent = 0.
|
|
335
|
+
percent = 0.60;
|
|
388
336
|
try {
|
|
389
337
|
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
390
338
|
await this.initramfs();
|
|
@@ -398,7 +346,7 @@ class Sequence {
|
|
|
398
346
|
if (!fs_1.default.existsSync(this.luksFile) || fs_1.default.existsSync(this.personalFile)) {
|
|
399
347
|
// delLiveUser
|
|
400
348
|
message = "Removing user live ";
|
|
401
|
-
percent = 0.
|
|
349
|
+
percent = 0.61;
|
|
402
350
|
try {
|
|
403
351
|
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
404
352
|
await this.delLiveUser();
|
|
@@ -408,7 +356,7 @@ class Sequence {
|
|
|
408
356
|
}
|
|
409
357
|
// addUser
|
|
410
358
|
message = "Adding user ";
|
|
411
|
-
percent = 0.
|
|
359
|
+
percent = 0.62;
|
|
412
360
|
try {
|
|
413
361
|
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
414
362
|
await this.addUser(this.users.name, this.users.password, this.users.fullname, '', '', '');
|
|
@@ -418,7 +366,7 @@ class Sequence {
|
|
|
418
366
|
}
|
|
419
367
|
// changePassword
|
|
420
368
|
message = "adding user password ";
|
|
421
|
-
percent = 0.
|
|
369
|
+
percent = 0.63;
|
|
422
370
|
try {
|
|
423
371
|
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
424
372
|
await this.changePassword('root', this.users.rootPassword);
|
|
@@ -431,7 +379,7 @@ class Sequence {
|
|
|
431
379
|
if (pacman_1.default.isInstalledGui()) {
|
|
432
380
|
try {
|
|
433
381
|
message = "autologin GUI";
|
|
434
|
-
percent = 0.
|
|
382
|
+
percent = 0.65;
|
|
435
383
|
if (this.users.autologin) {
|
|
436
384
|
await xdg_1.default.autologin(utils_1.default.getPrimaryUser(), this.users.name, this.installTarget);
|
|
437
385
|
}
|
|
@@ -443,7 +391,7 @@ class Sequence {
|
|
|
443
391
|
}
|
|
444
392
|
else { // autologin CLI remove DEFAULT
|
|
445
393
|
message = "autologin CLI";
|
|
446
|
-
percent = 0.
|
|
394
|
+
percent = 0.66;
|
|
447
395
|
try {
|
|
448
396
|
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
449
397
|
await cliAutologin.remove(this.installTarget);
|
|
@@ -455,12 +403,32 @@ class Sequence {
|
|
|
455
403
|
// cleanup
|
|
456
404
|
await cliAutologin.msgRemove(`${this.installTarget}/etc/motd`);
|
|
457
405
|
await cliAutologin.msgRemove(`${this.installTarget}/etc/issue`);
|
|
458
|
-
//
|
|
459
|
-
message = "
|
|
460
|
-
percent = 0.
|
|
406
|
+
// bootloader-config [moved to the end]
|
|
407
|
+
message = "bootloader-config ";
|
|
408
|
+
percent = 0.70;
|
|
409
|
+
try {
|
|
410
|
+
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
411
|
+
await this.bootloaderConfig();
|
|
412
|
+
}
|
|
413
|
+
catch (error) {
|
|
414
|
+
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
415
|
+
}
|
|
416
|
+
// grubcfg [moved to the end]
|
|
417
|
+
message = "grubcfg ";
|
|
418
|
+
percent = 0.75;
|
|
419
|
+
try {
|
|
420
|
+
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
421
|
+
await this.grubcfg();
|
|
422
|
+
}
|
|
423
|
+
catch (error) {
|
|
424
|
+
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
425
|
+
}
|
|
426
|
+
// bootloader (grub-install) [moved to the end)
|
|
427
|
+
message = "bootloader ";
|
|
428
|
+
percent = 0.80;
|
|
461
429
|
try {
|
|
462
430
|
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
463
|
-
await this.
|
|
431
|
+
await this.bootloader();
|
|
464
432
|
}
|
|
465
433
|
catch (error) {
|
|
466
434
|
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
@@ -468,7 +436,7 @@ class Sequence {
|
|
|
468
436
|
// sourcesYolkUmount
|
|
469
437
|
if (this.distro.familyId === 'debian') {
|
|
470
438
|
message = "sources yolk unmount";
|
|
471
|
-
percent = 0.
|
|
439
|
+
percent = 0.90;
|
|
472
440
|
try {
|
|
473
441
|
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
474
442
|
await this.execCalamaresModule('sources-yolk-unmount');
|
|
@@ -477,6 +445,30 @@ class Sequence {
|
|
|
477
445
|
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
478
446
|
}
|
|
479
447
|
}
|
|
448
|
+
// packages
|
|
449
|
+
message = "add/remove packages";
|
|
450
|
+
percent = 0.91;
|
|
451
|
+
try {
|
|
452
|
+
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
453
|
+
await this.packages();
|
|
454
|
+
}
|
|
455
|
+
catch (error) {
|
|
456
|
+
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
457
|
+
}
|
|
458
|
+
/**
|
|
459
|
+
* removeInstallerLink
|
|
460
|
+
*/
|
|
461
|
+
if (await pacman_1.default.calamaresCheck()) {
|
|
462
|
+
message = "remove installer link";
|
|
463
|
+
percent = 0.93;
|
|
464
|
+
try {
|
|
465
|
+
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
466
|
+
await this.removeInstallerLink();
|
|
467
|
+
}
|
|
468
|
+
catch (error) {
|
|
469
|
+
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
470
|
+
}
|
|
471
|
+
}
|
|
480
472
|
// umountVfs
|
|
481
473
|
message = "umount VFS";
|
|
482
474
|
percent = 0.95;
|
|
@@ -502,7 +494,7 @@ class Sequence {
|
|
|
502
494
|
percent = 100.0;
|
|
503
495
|
try {
|
|
504
496
|
await redraw(react_1.default.createElement(install_1.default, { message: message, percent: percent }));
|
|
505
|
-
await this.finished(
|
|
497
|
+
await this.finished();
|
|
506
498
|
}
|
|
507
499
|
catch (error) {
|
|
508
500
|
await utils_1.default.pressKeyToExit(JSON.stringify(error));
|
|
@@ -526,9 +518,9 @@ class Sequence {
|
|
|
526
518
|
/**
|
|
527
519
|
* only show the result
|
|
528
520
|
*/
|
|
529
|
-
async finished(
|
|
521
|
+
async finished() {
|
|
530
522
|
await redraw(react_1.default.createElement(finished_1.default, { installationDevice: this.partitions.installationDevice, hostName: this.users.hostname, userName: this.users.name }));
|
|
531
|
-
if (!unattended) {
|
|
523
|
+
if (!this.unattended) {
|
|
532
524
|
utils_1.default.pressKeyToExit('Press a key to reboot...');
|
|
533
525
|
}
|
|
534
526
|
shelljs_1.default.exec('reboot');
|
|
File without changes
|
|
File without changes
|
|
@@ -34,10 +34,5 @@ async function bootloader() {
|
|
|
34
34
|
catch (error) {
|
|
35
35
|
await utils_2.default.pressKeyToExit(cmd);
|
|
36
36
|
}
|
|
37
|
-
await (0, utils_1.exec)(`sleep 1 ${this.toNull}`, this.echo);
|
|
38
|
-
// let echoYes = Utils.setEcho(true)
|
|
39
|
-
// await exec(`chroot ${this.installTarget} grub-install ${this.partitions.installationDevice} ${this.toNull}`, echoYes)
|
|
40
|
-
// await exec(`chroot ${this.installTarget} grub-mkconfig -o /boot/grub/grub.cfg ${this.toNull}`, echoYes)
|
|
41
|
-
// await exec(`sleep 1 ${this.toNull}`, echoYes)
|
|
42
37
|
}
|
|
43
38
|
exports.default = bootloader;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* krill: module hostname
|
|
4
|
+
*
|
|
5
|
+
* author: Piero Proietti
|
|
6
|
+
* mail: piero.proietti@gmail.com
|
|
7
|
+
*
|
|
8
|
+
* https://stackoverflow.com/questions/23876782/how-do-i-split-a-typescript-class-into-multiple-files
|
|
9
|
+
*/
|
|
10
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
11
|
+
const tslib_1 = require("tslib");
|
|
12
|
+
const fs_1 = tslib_1.__importDefault(require("fs"));
|
|
13
|
+
/**
|
|
14
|
+
* hostname
|
|
15
|
+
*/
|
|
16
|
+
async function hostname(domain = 'local') {
|
|
17
|
+
let hostname = this.users.hostname;
|
|
18
|
+
/**
|
|
19
|
+
* hostname
|
|
20
|
+
*/
|
|
21
|
+
{
|
|
22
|
+
let file = this.installTarget + '/etc/hostname';
|
|
23
|
+
let text = hostname;
|
|
24
|
+
fs_1.default.writeFileSync(file, text);
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* hosts
|
|
28
|
+
*/
|
|
29
|
+
{
|
|
30
|
+
let file = this.installTarget + '/etc/hosts';
|
|
31
|
+
let text = '127.0.0.1 localhost localhost.localdomain\n';
|
|
32
|
+
if (this.network.addressType === 'static') {
|
|
33
|
+
text += `${this.network.address} ${hostname} pvelocalhost\n`;
|
|
34
|
+
}
|
|
35
|
+
else {
|
|
36
|
+
text += `127.0.1.1 ${hostname}.${domain} ${hostname} \n`;
|
|
37
|
+
}
|
|
38
|
+
text += `# The following lines are desirable for IPv6 capable hosts\n`;
|
|
39
|
+
text += `:: 1 ip6 - localhost ip6 - loopback\n`;
|
|
40
|
+
text += `fe00:: 0 ip6 - localnet\n`;
|
|
41
|
+
text += `ff00:: 0 ip6 - mcastprefix\n`;
|
|
42
|
+
text += `ff02:: 1 ip6 - allnodes\n`;
|
|
43
|
+
text += `ff02:: 2 ip6 - allrouters\n`;
|
|
44
|
+
text += `ff02:: 3 ip6 - allhosts\n`;
|
|
45
|
+
fs_1.default.writeFileSync(file, text);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
exports.default = hostname;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/**
|
|
3
|
-
* krill: module
|
|
3
|
+
* krill: module keyboard
|
|
4
4
|
*
|
|
5
5
|
* author: Piero Proietti
|
|
6
6
|
* mail: piero.proietti@gmail.com
|
|
@@ -11,7 +11,12 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
11
11
|
const tslib_1 = require("tslib");
|
|
12
12
|
const utils_1 = tslib_1.__importDefault(require("../../classes/utils"));
|
|
13
13
|
const utils_2 = require("../../lib/utils");
|
|
14
|
-
|
|
14
|
+
const fs_1 = tslib_1.__importDefault(require("fs"));
|
|
15
|
+
/**
|
|
16
|
+
*
|
|
17
|
+
* @param this
|
|
18
|
+
*/
|
|
19
|
+
async function mKeyboard() {
|
|
15
20
|
/**
|
|
16
21
|
* influence: - /etc/default/keyboard (x11)
|
|
17
22
|
* - /etc/vconsole.conf (console)
|
|
@@ -63,7 +68,10 @@ async function setKeyboard() {
|
|
|
63
68
|
content += ` MatchIsKeyboard "on"\n`;
|
|
64
69
|
content += ` Option "XkbLayout" "` + this.keyboardLayout + `"\n`;
|
|
65
70
|
content += `EndSection\n`;
|
|
66
|
-
|
|
71
|
+
// Not always exist /etc/X11/xorg.conf.d
|
|
72
|
+
if (fs_1.default.existsSync(`this.installTarget + '/etc/X11/xorg.conf.d`)) {
|
|
73
|
+
utils_1.default.write(this.installTarget + '/etc/X11/xorg.conf.d/00-keyboard.conf', content);
|
|
74
|
+
}
|
|
67
75
|
}
|
|
68
76
|
}
|
|
69
|
-
exports.default =
|
|
77
|
+
exports.default = mKeyboard;
|
|
@@ -15,7 +15,7 @@ const fs_1 = tslib_1.__importDefault(require("fs"));
|
|
|
15
15
|
*
|
|
16
16
|
* @param this
|
|
17
17
|
*/
|
|
18
|
-
async function
|
|
18
|
+
async function mTimezone() {
|
|
19
19
|
if (fs_1.default.existsSync('/etc/localtime')) {
|
|
20
20
|
const cmd = `chroot ${this.installTarget} unlink /etc/localtime`;
|
|
21
21
|
await (0, utils_1.exec)(cmd, this.echo);
|
|
@@ -23,4 +23,4 @@ async function setTimezone() {
|
|
|
23
23
|
const cmd = `chroot ${this.installTarget} ln -sf /usr/share/zoneinfo/${this.region}/${this.zone} /etc/localtime`;
|
|
24
24
|
await (0, utils_1.exec)(cmd, this.echo);
|
|
25
25
|
}
|
|
26
|
-
exports.default =
|
|
26
|
+
exports.default = mTimezone;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|