mirror of
https://github.com/community-scripts/ProxmoxVE
synced 2025-02-10 09:49:18 +00:00
Compare commits
18 Commits
da3fa9a2db
...
b440f41118
Author | SHA1 | Date | |
---|---|---|---|
|
b440f41118 | ||
|
d712be955c | ||
|
701f7e9cba | ||
|
5196539d1b | ||
|
774cdcaf8d | ||
|
784e109012 | ||
|
5184f47eb6 | ||
|
f7d37a8f3c | ||
|
4888c33e4b | ||
|
f98d81f5bf | ||
|
d7518d8644 | ||
|
599c462035 | ||
|
0909132d5c | ||
|
5123532729 | ||
|
d814907f99 | ||
|
32a99a44d4 | ||
|
e94280f1a1 | ||
|
b9ca4b7634 |
2
.github/workflows/changelog-pr.yml
vendored
2
.github/workflows/changelog-pr.yml
vendored
@ -157,6 +157,7 @@ jobs:
|
|||||||
if [ -n "$PR_NUMBER" ]; then
|
if [ -n "$PR_NUMBER" ]; then
|
||||||
gh pr review $PR_NUMBER --approve
|
gh pr review $PR_NUMBER --approve
|
||||||
fi
|
fi
|
||||||
|
|
||||||
- name: Re-approve pull request after update
|
- name: Re-approve pull request after update
|
||||||
if: steps.verify-diff.outputs.changed == 'true'
|
if: steps.verify-diff.outputs.changed == 'true'
|
||||||
env:
|
env:
|
||||||
@ -166,4 +167,3 @@ jobs:
|
|||||||
if [ -n "$PR_NUMBER" ]; then
|
if [ -n "$PR_NUMBER" ]; then
|
||||||
gh pr review $PR_NUMBER --approve
|
gh pr review $PR_NUMBER --approve
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -64,7 +64,7 @@ jobs:
|
|||||||
script: |
|
script: |
|
||||||
const result = "${{ job.status }}" === "success" ? "success" : "failure";
|
const result = "${{ job.status }}" === "success" ? "success" : "failure";
|
||||||
const diff = Buffer.from(
|
const diff = Buffer.from(
|
||||||
"${{ steps.shfmt.outputs.diff }}",
|
${{ steps.shfmt.outputs.diff }},
|
||||||
"base64",
|
"base64",
|
||||||
).toString();
|
).toString();
|
||||||
const issueNumber = context.payload.pull_request
|
const issueNumber = context.payload.pull_request
|
||||||
@ -75,7 +75,7 @@ jobs:
|
|||||||
|
|
||||||
if (result === "failure") {
|
if (result === "failure") {
|
||||||
newCommentBody +=
|
newCommentBody +=
|
||||||
":x: We found issues in the formatting of the following changed files:\n\n\`\`\`diff\n${diff}\n\`\`\`\n";
|
`:x: We found issues in the formatting of the following changed files:\n\n\`\`\`diff\n${diff}\n\`\`\`\n`;
|
||||||
} else {
|
} else {
|
||||||
newCommentBody += `:rocket: All changed shell scripts are formatted correctly!\n`;
|
newCommentBody += `:rocket: All changed shell scripts are formatted correctly!\n`;
|
||||||
}
|
}
|
23
CHANGELOG.md
23
CHANGELOG.md
@ -16,6 +16,29 @@ All LXC instances created using this repository come pre-installed with Midnight
|
|||||||
> [!IMPORTANT]
|
> [!IMPORTANT]
|
||||||
Do not break established syntax in this file, as it is automatically updated by a Github Workflow
|
Do not break established syntax in this file, as it is automatically updated by a Github Workflow
|
||||||
|
|
||||||
|
## 2025-01-06
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
### ✨ New Scripts
|
||||||
|
|
||||||
|
- New Script: Typesense [@tlissak](https://github.com/tlissak) ([#1291](https://github.com/community-scripts/ProxmoxVE/pull/1291))
|
||||||
|
- New script: GLPI [@opastorello](https://github.com/opastorello) ([#1201](https://github.com/community-scripts/ProxmoxVE/pull/1201))
|
||||||
|
|
||||||
|
### 🚀 Updated Scripts
|
||||||
|
|
||||||
|
- [Fix]: Fixed rm Bug in pf2etools [@MickLesk](https://github.com/MickLesk) ([#1292](https://github.com/community-scripts/ProxmoxVE/pull/1292))
|
||||||
|
- Fix: Homebox Update Script [@MickLesk](https://github.com/MickLesk) ([#1284](https://github.com/community-scripts/ProxmoxVE/pull/1284))
|
||||||
|
- Add ca-certificates for Install (Frigate) [@MickLesk](https://github.com/MickLesk) ([#1282](https://github.com/community-scripts/ProxmoxVE/pull/1282))
|
||||||
|
- fix: buffer from base64 in formatting pipeline [@se-bastiaan](https://github.com/se-bastiaan) ([#1285](https://github.com/community-scripts/ProxmoxVE/pull/1285))
|
||||||
|
|
||||||
|
### 🧰 Maintenance
|
||||||
|
|
||||||
|
- Add reapproval of Changelog-PR [@MickLesk](https://github.com/MickLesk) ([#1279](https://github.com/community-scripts/ProxmoxVE/pull/1279))
|
||||||
|
- ci: combine header checks into workflow with PR comment [@se-bastiaan](https://github.com/se-bastiaan) ([#1257](https://github.com/community-scripts/ProxmoxVE/pull/1257))
|
||||||
|
- ci: change filename checks into steps with PR comment [@se-bastiaan](https://github.com/se-bastiaan) ([#1255](https://github.com/community-scripts/ProxmoxVE/pull/1255))
|
||||||
|
- ci: add pipeline for code formatting checks [@se-bastiaan](https://github.com/se-bastiaan) ([#1239](https://github.com/community-scripts/ProxmoxVE/pull/1239))
|
||||||
|
|
||||||
## 2025-01-05
|
## 2025-01-05
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
52
ct/glpi.sh
Normal file
52
ct/glpi.sh
Normal file
@ -0,0 +1,52 @@
|
|||||||
|
#!/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: Nícolas Pastorello (opastorello)
|
||||||
|
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||||
|
|
||||||
|
# App Default Values
|
||||||
|
APP="GLPI"
|
||||||
|
var_tags="asset-management;foss"
|
||||||
|
var_cpu="2"
|
||||||
|
var_ram="2048"
|
||||||
|
var_disk="10"
|
||||||
|
var_os="debian"
|
||||||
|
var_version="12"
|
||||||
|
var_unprivileged="1"
|
||||||
|
|
||||||
|
# App Output & Base Settings
|
||||||
|
header_info "$APP"
|
||||||
|
base_settings
|
||||||
|
|
||||||
|
# Core
|
||||||
|
variables
|
||||||
|
color
|
||||||
|
catch_errors
|
||||||
|
|
||||||
|
function update_script() {
|
||||||
|
header_info
|
||||||
|
check_container_storage
|
||||||
|
check_container_resources
|
||||||
|
|
||||||
|
if [[ ! -d /opt/glpi ]]; then
|
||||||
|
msg_error "No ${APP} Installation Found!"
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
RELEASE=$(curl -s https://api.github.com/repos/glpi-project/glpi/releases/latest | grep '"tag_name"' | sed -E 's/.*"tag_name": "([^"]+)".*/\1/')
|
||||||
|
if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then
|
||||||
|
msg_error "Ther is currently no automatic update function for ${APP}."
|
||||||
|
else
|
||||||
|
msg_ok "No update required. ${APP} is already at v${RELEASE}."
|
||||||
|
fi
|
||||||
|
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}:80${CL}"
|
@ -40,8 +40,10 @@ function update_script() {
|
|||||||
msg_info "Updating ${APP} to ${RELEASE}"
|
msg_info "Updating ${APP} to ${RELEASE}"
|
||||||
cd /opt
|
cd /opt
|
||||||
rm -rf homebox_bak
|
rm -rf homebox_bak
|
||||||
|
rm -rf /tmp/homebox.tar.gz
|
||||||
mv homebox homebox_bak
|
mv homebox homebox_bak
|
||||||
wget -qO- https://github.com/sysadminsmedia/homebox/releases/download/${RELEASE}/homebox_Linux_x86_64.tar.gz | tar -xzf - -C /opt
|
wget -qO /tmp/homebox.tar.gz https://github.com/sysadminsmedia/homebox/releases/download/${RELEASE}/homebox_Linux_x86_64.tar.gz
|
||||||
|
tar -xzf /tmp/homebox.tar.gz -C /opt
|
||||||
chmod +x /opt/homebox
|
chmod +x /opt/homebox
|
||||||
echo "${RELEASE}" >/opt/${APP}_version.txt
|
echo "${RELEASE}" >/opt/${APP}_version.txt
|
||||||
msg_ok "Updated Homebox"
|
msg_ok "Updated Homebox"
|
||||||
|
@ -45,15 +45,14 @@ function update_script() {
|
|||||||
|
|
||||||
# Execute Update
|
# Execute Update
|
||||||
msg_info "Updating ${APP}"
|
msg_info "Updating ${APP}"
|
||||||
cd "/opt/${APP}"
|
cd /opt
|
||||||
wget -q "https://github.com/Pf2eToolsOrg/Pf2eTools/archive/refs/tags/${RELEASE}.zip"
|
wget -q "https://github.com/Pf2eToolsOrg/Pf2eTools/archive/refs/tags/${RELEASE}.zip"
|
||||||
unzip -q "${RELEASE}.zip"
|
unzip -q ${RELEASE}.zip
|
||||||
rm -rf "/opt/${APP}"
|
rm -rf "/opt/${APP}"
|
||||||
mv "${APP}-${RELEASE:1}" "/opt/${APP}"
|
mv ${APP}-${RELEASE:1} /opt/${APP}
|
||||||
cd /opt/Pf2eTools
|
cd /opt/Pf2eTools
|
||||||
$STD npm install
|
$STD npm install
|
||||||
$STD npm run build
|
$STD npm run build
|
||||||
cd ~
|
|
||||||
echo "${RELEASE}" >"/opt/${APP}_version.txt"
|
echo "${RELEASE}" >"/opt/${APP}_version.txt"
|
||||||
msg_ok "Updated ${APP}"
|
msg_ok "Updated ${APP}"
|
||||||
|
|
||||||
@ -62,7 +61,7 @@ function update_script() {
|
|||||||
|
|
||||||
# Cleaning up
|
# Cleaning up
|
||||||
msg_info "Cleaning Up"
|
msg_info "Cleaning Up"
|
||||||
rm -rf /opt/${APP}/${RELEASE}.zip
|
rm -rf /opt/${RELEASE}.zip
|
||||||
$STD apt-get -y autoremove
|
$STD apt-get -y autoremove
|
||||||
$STD apt-get -y autoclean
|
$STD apt-get -y autoclean
|
||||||
msg_ok "Cleanup Completed"
|
msg_ok "Cleanup Completed"
|
||||||
|
54
ct/typesense.sh
Normal file
54
ct/typesense.sh
Normal file
@ -0,0 +1,54 @@
|
|||||||
|
#!/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: tlissak | Co-Author MickLesk
|
||||||
|
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||||
|
# Source: https://typesense.org/
|
||||||
|
|
||||||
|
# App Default Values
|
||||||
|
APP="TypeSense"
|
||||||
|
var_tags="database"
|
||||||
|
var_cpu="1"
|
||||||
|
var_ram="1024"
|
||||||
|
var_disk="4"
|
||||||
|
var_os="debian"
|
||||||
|
var_version="12"
|
||||||
|
var_unprivileged="1"
|
||||||
|
|
||||||
|
# App Output & Base Settings
|
||||||
|
header_info "$APP"
|
||||||
|
base_settings
|
||||||
|
|
||||||
|
# Core
|
||||||
|
variables
|
||||||
|
color
|
||||||
|
catch_errors
|
||||||
|
|
||||||
|
function update_script() {
|
||||||
|
header_info
|
||||||
|
check_container_storage
|
||||||
|
check_container_resources
|
||||||
|
if [[ ! -f /etc/typesense/typesense-server.ini ]]; then
|
||||||
|
msg_error "No ${APP} Installation Found!"
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
RELEASE=$(curl -s https://api.github.com/repos/typesense/typesense/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
||||||
|
if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then
|
||||||
|
msg_info "Updating ${APP} LXC"
|
||||||
|
apt-get update &>/dev/null
|
||||||
|
apt-get -y upgrade &>/dev/null
|
||||||
|
msg_ok "Updated Successfully"
|
||||||
|
else
|
||||||
|
msg_ok "No update required. ${APP} is already at ${RELEASE}"
|
||||||
|
fi
|
||||||
|
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 IP:${CL}"
|
||||||
|
echo -e "${TAB}${GATEWAY}${BGN}${IP}:8108${CL}"
|
@ -15,7 +15,7 @@ network_check
|
|||||||
update_os
|
update_os
|
||||||
|
|
||||||
msg_info "Installing Dependencies (Patience)"
|
msg_info "Installing Dependencies (Patience)"
|
||||||
$STD apt-get install -y {curl,sudo,mc,git,gpg,automake,build-essential,xz-utils,libtool,ccache,pkg-config,libgtk-3-dev,libavcodec-dev,libavformat-dev,libswscale-dev,libv4l-dev,libxvidcore-dev,libx264-dev,libjpeg-dev,libpng-dev,libtiff-dev,gfortran,openexr,libatlas-base-dev,libssl-dev,libtbb2,libtbb-dev,libdc1394-22-dev,libopenexr-dev,libgstreamer-plugins-base1.0-dev,libgstreamer1.0-dev,gcc,gfortran,libopenblas-dev,liblapack-dev,libusb-1.0-0-dev,jq,moreutils}
|
$STD apt-get install -y {curl,sudo,mc,git,gpg,ca-certificates,automake,build-essential,xz-utils,libtool,ccache,pkg-config,libgtk-3-dev,libavcodec-dev,libavformat-dev,libswscale-dev,libv4l-dev,libxvidcore-dev,libx264-dev,libjpeg-dev,libpng-dev,libtiff-dev,gfortran,openexr,libatlas-base-dev,libssl-dev,libtbb2,libtbb-dev,libdc1394-22-dev,libopenexr-dev,libgstreamer-plugins-base1.0-dev,libgstreamer1.0-dev,gcc,gfortran,libopenblas-dev,liblapack-dev,libusb-1.0-0-dev,jq,moreutils}
|
||||||
msg_ok "Installed Dependencies"
|
msg_ok "Installed Dependencies"
|
||||||
|
|
||||||
msg_info "Installing Python3 Dependencies"
|
msg_info "Installing Python3 Dependencies"
|
||||||
|
151
install/glpi-install.sh
Normal file
151
install/glpi-install.sh
Normal file
@ -0,0 +1,151 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Copyright (c) 2021-2025 community-scripts ORG
|
||||||
|
# Author: Nícolas Pastorello (opastorello)
|
||||||
|
# License: MIT | https://github.com/community-scripts/ProxmoxVE/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 \
|
||||||
|
git \
|
||||||
|
sudo \
|
||||||
|
mc \
|
||||||
|
apache2 \
|
||||||
|
php8.2-{apcu,cli,common,curl,gd,imap,ldap,mysql,xmlrpc,xml,mbstring,bcmath,intl,zip,redis,bz2,soap} \
|
||||||
|
php-cas \
|
||||||
|
libapache2-mod-php \
|
||||||
|
mariadb-server
|
||||||
|
msg_ok "Installed Dependencies"
|
||||||
|
|
||||||
|
msg_info "Setting up database"
|
||||||
|
DB_NAME=glpi_db
|
||||||
|
DB_USER=glpi
|
||||||
|
DB_PASS=$(openssl rand -base64 18 | tr -dc 'a-zA-Z0-9' | head -c13)
|
||||||
|
mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql mysql
|
||||||
|
mysql -u root -e "CREATE DATABASE $DB_NAME;"
|
||||||
|
mysql -u root -e "CREATE USER '$DB_USER'@'localhost' IDENTIFIED BY '$DB_PASS';"
|
||||||
|
mysql -u root -e "GRANT ALL PRIVILEGES ON $DB_NAME.* TO '$DB_USER'@'localhost';"
|
||||||
|
mysql -u root -e "GRANT SELECT ON \`mysql\`.\`time_zone_name\` TO '$DB_USER'@'localhost'; FLUSH PRIVILEGES;"
|
||||||
|
{
|
||||||
|
echo "GLPI Database Credentials"
|
||||||
|
echo "Database: $DB_NAME"
|
||||||
|
echo "Username: $DB_USER"
|
||||||
|
echo "Password: $DB_PASS"
|
||||||
|
} >> ~/glpi_db.creds
|
||||||
|
msg_ok "Set up database"
|
||||||
|
|
||||||
|
msg_info "Installing GLPi"
|
||||||
|
cd /opt
|
||||||
|
RELEASE=$(curl -s https://api.github.com/repos/glpi-project/glpi/releases/latest | grep '"tag_name"' | sed -E 's/.*"tag_name": "([^"]+)".*/\1/')
|
||||||
|
wget -q "https://github.com/glpi-project/glpi/releases/download/${RELEASE}/glpi-${RELEASE}.tgz"
|
||||||
|
$STD tar -xzvf glpi-${RELEASE}.tgz
|
||||||
|
cd /opt/glpi
|
||||||
|
$STD php bin/console db:install --db-name=$DB_NAME --db-user=$DB_USER --db-password=$DB_PASS --no-interaction
|
||||||
|
echo "${RELEASE}" >/opt/${APPLICATION}_version.txt
|
||||||
|
msg_ok "Installed GLPi"
|
||||||
|
|
||||||
|
msg_info "Setting Downstream file"
|
||||||
|
cat <<EOF > /opt/glpi/inc/downstream.php
|
||||||
|
<?php
|
||||||
|
define('GLPI_CONFIG_DIR', '/etc/glpi/');
|
||||||
|
if (file_exists(GLPI_CONFIG_DIR . '/local_define.php')) {
|
||||||
|
require_once GLPI_CONFIG_DIR . '/local_define.php';
|
||||||
|
}
|
||||||
|
EOF
|
||||||
|
|
||||||
|
mv /opt/glpi/config /etc/glpi
|
||||||
|
mv /opt/glpi/files /var/lib/glpi
|
||||||
|
mv /var/lib/glpi/_log /var/log/glpi
|
||||||
|
|
||||||
|
cat <<EOF > /etc/glpi/local_define.php
|
||||||
|
<?php
|
||||||
|
define('GLPI_VAR_DIR', '/var/lib/glpi');
|
||||||
|
define('GLPI_DOC_DIR', GLPI_VAR_DIR);
|
||||||
|
define('GLPI_CRON_DIR', GLPI_VAR_DIR . '/_cron');
|
||||||
|
define('GLPI_DUMP_DIR', GLPI_VAR_DIR . '/_dumps');
|
||||||
|
define('GLPI_GRAPH_DIR', GLPI_VAR_DIR . '/_graphs');
|
||||||
|
define('GLPI_LOCK_DIR', GLPI_VAR_DIR . '/_lock');
|
||||||
|
define('GLPI_PICTURE_DIR', GLPI_VAR_DIR . '/_pictures');
|
||||||
|
define('GLPI_PLUGIN_DOC_DIR', GLPI_VAR_DIR . '/_plugins');
|
||||||
|
define('GLPI_RSS_DIR', GLPI_VAR_DIR . '/_rss');
|
||||||
|
define('GLPI_SESSION_DIR', GLPI_VAR_DIR . '/_sessions');
|
||||||
|
define('GLPI_TMP_DIR', GLPI_VAR_DIR . '/_tmp');
|
||||||
|
define('GLPI_UPLOAD_DIR', GLPI_VAR_DIR . '/_uploads');
|
||||||
|
define('GLPI_CACHE_DIR', GLPI_VAR_DIR . '/_cache');
|
||||||
|
define('GLPI_LOG_DIR', '/var/log/glpi');
|
||||||
|
EOF
|
||||||
|
msg_ok "Configured Downstream file"
|
||||||
|
|
||||||
|
msg_info "Setting Folder and File Permissions"
|
||||||
|
chown root:root /opt/glpi/ -R
|
||||||
|
chown www-data:www-data /etc/glpi -R
|
||||||
|
chown www-data:www-data /var/lib/glpi -R
|
||||||
|
chown www-data:www-data /var/log/glpi -R
|
||||||
|
chown www-data:www-data /opt/glpi/marketplace -Rf
|
||||||
|
find /opt/glpi/ -type f -exec chmod 0644 {} \;
|
||||||
|
find /opt/glpi/ -type d -exec chmod 0755 {} \;
|
||||||
|
find /etc/glpi -type f -exec chmod 0644 {} \;
|
||||||
|
find /etc/glpi -type d -exec chmod 0755 {} \;
|
||||||
|
find /var/lib/glpi -type f -exec chmod 0644 {} \;
|
||||||
|
find /var/lib/glpi -type d -exec chmod 0755 {} \;
|
||||||
|
find /var/log/glpi -type f -exec chmod 0644 {} \;
|
||||||
|
find /var/log/glpi -type d -exec chmod 0755 {} \;
|
||||||
|
msg_ok "Configured Folder and File Permissions"
|
||||||
|
|
||||||
|
msg_info "Setup Service"
|
||||||
|
cat <<EOF >/etc/apache2/sites-available/glpi.conf
|
||||||
|
<VirtualHost *:80>
|
||||||
|
ServerName localhost
|
||||||
|
DocumentRoot /opt/glpi/public
|
||||||
|
|
||||||
|
<Directory /opt/glpi/public>
|
||||||
|
Require all granted
|
||||||
|
RewriteEngine On
|
||||||
|
RewriteCond %{HTTP:Authorization} ^(.+)$
|
||||||
|
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
|
||||||
|
RewriteCond %{REQUEST_FILENAME} !-f
|
||||||
|
RewriteRule ^(.*)$ index.php [QSA,L]
|
||||||
|
</Directory>
|
||||||
|
|
||||||
|
ErrorLog \${APACHE_LOG_DIR}/glpi_error.log
|
||||||
|
CustomLog \${APACHE_LOG_DIR}/glpi_access.log combined
|
||||||
|
</VirtualHost>
|
||||||
|
EOF
|
||||||
|
$STD a2dissite 000-default.conf
|
||||||
|
$STD a2enmod rewrite
|
||||||
|
$STD a2ensite glpi.conf
|
||||||
|
msg_ok "Setup Service"
|
||||||
|
|
||||||
|
msg_info "Setup Cronjob"
|
||||||
|
(crontab -l 2>/dev/null; echo "* * * * * php /opt/glpi/front/cron.php") | crontab -
|
||||||
|
msg_ok "Setup Cronjob"
|
||||||
|
|
||||||
|
msg_info "Update PHP Params"
|
||||||
|
PHP_VERSION=$(ls /etc/php/ | grep -E '^[0-9]+\.[0-9]+$' | head -n 1)
|
||||||
|
PHP_INI="/etc/php/$PHP_VERSION/apache2/php.ini"
|
||||||
|
sed -i 's/^upload_max_filesize = .*/upload_max_filesize = 20M/' $PHP_INI
|
||||||
|
sed -i 's/^post_max_size = .*/post_max_size = 20M/' $PHP_INI
|
||||||
|
sed -i 's/^max_execution_time = .*/max_execution_time = 60/' $PHP_INI
|
||||||
|
sed -i 's/^max_input_vars = .*/max_input_vars = 5000/' $PHP_INI
|
||||||
|
sed -i 's/^memory_limit = .*/memory_limit = 256M/' $PHP_INI
|
||||||
|
sed -i 's/^;\?\s*session.cookie_httponly\s*=.*/session.cookie_httponly = On/' $PHP_INI
|
||||||
|
systemctl restart apache2
|
||||||
|
msg_ok "Update PHP Params"
|
||||||
|
|
||||||
|
motd_ssh
|
||||||
|
customize
|
||||||
|
|
||||||
|
msg_info "Cleaning up"
|
||||||
|
rm -rf /opt/glpi/install
|
||||||
|
rm -rf /opt/glpi-${RELEASE}.tgz
|
||||||
|
$STD apt-get -y autoremove
|
||||||
|
$STD apt-get -y autoclean
|
||||||
|
msg_ok "Cleaned"
|
@ -56,11 +56,11 @@ $STD composer install --no-dev --optimize-autoloader --no-interaction
|
|||||||
cp .env.dist .env
|
cp .env.dist .env
|
||||||
sed -i "/^DATABASE_URL=/c\DATABASE_URL=mysql://$DB_USER:$DB_PASS@127.0.0.1:3306/$DB_NAME?charset=utf8mb4&serverVersion=$MYSQL_VERSION" /opt/kimai/.env
|
sed -i "/^DATABASE_URL=/c\DATABASE_URL=mysql://$DB_USER:$DB_PASS@127.0.0.1:3306/$DB_NAME?charset=utf8mb4&serverVersion=$MYSQL_VERSION" /opt/kimai/.env
|
||||||
$STD bin/console kimai:install -n
|
$STD bin/console kimai:install -n
|
||||||
chown -R :www-data /opt/kimai
|
chown -R :www-data /opt/*
|
||||||
chmod -R g+r /opt/kimai
|
chmod -R g+r /opt/*
|
||||||
chmod -R g+rw /opt/kimai
|
chmod -R g+rw /opt/*
|
||||||
sudo chown -R www-data:www-data /opt/kimai
|
sudo chown -R www-data:www-data /opt/*
|
||||||
sudo chmod -R 755 /opt/kimai
|
sudo chmod -R 755 /opt/*
|
||||||
$STD expect <<EOF
|
$STD expect <<EOF
|
||||||
set timeout -1
|
set timeout -1
|
||||||
log_user 0
|
log_user 0
|
||||||
|
@ -38,6 +38,7 @@ msg_ok "Installed Node.js"
|
|||||||
|
|
||||||
# Setup App
|
# Setup App
|
||||||
msg_info "Setup Pf2eTools"
|
msg_info "Setup Pf2eTools"
|
||||||
|
cd /opt
|
||||||
RELEASE=$(curl -s https://api.github.com/repos/Pf2eToolsOrg/Pf2eTools/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
|
RELEASE=$(curl -s https://api.github.com/repos/Pf2eToolsOrg/Pf2eTools/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
|
||||||
wget -q "https://github.com/Pf2eToolsOrg/Pf2eTools/archive/refs/tags/${RELEASE}.zip"
|
wget -q "https://github.com/Pf2eToolsOrg/Pf2eTools/archive/refs/tags/${RELEASE}.zip"
|
||||||
unzip -q "${RELEASE}.zip"
|
unzip -q "${RELEASE}.zip"
|
||||||
@ -65,7 +66,7 @@ msg_ok "Created Service"
|
|||||||
|
|
||||||
# Cleanup
|
# Cleanup
|
||||||
msg_info "Cleaning up"
|
msg_info "Cleaning up"
|
||||||
rm "${RELEASE}.zip"
|
rm -rf /opt/${RELEASE}.zip
|
||||||
$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
install/typesense-install.sh
Normal file
39
install/typesense-install.sh
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Copyright (c) 2021-2025 community-scripts ORG
|
||||||
|
# Author: tlissak
|
||||||
|
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||||
|
# Source: https://typesense.org/
|
||||||
|
|
||||||
|
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 \
|
||||||
|
mc \
|
||||||
|
sudo
|
||||||
|
msg_ok "Installed Dependencies"
|
||||||
|
|
||||||
|
msg_info "Installing TypeSense"
|
||||||
|
RELEASE=$(curl -s https://api.github.com/repos/typesense/typesense/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
||||||
|
cd /opt
|
||||||
|
wget -q https://dl.typesense.org/releases/${RELEASE}/typesense-server-${RELEASE}-amd64.deb
|
||||||
|
$STD apt install -y /opt/typesense-server-${RELEASE}-amd64.deb
|
||||||
|
echo 'enable-cors = true' >> /etc/typesense/typesense-server.ini
|
||||||
|
echo "${RELEASE}" >"/opt/${APPLICATION}_version.txt"
|
||||||
|
msg_ok "Installed TypeSense"
|
||||||
|
|
||||||
|
motd_ssh
|
||||||
|
customize
|
||||||
|
|
||||||
|
msg_info "Cleaning up"
|
||||||
|
rm -rf /opt/typesense-server-${RELEASE}-amd64.deb
|
||||||
|
$STD apt-get -y autoremove
|
||||||
|
$STD apt-get -y autoclean
|
||||||
|
msg_ok "Cleaned"
|
34
json/glpi.json
Normal file
34
json/glpi.json
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
{
|
||||||
|
"name": "GLPI",
|
||||||
|
"slug": "glpi",
|
||||||
|
"categories": [
|
||||||
|
0
|
||||||
|
],
|
||||||
|
"date_created": "2025-01-06",
|
||||||
|
"type": "ct",
|
||||||
|
"updateable": false,
|
||||||
|
"privileged": false,
|
||||||
|
"interface_port": 80,
|
||||||
|
"documentation": "https://glpi-project.org/documentation/",
|
||||||
|
"website": "https://glpi-project.org/",
|
||||||
|
"logo": "https://raw.githubusercontent.com/glpi-project/glpi/refs/heads/main/public/pics/login_logo_glpi.png",
|
||||||
|
"description": "GLPI is a Free Asset and IT Management Software package, Data center management, ITIL Service Desk, licenses tracking and software auditing.",
|
||||||
|
"install_methods": [
|
||||||
|
{
|
||||||
|
"type": "default",
|
||||||
|
"script": "ct/glpi.sh",
|
||||||
|
"resources": {
|
||||||
|
"cpu": 2,
|
||||||
|
"ram": 2048,
|
||||||
|
"hdd": 10,
|
||||||
|
"os": "Debian",
|
||||||
|
"version": "12"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"default_credentials": {
|
||||||
|
"username": "glpi",
|
||||||
|
"password": "glpi"
|
||||||
|
},
|
||||||
|
"notes": []
|
||||||
|
}
|
39
json/typesense.json
Normal file
39
json/typesense.json
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
{
|
||||||
|
"name": "TypeSense",
|
||||||
|
"slug": "typesense",
|
||||||
|
"categories": [
|
||||||
|
5
|
||||||
|
],
|
||||||
|
"date_created": "2025-01-06",
|
||||||
|
"type": "ct",
|
||||||
|
"updateable": true,
|
||||||
|
"privileged": false,
|
||||||
|
"interface_port": null,
|
||||||
|
"documentation": "https://typesense.org/docs/",
|
||||||
|
"website": "https://typesense.org/",
|
||||||
|
"logo": "https://typesense.org/_nuxt/img/typesense_logo_white.0f9fb0a.svg",
|
||||||
|
"description": "Typesense is an open-source, fast, and lightweight search engine optimized for delivering instant, relevant, and typo-tolerant search results. Designed for ease of use and high performance, it offers features like real-time indexing, fuzzy matching, customizable relevance ranking, and a simple API for integration. Typesense is particularly well-suited for applications requiring instant search capabilities, such as e-commerce, documentation, or any content-rich websites. It is often compared to tools like Elasticsearch but is more developer-friendly and less resource-intensive.",
|
||||||
|
"install_methods": [
|
||||||
|
{
|
||||||
|
"type": "default",
|
||||||
|
"script": "ct/typesense.sh",
|
||||||
|
"resources": {
|
||||||
|
"cpu": 1,
|
||||||
|
"ram": 1024,
|
||||||
|
"hdd": 4,
|
||||||
|
"os": "debian",
|
||||||
|
"version": "12"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"default_credentials": {
|
||||||
|
"username": null,
|
||||||
|
"password": null
|
||||||
|
},
|
||||||
|
"notes": [
|
||||||
|
{
|
||||||
|
"text": "This script requires some extra steps after the installation, Please checkout the 'documentation' Button",
|
||||||
|
"type": "info"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user