2023-03-23 01:48:20 +01:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
2024-01-01 18:13:05 +01:00
|
|
|
# Copyright (c) 2021-2024 tteck
|
2023-03-23 01:48:20 +01:00
|
|
|
# Author: tteck (tteckster)
|
|
|
|
# License: MIT
|
|
|
|
# https://github.com/tteck/Proxmox/raw/main/LICENSE
|
|
|
|
|
|
|
|
source /dev/stdin <<< "$FUNCTIONS_FILE_PATH"
|
|
|
|
color
|
|
|
|
verb_ip6
|
|
|
|
catch_errors
|
|
|
|
setting_up_container
|
|
|
|
network_check
|
|
|
|
update_os
|
|
|
|
|
|
|
|
msg_info "Installing Dependencies"
|
|
|
|
$STD apt-get install -y curl
|
|
|
|
$STD apt-get install -y sudo
|
|
|
|
$STD apt-get install -y mc
|
2023-05-07 16:39:56 +02:00
|
|
|
$STD apt-get install -y apt-transport-https
|
2023-11-26 13:30:19 +01:00
|
|
|
$STD apt-get install -y gnupg
|
2023-03-23 01:48:20 +01:00
|
|
|
msg_ok "Installed Dependencies"
|
|
|
|
|
2023-05-07 16:39:56 +02:00
|
|
|
msg_info "Installing OpenJDK"
|
2023-11-26 13:43:37 +01:00
|
|
|
wget -qO- https://packages.adoptium.net/artifactory/api/gpg/key/public | gpg --dearmor >/etc/apt/trusted.gpg.d/adoptium.gpg
|
|
|
|
echo 'deb [arch=amd64 signed-by=/etc/apt/trusted.gpg.d/adoptium.gpg] https://packages.adoptium.net/artifactory/deb bookworm main' >/etc/apt/sources.list.d/adoptium.list
|
2023-11-26 13:30:19 +01:00
|
|
|
$STD apt-get update
|
2024-02-11 15:23:03 +01:00
|
|
|
$STD apt-get install -y temurin-17-jre
|
2023-05-07 16:39:56 +02:00
|
|
|
msg_ok "Installed OpenJDK"
|
2023-03-23 01:48:20 +01:00
|
|
|
|
2023-05-07 16:39:56 +02:00
|
|
|
msg_info "Installing MongoDB"
|
2024-02-28 15:41:51 +01:00
|
|
|
libssl=$(curl -fsSL "http://security.ubuntu.com/ubuntu/pool/main/o/openssl/" | grep -o 'libssl1\.1_1\.1\.1f-1ubuntu2\.2[^"]*amd64\.deb' | head -n1)
|
|
|
|
wget -qL http://security.ubuntu.com/ubuntu/pool/main/o/openssl/$libssl
|
2024-02-28 21:37:33 +01:00
|
|
|
$STD dpkg -i $libssl
|
2023-11-26 13:43:37 +01:00
|
|
|
wget -qO- https://pgp.mongodb.com/server-4.4.asc | gpg --dearmor >/etc/apt/trusted.gpg.d/mongodb-server-4.4.gpg
|
2023-11-26 13:30:19 +01:00
|
|
|
echo 'deb [ arch=amd64 signed-by=/etc/apt/trusted.gpg.d/mongodb-server-4.4.gpg ] https://repo.mongodb.org/apt/debian buster/mongodb-org/4.4 main' >/etc/apt/sources.list.d/mongodb-org-4.4.list
|
|
|
|
$STD apt-get update
|
|
|
|
$STD apt-get install -y mongodb-org
|
2023-05-07 16:39:56 +02:00
|
|
|
msg_ok "Installed MongoDB"
|
|
|
|
|
|
|
|
msg_info "Installing UniFi Network Application"
|
|
|
|
wget -qO /etc/apt/trusted.gpg.d/unifi-repo.gpg https://dl.ui.com/unifi/unifi-repo.gpg
|
2023-11-26 13:30:19 +01:00
|
|
|
echo 'deb [ arch=amd64 signed-by=/etc/apt/trusted.gpg.d/unifi-repo.gpg] https://www.ui.com/downloads/unifi/debian stable ubiquiti' >/etc/apt/sources.list.d/100-ubnt-unifi.list
|
2023-05-07 16:39:56 +02:00
|
|
|
$STD apt-get update
|
|
|
|
$STD apt-get install -y unifi
|
2023-03-23 01:48:20 +01:00
|
|
|
msg_ok "Installed UniFi Network Application"
|
|
|
|
|
|
|
|
motd_ssh
|
2023-05-15 13:39:30 +02:00
|
|
|
customize
|
2023-03-23 01:48:20 +01:00
|
|
|
|
|
|
|
msg_info "Cleaning up"
|
2024-02-28 21:37:33 +01:00
|
|
|
rm -rf $libssl
|
2023-03-23 01:48:20 +01:00
|
|
|
$STD apt-get autoremove
|
|
|
|
$STD apt-get autoclean
|
|
|
|
msg_ok "Cleaned"
|