-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfedora.dist.cfg
244 lines (202 loc) · 6.32 KB
/
fedora.dist.cfg
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
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
# version=41
# Fedora 41 Kickstart
# Author: Lilian POULIQUEN
# Use command line install
text
# Keyboard layouts
keyboard --xlayouts="fr (oss)"
# System language
lang fr_FR.UTF-8
# Network information
network --bootproto=dhcp --onboot=yes --ipv6=auto --hostname=HOSTNAME
# Do not run the Setup Agent on first boot
firstboot --disable
# Install the bootloader
bootloader --driveorder=nvme0n1
# Use only required disks
ignoredisk --only-use=nvme0n1,sda
# Partition clearing information
clearpart --all
# Zero mbr
zerombr
# Disk partitioning information
reqpart --add-boot
## System partition
part pv.1000 --fstype="lvmpv" --ondisk=nvme0n1 --size=1 --grow --encrypted --luks-version=luks2
volgroup LinuxSystem --pesize=4096 pv.1000
logvol / --fstype="xfs" --size=1 --grow --label="LinuxSystem" --name=root --vgname=LinuxSystem
logvol swap --fstype="swap" --size=8192 --name=swap --vgname=LinuxSystem
## Data partition
part pv.1001 --fstype="lvmpv" --ondisk=sda --size=1 --grow --encrypted --luks-version=luks2
volgroup LinuxData --pesize=4096 pv.1001
logvol /home --fstype="xfs" --size=1 --grow --label="LinuxData" --name=home --vgname=LinuxData
# System timezone
timezone Europe/Paris
# Adding repos
url --mirrorlist="https://mirrors.fedoraproject.org/metalink?repo=fedora-41&arch=x86_64"
# Root password
rootpw --iscrypted ENCRYPTED_ROOT_PASSWORD
# Create main user
user --groups=wheel --name=MAIN_USER_LOGIN --password=ENCRYPTED_MAIN_USER_PASSWORD --iscrypted --gecos="MAIN_USER_DISPLAY_NAME"
# Enabling services
services --enabled=crond,libvirtd
# Interface graphique au démarrage
xconfig --startxonboot
# Shutdown after installation
shutdown
%addon com_redhat_kdump --disable --reserve-mb='auto'
%end
# Installing packages
%packages
@^workstation-product-environment
@virtualization
## Removing unwanted packages
-@container-management
-@firefox
-@libreoffice
-abrt
-abrt-cli
-abrt-desktop
-abrt-java-connector
-baobab
-evince
-evince-djvu
-fedora-chromium-config
-gnome-abrt
-gnome-boxes
-gnome-calculator
-gnome-calendar
-gnome-characters
-gnome-classic-session
-gnome-classic-session-xsession
-gnome-clocks
-gnome-connections
-gnome-contacts
-gnome-extensions-app
-gnome-font-viewer
-gnome-initial-setup
-gnome-logs
-gnome-maps
-gnome-text-editor
-gnome-tour
-gnome-user-docs
-gnome-user-share
-gnome-weather
-hyperv-daemons
-loupe
-mediawriter
-open-vm-tools-desktop
-rhythmbox
-simple-scan
-snapshot
-totem
-unoconv
-virtualbox-guest-additions
-yelp
## Installing packages
ansible
ansible-lint
bridge-utils
crontabs
flatpak
gcc-c++
gnome-shell-extension-blur-my-shell
gnome-shell-extension-common
gnome-shell-extension-drive-menu
gnome-shell-extension-gsconnect
gnome-shell-extension-launch-new-instance
gnome-shell-extension-no-overview
gnome-shell-extension-user-theme
gnome-tweaks
guestfs-tools
java-latest-openjdk
libguestfs-tools
nautilus-gsconnect
neovim
npm
samba
tig
tmux
vim
%end
# Post installs
%post --interpreter=/usr/bin/bash --log=/tmp/post-script.log
## Disabling unwanted repos
dnf config-manager --disable \
copr:copr.fedorainfracloud.org:phracek:PyCharm \
fedora-cisco-openh264
# Enabling rpmfusion's repo for nvidia drivers
dnf config-manager --enable \
rpmfusion-nonfree-nvidia-driver \
rpmfusion-nonfree-steam
## Installing Docker
dnf config-manager --add-repo "https://download.docker.com/linux/fedora/docker-ce.repo"
dnf install --assumeyes \
docker-ce-cli \
docker-ce \
containerd.io
## Updating packages
dnf update --assumeyes
### Installing Docker Compose
curl --silent --location --output "/usr/local/sbin/docker-compose" "https://github.com/docker/compose/releases/latest/download/docker-compose-linux-x86_64"
chown root:docker "/usr/local/sbin/docker-compose"
chmod 754 "/usr/local/sbin/docker-compose"
### Docker auto-completion
curl --silent --location --output "/usr/share/bash-completion/completions/docker" "https://raw.githubusercontent.com/docker/cli/master/contrib/completion/bash/docker"
### Enabling Docker at start
systemctl enable docker
## Installing GNOME extensions
unset extension_urls
declare -A extension_urls
extension_urls+=(
["middleclickclose@paolo.tranquilli.gmail.com"]="https://extensions.gnome.org/extension-data/middleclickclosepaolo.tranquilli.gmail.com.v31.shell-extension.zip"
["nightthemeswitcher@romainvigier.fr"]="https://extensions.gnome.org/extension-data/nightthemeswitcherromainvigier.fr.v78.shell-extension.zip"
)
for extension_uuid in "${!extension_urls[@]}"
do
rm --recursive --force "/usr/share/gnome-shell/extensions/${extension_uuid}/"
wget --quiet --output-document "/tmp/${extension_uuid}.zip" "${extension_urls[$extension_uuid]}"
mkdir --parents "/tmp/${extension_uuid}/"
unzip -qq -o "/tmp/${extension_uuid}.zip" -d "/tmp/${extension_uuid}/"
mv "/tmp/${extension_uuid}/" "/usr/share/gnome-shell/extensions/"
rm --recursive --force "/tmp/${extension_uuid}.zip" "/tmp/${extension_uuid}/"
chmod 644 "/usr/share/gnome-shell/extensions/${extension_uuid}/metadata.json"
glib-compile-schemas /usr/share/gnome-shell/extensions/${extensions_uuid}/schemas/
done
## Installing patched font for terminal
wget --quiet --output-document "/tmp/SourceCodePro.zip" "https://github.com/ryanoasis/nerd-fonts/releases/latest/download/SourceCodePro.zip"
unzip "/tmp/SourceCodePro.zip" -d "/usr/share/fonts/sauce-code-pro/"
## Setting custom environment variables
echo "export EDITOR=\"/usr/bin/vim\"" >> "/etc/profile.d/sh.local"
cat > "/etc/profile.d/vim.sh" << EOF
# Creating alias to use vim instead of vi
alias vi='vim'
# Creating alias to use nvim to code
alias code='nvim'
EOF
## Installing system wide Flatpak apps
flatpak remote-add --system --if-not-exists flathub "https://flathub.org/repo/flathub.flatpakrepo"
flatpak install --system --assumeyes flathub \
com.bitwarden.desktop \
com.github.tchx84.Flatseal \
com.mattjakeman.ExtensionManager \
com.nextcloud.desktopclient.nextcloud \
com.rafaelmardojai.Blanket \
io.gitlab.librewolf-community \
io.mpv.Mpv \
md.obsidian.Obsidian \
org.gimp.GIMP \
org.gnome.baobab \
org.gnome.Calendar \
org.gnome.Loupe \
org.gnome.Evince \
org.gnome.FileRoller \
org.gnome.Geary \
org.gnome.SimpleScan \
org.gnome.TextEditor \
org.inkscape.Inkscape \
org.libreoffice.LibreOffice \
org.mozilla.firefox \
org.mozilla.Thunderbird \
org.onlyoffice.desktopeditors
%end