-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdpl_install.sh
41 lines (31 loc) · 1.19 KB
/
dpl_install.sh
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
#!/bin/bash
# installation script for DPL Digital Preservation Lab -- an environment for teaching and experimenting digital preservation
# runs on Ubuntu 24.04
# 2024 Tobias Wildi, [email protected]
#
# Use this script to install the tools on new Ubuntu-machine
# Exit immediately if a command exits with a non-zero status
set -e
# Needed for all installers
sudo apt update -y
sudo apt install curl zip unzip -y
# create ~/opt for additional softare
if [ -d ~/opt ]; then
echo "Directory ~/opt already exists."
else
mkdir ~/opt
echo "Directory ~/opt created."
fi
# Ensure computer doesn't go to sleep or lock while installing
gsettings set org.gnome.desktop.screensaver lock-enabled false
gsettings set org.gnome.desktop.session idle-delay 0
# Run installers
for script in ~/dpl/install/*.sh; do source $script; done
# Upgrade everything that might ask for a reboot last
sudo apt upgrade -y
# Revert to normal idle and lock settings
gsettings set org.gnome.desktop.screensaver lock-enabled true
gsettings set org.gnome.desktop.session idle-delay 300
# Logout to pickup changes
gum confirm "Ready to logout for all settings to take effect?" && gnome-session-quit --logout --no-prompt
exit 0