Compare commits
2 commits
52d9af32d5
...
2077911805
Author | SHA1 | Date | |
---|---|---|---|
2077911805 | |||
ec91773b25 |
15 changed files with 94 additions and 45 deletions
51
:w
Normal file
51
:w
Normal file
|
@ -0,0 +1,51 @@
|
|||
#!/run/current-system/profile/bin/bash
|
||||
|
||||
USER_PASSWORD=""
|
||||
ROOT_PASSWORD=""
|
||||
|
||||
source ./guix-env
|
||||
source ./guix-log
|
||||
|
||||
get_root_password() {
|
||||
read -s -p "Root password: " PASSWORD
|
||||
printf "\n"
|
||||
read -s -p "Confirm password: " PASSWORD_CONFIRM
|
||||
printf "\n"
|
||||
if [ "$PASSWORD" == "$PASSWORD_CONFIRM" ]; then
|
||||
ROOT_PASSWORD=$PASSWORD
|
||||
return
|
||||
else
|
||||
ERROR "Passwords do not match"
|
||||
get_root_password
|
||||
fi
|
||||
}
|
||||
|
||||
get_user_password() {
|
||||
read -s -p "User password: " PASSWORD
|
||||
printf "\n"
|
||||
read -s -p "Confirm password: " PASSWORD_CONFIRM
|
||||
printf "\n"
|
||||
if [ "$PASSWORD" == "$PASSWORD_CONFIRM" ]; then
|
||||
USER_PASSWORD=$PASSWORD
|
||||
return
|
||||
else
|
||||
ERROR "Passwords do not match"
|
||||
get_user_password
|
||||
fi
|
||||
}
|
||||
|
||||
EVENT "Setup /etc/shadow for root and user"
|
||||
|
||||
get_root_password
|
||||
get_user_password
|
||||
|
||||
cat << EOF | chroot /mnt
|
||||
passwd
|
||||
$ROOT_PASSWORD
|
||||
$ROOT_PASSWORD
|
||||
passwd freya
|
||||
$USER_PASSWORD
|
||||
$USER_PASSWORD
|
||||
EOF
|
||||
|
||||
EVENT "Successfully set passwords"
|
|
@ -8,11 +8,11 @@
|
|||
- Boot and create partitions using graphical installer
|
||||
- Bail out right before installation begins, go to terminal
|
||||
- Mount cow-store using herd start cow-store /mnt
|
||||
- Download latest version of configuration using `curl -o main.tar.gz --insecure --follow https://g.tylerm.dev/tylerm/dotfiles/archive/main.tar.gz` and unpack using tar
|
||||
- Download latest version of configuration using `curl -o main.tar.gz https://g.freya.dev/freya/dotfiles/archive/main.tar.gz` and unpack using tar
|
||||
- Authorize nonguix channel using `curl -o signkey.pub https://substitutes.nonguix.org/signing-key.pub and guix archive --authorize < signkey.pub`
|
||||
- Modify/add system config for system and initialize using `guix time-machine -C channels.scm -- system -L modules/ --substitute-urls='https://bordeaux.guix.gnu.org https://ci.guix.gnu.org https://substitutes.nonguix.org' init system.scm /mnt`
|
||||
- When installed, proceed
|
||||
- Reboot into system, assign root and tylerm user a password
|
||||
- Reboot into system, assign root and freya user a password
|
||||
- Setup system completely
|
||||
- Clone guix-config to proper location
|
||||
- Reconfigure system
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
(url "https://git.savannah.gnu.org/git/guix.git")
|
||||
(branch "master")
|
||||
(commit
|
||||
"c4886c0cb608e1b36969f195eb2f7ea25a37ac89")
|
||||
"e3f87960915e3ef0b1d6a5a15281b3d4e9ee4d38")
|
||||
(introduction
|
||||
(make-channel-introduction
|
||||
"9edb3f66fd807b096b48283debdcddccfea34bad"
|
||||
|
@ -14,7 +14,7 @@
|
|||
(url "https://gitlab.com/nonguix/nonguix")
|
||||
(branch "master")
|
||||
(commit
|
||||
"61279f68f2b617ab868a094db856188602fc880b")
|
||||
"877ed8cc4eee26ddde3d7d200c19c370c6bf7cb1")
|
||||
(introduction
|
||||
(make-channel-introduction
|
||||
"897c1a470da759236cc11798f4e0a5f7d4d59fbc"
|
||||
|
|
|
@ -13,6 +13,9 @@ EVENT "Setting up disk encryption with luks"
|
|||
if [[ $DISK == "/dev/sd"* ]]; then
|
||||
CRYPT_PARTITION="$DISK""2"
|
||||
EFI_PARTITION="$DISK""1"
|
||||
elif [[ $DISK == "/dev/vd"* ]]; then
|
||||
CRYPT_PARTITION="$DISK""2"
|
||||
EFI_PARTITION="$DISK""1"
|
||||
elif [[ $DISK == "/dev/nvme"* ]]; then
|
||||
CRYPT_PARTITION="$DISK""p2"
|
||||
EFI_PARTITION="$DISK""p1"
|
||||
|
@ -43,19 +46,19 @@ $PASSWORD
|
|||
$PASSWORD_CONFIRM
|
||||
EOF
|
||||
|
||||
EVENT "Opening cryptroot"
|
||||
EVENT "Opening root"
|
||||
|
||||
cryptsetup open "$CRYPT_PARTITION" cryptroot <<EOF
|
||||
cryptsetup open "$CRYPT_PARTITION" root <<EOF
|
||||
$PASSWORD
|
||||
EOF
|
||||
|
||||
EVENT "Setting up cryptroot btrfs"
|
||||
EVENT "Setting up root btrfs"
|
||||
|
||||
mkfs.btrfs "/dev/mapper/cryptroot"
|
||||
mkfs.btrfs "/dev/mapper/root"
|
||||
|
||||
EVENT "Mounting cryptroot"
|
||||
EVENT "Mounting root"
|
||||
|
||||
mount /dev/mapper/cryptroot /mnt
|
||||
mount /dev/mapper/root /mnt
|
||||
|
||||
EVENT "Setting up EFI vfat"
|
||||
|
||||
|
|
|
@ -15,8 +15,8 @@ guix time-machine -C ../channels.scm -- system -L ../modules --substitute-urls='
|
|||
|
||||
EVENT "Installing User Environment"
|
||||
|
||||
USER=tylerm
|
||||
guix shell git -- git clone https://g.tylerm.dev/tylerm/dotfiles /mnt/home/$USER/.config/guix
|
||||
USER=freya
|
||||
guix shell git -- git clone https://g.freya.cat/freya/dotfiles /mnt/home/$USER/.config/guix
|
||||
cp ../$HOSTNAME.scm /mnt/home/$USER/.config/guix/$HOSTNAME.scm
|
||||
cp ./guix-setup-user /mnt/home/$USER/.zprofile
|
||||
|
||||
|
|
|
@ -43,7 +43,7 @@ cat << EOF | chroot /mnt
|
|||
passwd
|
||||
$ROOT_PASSWORD
|
||||
$ROOT_PASSWORD
|
||||
passwd tylerm
|
||||
passwd freya
|
||||
$USER_PASSWORD
|
||||
$USER_PASSWORD
|
||||
EOF
|
||||
|
|
|
@ -8,12 +8,12 @@
|
|||
(mapped-devices (list (mapped-device
|
||||
(source (uuid
|
||||
"SED_CRYPT_UUID"))
|
||||
(target "cryptroot")
|
||||
(target "root")
|
||||
(type luks-device-mapping))))
|
||||
|
||||
(file-systems (cons* (file-system
|
||||
(mount-point "/")
|
||||
(device "/dev/mapper/cryptroot")
|
||||
(device "/dev/mapper/root")
|
||||
(type "btrfs")
|
||||
(dependencies mapped-devices))
|
||||
(file-system
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
[user]
|
||||
signingkey = 4F6BC11CEBB2F24214B90FAC9FF6937B829E565A
|
||||
email = tylerm@tylerm.dev
|
||||
name = Tyler Murphy
|
||||
email = freya@freyacat.org
|
||||
name = Freya Murphy
|
||||
[commit]
|
||||
gpgsign = true
|
||||
[init]
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
file:///home/tylerm/code
|
||||
file:///home/tylerm/sync
|
||||
file:///home/freya/code
|
||||
file:///home/freya/sync
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# DO NOT EDIT! This file will be overwritten by LXAppearance.
|
||||
# Any customization should be done in ~/.gtkrc-2.0.mine instead.
|
||||
|
||||
include "/home/tylerm/.gtkrc-2.0.mine"
|
||||
include "/home/freya/.gtkrc-2.0.mine"
|
||||
gtk-theme-name="Lavanda-Sea-Dark"
|
||||
gtk-icon-theme-name="Adwaita"
|
||||
gtk-font-name="Cantarell 11"
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
{
|
||||
# Home Manager needs a bit of information about you and the paths it should
|
||||
# manage.
|
||||
home.username = "tylerm";
|
||||
home.homeDirectory = "/home/tylerm";
|
||||
home.username = "freya";
|
||||
home.homeDirectory = "/home/freya";
|
||||
home.stateVersion = "22.11"; # Please read the comment before changing.
|
||||
|
||||
# This value will set some environment variables to allow home-manager to
|
||||
|
|
|
@ -1,17 +1,17 @@
|
|||
Match host * exec "gpg-connect-agent UPDATESTARTUPTTY /bye"
|
||||
|
||||
Host icarus
|
||||
HostName icarus.tylerm.dev
|
||||
User tylerm
|
||||
HostName icarus.freya.cat
|
||||
User freya
|
||||
|
||||
Host tardis
|
||||
HostName tardis.tylerm.dev
|
||||
User tylerm
|
||||
HostName tardis.freya.cat
|
||||
User freya
|
||||
Port 1111
|
||||
|
||||
Host stationery
|
||||
HostName stationery.faith
|
||||
User tylerm
|
||||
User freya
|
||||
|
||||
Host queeg
|
||||
Hostname queeg.cs.rit.edu
|
||||
|
@ -24,7 +24,7 @@ Host nitron
|
|||
Host github.com
|
||||
Hostname github.com
|
||||
User tam2214
|
||||
IdentityFile /home/tylerm/.ssh/id_rit
|
||||
IdentityFile /home/freya/.ssh/id_rit
|
||||
|
||||
#Host *
|
||||
# KexAlgorithms -sntrup761x25519-sha512@openssh.com
|
||||
|
|
|
@ -27,7 +27,6 @@
|
|||
#:use-module (gnu services avahi)
|
||||
#:use-module (gnu services spice)
|
||||
#:use-module (gnu services virtualization)
|
||||
#:use-module (home-services ntp)
|
||||
#:use-module (home-packages wm)
|
||||
#:use-module (home-packages certs)
|
||||
#:use-module (home-packages virtualization))
|
||||
|
@ -58,10 +57,10 @@
|
|||
|
||||
;; The list of user accounts ('root' is implicit).
|
||||
(users (cons* (user-account
|
||||
(name "tylerm")
|
||||
(comment "Tyler Murphy")
|
||||
(name "freya")
|
||||
(comment "Freya Murphy")
|
||||
(group "users")
|
||||
(home-directory "/home/tylerm")
|
||||
(home-directory "/home/freya")
|
||||
(shell (file-append zsh "/bin/zsh"))
|
||||
(supplementary-groups '("wheel" "audio" "lp" "docker" "plugdev" "libvirt" "kvm" "netdev" "video" "tty")))
|
||||
%base-user-accounts))
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
#:recursive? #t))
|
||||
(build-system trivial-build-system)
|
||||
(license license:mpl2.0)
|
||||
(home-page "https://tylerm.dev")
|
||||
(home-page "https://freya.cat")
|
||||
(arguments
|
||||
`(#:modules
|
||||
((guix build utils))
|
||||
|
|
|
@ -9,24 +9,19 @@
|
|||
#:use-module (guix build-system trivial)
|
||||
#:use-module (nongnu packages mozilla))
|
||||
|
||||
(define firefox*
|
||||
(package/inherit
|
||||
firefox
|
||||
(inputs
|
||||
(modify-inputs
|
||||
(package-inputs firefox)
|
||||
(delete "pipewire")
|
||||
(append pipewire)))))
|
||||
|
||||
(define-public firefox-wayland-new
|
||||
(package
|
||||
(inherit firefox*)
|
||||
(name "firefox-wayland-new")
|
||||
(native-inputs '())
|
||||
(source #f)
|
||||
(version "0.1")
|
||||
(synopsis "Simple wrapper for pipewire in firefox")
|
||||
(description "Simple wrapper for pipewire in firefox")
|
||||
(home-page "http://mozilla.org/")
|
||||
(license license:mpl2.0)
|
||||
(inputs
|
||||
`(("bash" ,bash-minimal)
|
||||
("pipewire" ,pipewire)
|
||||
("firefox" ,firefox*)))
|
||||
("firefox" ,firefox)))
|
||||
(build-system trivial-build-system)
|
||||
(arguments
|
||||
'(#:modules ((guix build utils))
|
||||
|
@ -47,6 +42,7 @@
|
|||
(format port "#!~a \n
|
||||
export LD_LIBRARY_PATH=~a \n
|
||||
export MOZ_ENABLE_WAYLAND=1 \n
|
||||
export MOZ_USE_XINPUT2=1 \n
|
||||
exec ~a $@\n"
|
||||
(string-append bash "/bin/bash")
|
||||
(string-append pipewire "/lib")
|
||||
|
|
Loading…
Reference in a new issue