-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstall.sh
More file actions
112 lines (100 loc) · 3.19 KB
/
install.sh
File metadata and controls
112 lines (100 loc) · 3.19 KB
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
#!/bin/bash
#
# HomeServer-Script
# -----------------
# An interactive automation script that installs and configures a complete
# self-hosted home server stack on Ubuntu systems.
#
# This script was created to simplify the process of setting up commonly
# used self-hosted services such as CasaOS, Jellyfin, Immich, Tailscale,
# Ollama, and n8n. Instead of manually installing and configuring each
# service individually, this script provides a guided setup that allows
# users to select the services they want and install them in a single run.
#
# The project is an extension of the HomeServer-Guide repository, where the
# full manual setup process was originally documented. After realizing that
# repeating the manual setup process was time-consuming, this automation
# script was created to save time and reduce repetitive configuration work.
#
# Repository:
# https://github.com/Adamya-Gupta/HomeServer-Script
#
# Author: Adamya Gupta
# License: MIT
# Created: 2026
#
# Requirements:
# - Ubuntu Server or Ubuntu Desktop
# - Bash 4.2+
# - Internet connection
#
source ./lib/utils.sh
source ./modules/docker_install.sh
source ./modules/casaos_install.sh
source ./modules/immich_install.sh
source ./modules/jellyfin_install.sh
source ./modules/tailscale_install.sh
source ./modules/ollama_install.sh
source ./modules/n8n_install.sh
source ./lib/summary.sh
# Pre-flight checks
check_root
check_ubuntu
update_system
install_curl
install_gum
#Banner
gum style \
--foreground 212 --border-foreground 57 --border double \
--align center --width 50 --margin "1 2" --padding "2 4" \
--bold \
'HomeServer' 'Automation Script!'
echo "## You can setup following services:
|Name |More info | Suggestion |
|-----------|-----------------------------------------------|------------------------------|
|CASA OS |Provides Dashboard and management for Server |Recommended |
|Jellyfin |Enables Media Streaming |Recommended |
|Immich |Self-hosted photo and video backup solution |Recommended |
|Tailscale |VPN to connect to your server from any location|Recommended |
|Ollama |Lets you run local AI models on your server |Optional(16GB RAM recommended)|
|n8n |AI workflow automation platform |Optional |
" | gum format
echo ""
echo "Press tab or x to select , Enter to submit."
# Gum selection menu
CHOICE=$(gum choose --no-limit "CASA OS" "Jellyfin" "Immich" "Tailscale" "Ollama" "n8n")
if ! gum confirm 'Are you ready to start?';
then
echo "Take your time. No hurry 🙂";
exit 0
else
echo ""
echo "Starting installation... 🚀"
echo ""
docker_install
mapfile -t selected_choices <<< "$CHOICE"
# Loop through the array
for choice in "${selected_choices[@]}"; do
case "$choice" in
"CASA OS")
casaos_install
;;
"Jellyfin")
jellyfin_install
;;
"Immich")
immich_install
;;
"Tailscale")
tailscale_install
;;
"Ollama")
ollama_install
;;
"n8n")
n8n_install
;;
esac
done
fi
show_summary