Compare commits

...

16 Commits

Author SHA1 Message Date
Tobias
9d46a6d133 Update wastebin.sh (#2896) 2025-03-06 22:04:57 +01:00
community-scripts-pr-app[bot]
bbbbd3cb5f Update CHANGELOG.md (#2893) 2025-03-06 21:14:04 +01:00
community-scripts-pr-app[bot]
5db4a93697 Update .app files (#2892) 2025-03-06 21:13:44 +01:00
community-scripts-pr-app[bot]
dc7529dc8e Update date in json (#2891) 2025-03-06 21:13:19 +01:00
Slaviša Arežina
301ea36264 InvenTree (#2890) 2025-03-06 21:12:30 +01:00
community-scripts-pr-app[bot]
fc26badfdb Update CHANGELOG.md (#2887) 2025-03-06 17:19:15 +01:00
CanbiZ
0ded79b785 Wastebin: Update Script for Version 3.0.0 (#2885)
* Wastebin: Update Script for Version 3.0.0

* Update wastebin-install.sh
2025-03-06 17:01:18 +01:00
CanbiZ
83a79dcb6d Update wastebin-install.sh 2025-03-06 15:33:55 +01:00
community-scripts-pr-app[bot]
c98e92b034 Update CHANGELOG.md (#2877)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-03-06 10:48:05 +01:00
Tobias
c8dd6b1af1 Homarr: Optional Reboot after update (#2876)
* Update homarr.sh

* Update homarr.sh
2025-03-06 10:26:05 +01:00
CanbiZ
7ee0c9cc78 Fix Tag "community-scripts" for ArchLinux / OPNSense (#2875) 2025-03-06 08:55:00 +01:00
community-scripts-pr-app[bot]
648e452f8b Update CHANGELOG.md (#2865) 2025-03-05 20:07:17 +01:00
CanbiZ
8e3177135f Kimai: Better Handling of Updates (backup var / env / yaml) (#2862)
* Kimai: Better Handling of Updates (backup var / env / yaml)

* formatting
2025-03-05 18:41:34 +01:00
Slaviša Arežina
7352cbc220 fix: updated the composer call (#2864) 2025-03-05 18:35:18 +01:00
community-scripts-pr-app[bot]
3dd87d8989 Update CHANGELOG.md (#2859) 2025-03-05 12:59:58 +01:00
CanbiZ
4a3192b704 Fix NextcloudPi-Installation (#2853) 2025-03-05 12:17:31 +01:00
13 changed files with 316 additions and 96 deletions

View File

@@ -14,6 +14,32 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
All LXC instances created using this repository come pre-installed with Midnight Commander, which is a command-line tool (`mc`) that offers a user-friendly file and directory management interface for the terminal environment. All LXC instances created using this repository come pre-installed with Midnight Commander, which is a command-line tool (`mc`) that offers a user-friendly file and directory management interface for the terminal environment.
## 2025-03-06
### 🆕 New Scripts
- InvenTree [@tremor021](https://github.com/tremor021) ([#2890](https://github.com/community-scripts/ProxmoxVE/pull/2890))
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- Homarr: Optional Reboot after update [@CrazyWolf13](https://github.com/CrazyWolf13) ([#2876](https://github.com/community-scripts/ProxmoxVE/pull/2876))
- Fix Tag "community-scripts" for ArchLinux / OPNSense [@MickLesk](https://github.com/MickLesk) ([#2875](https://github.com/community-scripts/ProxmoxVE/pull/2875))
- #### ✨ New Features
- Wastebin: Update Script for Version 3.0.0 [@MickLesk](https://github.com/MickLesk) ([#2885](https://github.com/community-scripts/ProxmoxVE/pull/2885))
## 2025-03-05
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- Kimai: Better Handling of Updates (backup var / env / yaml) [@MickLesk](https://github.com/MickLesk) ([#2862](https://github.com/community-scripts/ProxmoxVE/pull/2862))
- Fix NextcloudPi-Installation [@MickLesk](https://github.com/MickLesk) ([#2853](https://github.com/community-scripts/ProxmoxVE/pull/2853))
## 2025-03-04 ## 2025-03-04
### 🆕 New Scripts ### 🆕 New Scripts

6
ct/headers/inventree Normal file
View File

@@ -0,0 +1,6 @@
____ ______
/ _/___ _ _____ ____/_ __/_______ ___
/ // __ \ | / / _ \/ __ \/ / / ___/ _ \/ _ \
_/ // / / / |/ / __/ / / / / / / / __/ __/
/___/_/ /_/|___/\___/_/ /_/_/ /_/ \___/\___/

View File

@@ -45,7 +45,8 @@ function update_script() {
cp -R Heimdall-${VER}/* /opt/Heimdall cp -R Heimdall-${VER}/* /opt/Heimdall
cd /opt/Heimdall cd /opt/Heimdall
$STD apt-get install -y composer $STD apt-get install -y composer
$STD COMPOSER_ALLOW_SUPERUSER=1 composer dump-autoload export COMPOSER_ALLOW_SUPERUSER=1
$STD composer dump-autoload
echo "${RELEASE}" >/opt/${APP}_version.txt echo "${RELEASE}" >/opt/${APP}_version.txt
msg_ok "Updated Heimdall Dashboard to ${RELEASE}" msg_ok "Updated Heimdall Dashboard to ${RELEASE}"
msg_info "Restoring Data" msg_info "Restoring Data"

View File

@@ -148,9 +148,12 @@ EOF
msg_info "Starting Services" msg_info "Starting Services"
systemctl start homarr systemctl start homarr
systemctl restart homarr
msg_ok "Started Services" msg_ok "Started Services"
msg_ok "Updated Successfully" msg_ok "Updated Successfully"
read -p "It's recommended to reboot the LXC after an update, would you like to reboot the LXC now ? (y/n): " choice
if [[ "$choice" =~ ^[Yy]$ ]]; then
reboot
fi
else else
msg_ok "No update required. ${APP} is already at v${RELEASE}" msg_ok "No update required. ${APP} is already at v${RELEASE}"
fi fi

45
ct/inventree.sh Normal file
View File

@@ -0,0 +1,45 @@
#!/usr/bin/env bash
source <(curl -s https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/build.func)
# Copyright (c) 2021-2025 community-scripts ORG
# Author: Slaviša Arežina (tremor021)
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
# Source: https://github.com/inventree/InvenTree
APP="InvenTree"
var_tags="inventory"
var_cpu="2"
var_ram="2048"
var_disk="6"
var_os="debian"
var_version="12"
var_unprivileged="1"
header_info "$APP"
variables
color
catch_errors
function update_script() {
header_info
check_container_storage
check_container_resources
if [[ ! -d "/opt/inventree" ]]; then
msg_error "No ${APP} Installation Found!"
exit
fi
msg_info "Updating $APP"
$STD apt-get update
$STD apt-get install --only-upgrade inventree -y
msg_ok "Updated $APP"
exit
}
start
build_container
description
msg_ok "Completed Successfully!\n"
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
echo -e "${INFO}${YW} Access it using the following URL:${CL}"
echo -e "${TAB}${GATEWAY}${BGN}http://${IP}${CL}"

View File

@@ -28,20 +28,29 @@ function update_script() {
exit exit
fi fi
RELEASE=$(curl -s https://api.github.com/repos/kimai/kimai/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }') RELEASE=$(curl -s https://api.github.com/repos/kimai/kimai/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
BACKUP_DIR="/opt/kimai_backup"
if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then
msg_info "Stopping Apache2" msg_info "Stopping Apache2"
systemctl stop apache2 systemctl stop apache2
msg_ok "Stopped Apache2" msg_ok "Stopped Apache2"
msg_info "Backing up Kimai configuration and var directory"
mkdir -p "$BACKUP_DIR"
[ -d /opt/kimai/var ] && cp -r /opt/kimai/var "$BACKUP_DIR/"
[ -f /opt/kimai/.env ] && cp /opt/kimai/.env "$BACKUP_DIR/"
[ -f /opt/kimai/config/packages/local.yaml ] && cp /opt/kimai/config/packages/local.yaml "$BACKUP_DIR/"
msg_ok "Backup completed"
msg_info "Updating ${APP} to ${RELEASE}" msg_info "Updating ${APP} to ${RELEASE}"
cp /opt/kimai/.env /opt/.env
[ -f /opt/kimai/config/packages/local.yaml ] && cp /opt/kimai/config/packages/local.yaml /opt/local.yaml
rm -rf /opt/kimai rm -rf /opt/kimai
wget -q "https://github.com/kimai/kimai/archive/refs/tags/${RELEASE}.zip" wget -q "https://github.com/kimai/kimai/archive/refs/tags/${RELEASE}.zip"
unzip -q ${RELEASE}.zip unzip -q ${RELEASE}.zip
mv kimai-${RELEASE} /opt/kimai mv kimai-${RELEASE} /opt/kimai
mv /opt/.env /opt/kimai/.env [ -d "$BACKUP_DIR/var" ] && cp -r "$BACKUP_DIR/var" /opt/kimai/
[ -f /opt/local.yaml ] && mv /opt/local.yaml /opt/kimai/config/packages/local.yaml [ -f "$BACKUP_DIR/.env" ] && cp "$BACKUP_DIR/.env" /opt/kimai/
[ -f "$BACKUP_DIR/local.yaml" ] && cp "$BACKUP_DIR/local.yaml" /opt/kimai/config/packages/
rm -rf "$BACKUP_DIR"
cd /opt/kimai cd /opt/kimai
$STD composer install --no-dev --optimize-autoloader $STD composer install --no-dev --optimize-autoloader
$STD bin/console kimai:update $STD bin/console kimai:update
@@ -60,6 +69,7 @@ function update_script() {
msg_info "Cleaning Up" msg_info "Cleaning Up"
rm -rf ${RELEASE}.zip rm -rf ${RELEASE}.zip
rm -rf "$BACKUP_DIR"
msg_ok "Cleaned" msg_ok "Cleaned"
msg_ok "Updated Successfully" msg_ok "Updated Successfully"
else else

View File

@@ -28,14 +28,44 @@ function update_script() {
exit exit
fi fi
RELEASE=$(curl -s https://api.github.com/repos/matze/wastebin/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }') RELEASE=$(curl -s https://api.github.com/repos/matze/wastebin/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
# Dirty-Fix 03/2025 for missing APP_version.txt on old installations, set to pre-latest release
msg_info "Running Migration"
if [[ ! -f /opt/${APP}_version.txt ]]; then
echo "2.7.1" >/opt/${APP}_version.txt
mkdir -p /opt/wastebin-data
cat <<EOF >/opt/wastebin-data/.env
WASTEBIN_DATABASE_PATH=/opt/wastebin-data/wastebin.db
WASTEBIN_CACHE_SIZE=1024
WASTEBIN_HTTP_TIMEOUT=30
WASTEBIN_SIGNING_KEY=$(openssl rand -hex 32)
WASTEBIN_PASTE_EXPIRATIONS=0,600,3600=d,86400,604800,2419200,29030400
EOF
systemctl stop wastebin
cat <<EOF >/etc/systemd/system/wastebin.service
[Unit]
Description=Wastebin Service
After=network.target
[Service]
WorkingDirectory=/opt/wastebin
ExecStart=/opt/wastebin/wastebin
EnvironmentFile=/opt/wastebin-data/.env
[Install]
WantedBy=multi-user.target
EOF
systemctl daemon-reload
fi
msg_ok "Migration Done"
if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then
msg_info "Stopping Wastebin" msg_info "Stopping Wastebin"
systemctl stop wastebin systemctl stop wastebin
msg_ok "Wastebin Stopped" msg_ok "Wastebin Stopped"
msg_info "Updating Wastebin" msg_info "Updating Wastebin"
wget -q https://github.com/matze/wastebin/releases/download/${RELEASE}/wastebin_${RELEASE}_x86_64-unknown-linux-musl.tar.zst temp_file=$(mktemp)
tar -xf wastebin_${RELEASE}_x86_64-unknown-linux-musl.tar.zst wget -q https://github.com/matze/wastebin/releases/download/${RELEASE}/wastebin_${RELEASE}_x86_64-unknown-linux-musl.zip -O $temp_file
unzip -o -q $temp_file
cp -f wastebin /opt/wastebin/ cp -f wastebin /opt/wastebin/
chmod +x /opt/wastebin/wastebin chmod +x /opt/wastebin/wastebin
echo "${RELEASE}" >/opt/${APP}_version.txt echo "${RELEASE}" >/opt/${APP}_version.txt
@@ -46,8 +76,8 @@ function update_script() {
msg_ok "Started Wastebin" msg_ok "Started Wastebin"
msg_info "Cleaning Up" msg_info "Cleaning Up"
rm -rf wastebin_${RELEASE}_x86_64-unknown-linux-musl.tar.zst rm -f $temp_file
msg_ok "Cleaned" msg_ok "Cleanup Completed"
msg_ok "Updated Successfully" msg_ok "Updated Successfully"
else else
msg_ok "No update required. ${APP} is already at v${RELEASE}" msg_ok "No update required. ${APP} is already at v${RELEASE}"

View File

@@ -0,0 +1,46 @@
#!/usr/bin/env bash
# Copyright (c) 2021-2025 community-scripts ORG
# Author: Slaviša Arežina (tremor021)
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
# Source: https://github.com/inventree/InvenTree
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 \
sudo \
mc \
gnupg \
sudo
temp_file=$(mktemp)
wget -q http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_amd64.deb -O $temp_file
$STD dpkg -i $temp_file
msg_ok "Installed Dependencies"
msg_info "Setting up InvenTree Repository"
mkdir -p /etc/apt/keyrings
curl -fsSL https://dl.packager.io/srv/inventree/InvenTree/key | gpg --dearmor -o /etc/apt/keyrings/inventree.gpg
echo "deb [signed-by=/etc/apt/keyrings/inventree.gpg] https://dl.packager.io/srv/deb/inventree/InvenTree/stable/ubuntu 20.04 main" >/etc/apt/sources.list.d/inventree.list
msg_ok "Set up InvenTree Repository"
msg_info "Setup ${APPLICATION} (Patience)"
$STD apt-get update
$STD apt-get install -y inventree
msg_ok "Setup ${APPLICATION}"
motd_ssh
customize
msg_info "Cleaning up"
rm -f $temp_file
$STD apt-get -y autoremove
$STD apt-get -y autoclean
msg_ok "Cleaned"

View File

@@ -14,13 +14,14 @@ network_check
update_os update_os
msg_info "Installing Dependencies" msg_info "Installing Dependencies"
$STD apt-get install -y curl $STD apt-get install -y \
$STD apt-get install -y sudo curl \
$STD apt-get install -y mc sudo \
mc
msg_ok "Installed Dependencies" msg_ok "Installed Dependencies"
msg_info "Installing NextCloudPi (Patience)" msg_info "Installing NextCloudPi (Patience)"
$STD bash <(curl -fsSL https://raw.githubusercontent.com/nextcloud/nextcloudpi/master/install.sh) bash <(curl -fsSL https://raw.githubusercontent.com/nextcloud/nextcloudpi/master/install.sh) >/dev/null 2>&1
msg_ok "Installed NextCloudPi" msg_ok "Installed NextCloudPi"
motd_ssh motd_ssh

View File

@@ -1,8 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
# Copyright (c) 2021-2025 tteck # Copyright (c) 2021-2025 community-scripts ORG
# Author: tteck # Author: MickLesk (Canbiz)
# Co-Author: MickLesk (Canbiz)
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE # License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
# Source: https://github.com/matze/wastebin # Source: https://github.com/matze/wastebin
@@ -15,19 +14,31 @@ network_check
update_os update_os
msg_info "Installing Dependencies" msg_info "Installing Dependencies"
$STD apt-get install -y curl $STD apt-get install -y \
$STD apt-get install -y sudo curl \
$STD apt-get install -y mc sudo \
mc
msg_ok "Installed Dependencies" msg_ok "Installed Dependencies"
msg_info "Installing Wastebin" msg_info "Installing Wastebin"
temp_file=$(mktemp)
RELEASE=$(curl -s https://api.github.com/repos/matze/wastebin/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }') RELEASE=$(curl -s https://api.github.com/repos/matze/wastebin/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
wget -q https://github.com/matze/wastebin/releases/download/${RELEASE}/wastebin_${RELEASE}_x86_64-unknown-linux-musl.tar.zst wget -q https://github.com/matze/wastebin/releases/download/${RELEASE}/wastebin_${RELEASE}_x86_64-unknown-linux-musl.zip -O $temp_file
tar -xf wastebin_${RELEASE}_x86_64-unknown-linux-musl.tar.zst unzip -q $temp_file
rm -rf wastebin_${RELEASE}_x86_64-unknown-linux-musl.tar.zst
mkdir -p /opt/wastebin mkdir -p /opt/wastebin
mv wastebin /opt/wastebin/ mv wastebin /opt/wastebin/
chmod +x /opt/wastebin/wastebin chmod +x /opt/wastebin/wastebin
mkdir -p /opt/wastebin-data
cat <<EOF >/opt/wastebin-data/.env
WASTEBIN_DATABASE_PATH=/opt/wastebin-data/wastebin.db
WASTEBIN_CACHE_SIZE=1024
WASTEBIN_HTTP_TIMEOUT=30
WASTEBIN_SIGNING_KEY=$(openssl rand -hex 32)
WASTEBIN_PASTE_EXPIRATIONS=0,600,3600=d,86400,604800,2419200,29030400
EOF
echo "${RELEASE}" >"/opt/${APPLICATION}_version.txt"
msg_ok "Installed Wastebin" msg_ok "Installed Wastebin"
msg_info "Creating Service" msg_info "Creating Service"
@@ -39,17 +50,19 @@ After=network.target
[Service] [Service]
WorkingDirectory=/opt/wastebin WorkingDirectory=/opt/wastebin
ExecStart=/opt/wastebin/wastebin ExecStart=/opt/wastebin/wastebin
EnvironmentFile=/opt/wastebin-data/.env
[Install] [Install]
WantedBy=multi-user.target WantedBy=multi-user.target
EOF EOF
systemctl enable -q --now wastebin.service systemctl enable -q --now wastebin
msg_ok "Created Service" msg_ok "Created Service"
motd_ssh motd_ssh
customize customize
msg_info "Cleaning up" msg_info "Cleaning up"
rm -f $temp_file
$STD apt-get -y autoremove $STD apt-get -y autoremove
$STD apt-get -y autoclean $STD apt-get -y autoclean
msg_ok "Cleaned" msg_ok "Cleaned"

39
json/inventree.json Normal file
View File

@@ -0,0 +1,39 @@
{
"name": "InvenTree",
"slug": "inventree",
"categories": [
25
],
"date_created": "2025-03-06",
"type": "ct",
"updateable": true,
"privileged": false,
"interface_port": 80,
"documentation": "https://docs.inventree.org/en/latest/",
"website": "https://inventree.org",
"logo": "https://cdn.jsdelivr.net/gh/selfhst/icons/svg/inventree.svg",
"description": "InvenTree is an open-source inventory management system which provides intuitive parts management and stock control. It is designed to be lightweight and easy to use for SME or hobbyist applications.",
"install_methods": [
{
"type": "default",
"script": "ct/inventree.sh",
"resources": {
"cpu": 2,
"ram": 2048,
"hdd": 6,
"os": "debian",
"version": "12"
}
}
],
"default_credentials": {
"username": "admin",
"password": "`cat /etc/inventree/admin_password.txt`"
},
"notes": [
{
"text": "Please read the documentation for your configuration needs.",
"type": "info"
}
]
}

View File

@@ -454,7 +454,7 @@ done
msg_info "Creating a Arch Linux VM" msg_info "Creating a Arch Linux VM"
qm create $VMID -agent 1${MACHINE} -tablet 0 -localtime 1 -bios ovmf${CPU_TYPE} -cores $CORE_COUNT -memory $RAM_SIZE \ qm create $VMID -agent 1${MACHINE} -tablet 0 -localtime 1 -bios ovmf${CPU_TYPE} -cores $CORE_COUNT -memory $RAM_SIZE \
-name $HN -tags community-scripts -net0 virtio,bridge=$BRG,macaddr=$MAC$VLAN$MTU -onboot 1 -ostype l26 -scsihw virtio-scsi-pci -name $HN -tags community-script -net0 virtio,bridge=$BRG,macaddr=$MAC$VLAN$MTU -onboot 1 -ostype l26 -scsihw virtio-scsi-pci
pvesm alloc $STORAGE $VMID $DISK0 4M 1>&/dev/null pvesm alloc $STORAGE $VMID $DISK0 4M 1>&/dev/null
qm importdisk $VMID ${FILE} $STORAGE ${DISK_IMPORT:-} 1>&/dev/null qm importdisk $VMID ${FILE} $STORAGE ${DISK_IMPORT:-} 1>&/dev/null
qm set $VMID \ qm set $VMID \

View File

@@ -565,7 +565,7 @@ qm set $VMID \
-scsi0 ${DISK1_REF},${DISK_CACHE}${THIN}size=2G \ -scsi0 ${DISK1_REF},${DISK_CACHE}${THIN}size=2G \
-boot order=scsi0 \ -boot order=scsi0 \
-serial0 socket >/dev/null \ -serial0 socket >/dev/null \
-tags community-scripts -tags community-script
qm resize $VMID scsi0 10G >/dev/null qm resize $VMID scsi0 10G >/dev/null
DESCRIPTION=$(cat <<EOF DESCRIPTION=$(cat <<EOF
<div align='center'> <div align='center'>