updates arch base

This commit is contained in:
JOLIMAITRE Matthieu 2023-12-10 23:04:08 +01:00
parent abd5a71a25
commit 33caad6317

View file

@ -4,14 +4,16 @@ export { build };
const build: Base = async (c) => { const build: Base = async (c) => {
// installs base // installs base
await c.sh(`pacstrap -K '${c.root_dir}' base`); await c.sh(`pacstrap -K -c '${c.root_dir}' base`);
await c.sh(`rm -fr '${c.root_dir}/etc/securetty' '${c.root_dir}/usr/share/factory/etc/securetty'`); await c.sh(`rm -fr '${c.root_dir}/etc/securetty' '${c.root_dir}/usr/share/factory/etc/securetty'`);
await c.sh_in(`printf 'root:noussommesdescrabes' | chpasswd --crypt-method DES`); await c.sh_in(`pacman -Syu`);
await c.sh_in(`sed -i 's/^SigLevel = .*$/SigLevel = Never/g' /etc/pacman.conf`);
await pacman(c, "nano", "git", "base-devel"); await pacman(c, "nano", "git", "base-devel");
await c.sh_in(`systemctl enable systemd-networkd.service`); await c.sh_in(`systemctl enable systemd-networkd.service`);
// ssh // ssh
await c.sh_in(`printf 'root:jesuisunevoute' | chpasswd --crypt-method DES`);
await pacman(c, "openssh"); await pacman(c, "openssh");
await c.sh_in(` await c.sh_in(`
echo 'PermitRootLogin yes' >> /etc/ssh/sshd_config echo 'PermitRootLogin yes' >> /etc/ssh/sshd_config
@ -22,5 +24,5 @@ const build: Base = async (c) => {
}; };
async function pacman(c: BaseContext, ...packages: string[]) { async function pacman(c: BaseContext, ...packages: string[]) {
await c.sh_in(`pacman -Syu --noconfirm '${packages.join("' '")}'`); await c.sh_in(`pacman -S --noconfirm '${packages.join("' '")}'`);
} }