blob: 703fcd3e551bc68027e471078fe121f43cbfedb4 (
about) (
plain)
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
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
|
(define-module (systems ayase))
(define efi-filesystem-uuid
((@ (gnu system uuid) uuid)
"B4FB-CBD9"
'fat32))
(define host-name
"ayase")
(define (label number)
((@ (gnu system file-systems) file-system-label)
(string-append host-name
"-swap"
number)))
(define polish-locale-string
"pl_PL.utf8")
(define root-filesystem-uuid
((@ (gnu system file-systems) uuid)
"615a98cd-a632-4ee5-a6f4-e5ebcaa6fb8c"))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(define efi-partition
((@ (gnu system file-systems) file-system)
(mount-point "/boot/efi")
(device efi-filesystem-uuid)
(type "vfat")))
(define (gc-workaround-service)
(use-modules (gnu packages bootloaders)
(gnu packages ibus)
(gnu packages python-build)
(gnu packages ruby)
(gnu services))
(simple-service 'gc-workaround
profile-service-type
(list grub
ibus
python-pip
ruby)))
(define (home-services)
(use-modules (gnu services guix)
(users id1000))
(let ((uid1000-home-environment* (uid1000-home-environment host-name)))
((@ (gnu services) service)
guix-home-service-type
`((,uid1000-name ,uid1000-home-environment*)))))
(define keyboard-layout
((@ (gnu system keyboard) keyboard-layout)
"pl"))
(define (libvirt-service)
(use-modules (gnu services virtualization))
((@ (gnu services) service)
libvirt-service-type))
(define (openssh-service)
(use-modules (gnu services ssh))
((@ (gnu services) service)
openssh-service-type))
(define polish-locale
((@ (gnu system locale) locale-definition)
(name polish-locale-string)
(source "pl_PL")))
(define root-partition
((@ (gnu system file-systems) file-system)
(mount-point "/")
(device root-filesystem-uuid)
(type "ext4")))
(define (swap-label number)
(let ((target-label (label number)))
((@ (gnu system file-systems) swap-space)
(target target-label))))
(define (system-packages-service)
(use-modules (gnu packages gnome)
(gnu packages gnupg)
(gnu packages kde-pim)
(gnu services))
(simple-service 'system-packages
profile-service-type
(list gnome-boxes
kgpg
pinentry-qt
pinentry-tty)))
(define (tor-service)
(use-modules (gnu services)
(gnu services networking))
((@ (gnu services) service)
tor-service-type))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(define (bootloader)
(use-modules (gnu bootloader grub))
((@ (gnu bootloader) bootloader-configuration)
(bootloader grub-efi-bootloader)
(targets (list "/boot/efi"))
(keyboard-layout keyboard-layout)))
(define (file-systems)
(use-modules (gnu system file-systems))
(append %base-file-systems
(list root-partition
efi-partition)))
(define (locale-definitions)
(use-modules (gnu system locale))
(append %default-locale-definitions
(list polish-locale)))
(define services
(append (@ (suweren services) %distribution-services)
(list (gc-workaround-service)
(home-services)
(libvirt-service)
(openssh-service)
(system-packages-service)
(tor-service))))
(define swap-device-1
(swap-label "-1"))
(define swap-device-2
(swap-label "-2"))
(define (users)
(use-modules (gnu system shadow)
(users id1000))
(append %base-user-accounts
(list uid1000-account)))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(define (operating-system*)
(use-modules (nongnu packages linux)
(nongnu system linux-initrd)
(gnu system keyboard)
(suweren commons sudoers))
((@ (gnu system) operating-system)
(kernel linux)
(bootloader (bootloader))
(keyboard-layout keyboard-layout)
(initrd microcode-initrd)
(firmware (list linux-firmware))
(host-name host-name)
(file-systems (file-systems))
(swap-devices (list swap-device-1
swap-device-2))
(users (users))
(timezone "Europe/Warsaw")
(locale polish-locale-string)
(locale-definitions (locale-definitions))
(services services)
(sudoers-file %sudoers-specification*)))
(define-public operating-system*
(operating-system*))
operating-system*
|