fixes
This commit is contained in:
parent
aad0ee8120
commit
801f27c54a
|
|
@ -1,48 +1,48 @@
|
||||||
{
|
{
|
||||||
"name": "MySQL",
|
"name": "MySQL",
|
||||||
"slug": "mysql",
|
"slug": "mysql",
|
||||||
"categories": [
|
"categories": [
|
||||||
8
|
8
|
||||||
],
|
],
|
||||||
"date_created": "2024-10-10",
|
"date_created": "2024-10-10",
|
||||||
"type": "ct",
|
"type": "ct",
|
||||||
"updateable": true,
|
"updateable": true,
|
||||||
"privileged": false,
|
"privileged": false,
|
||||||
"interface_port": null,
|
"interface_port": null,
|
||||||
"documentation": "https://dev.mysql.com/doc/",
|
"documentation": "https://dev.mysql.com/doc/",
|
||||||
"website": "https://www.mysql.com/",
|
"website": "https://www.mysql.com/",
|
||||||
"logo": "https://cdn.jsdelivr.net/gh/selfhst/icons/webp/mysql.webp",
|
"logo": "https://cdn.jsdelivr.net/gh/selfhst/icons/webp/mysql.webp",
|
||||||
"config_path": "",
|
"config_path": "",
|
||||||
"description": "MySQL is an open-source relational database management system (RDBMS) that uses SQL for managing and manipulating data. It is known for its scalability, reliability, and high performance, making it suitable for small to large-scale applications. Key features include support for ACID transactions, data replication for high availability, and compatibility with various programming languages like Python, PHP, and Java.",
|
"description": "MySQL is an open-source relational database management system (RDBMS) that uses SQL for managing and manipulating data. It is known for its scalability, reliability, and high performance, making it suitable for small to large-scale applications. Key features include support for ACID transactions, data replication for high availability, and compatibility with various programming languages like Python, PHP, and Java.",
|
||||||
"install_methods": [
|
"install_methods": [
|
||||||
{
|
{
|
||||||
"type": "default",
|
"type": "default",
|
||||||
"script": "ct/mysql.sh",
|
"script": "ct/mysql.sh",
|
||||||
"resources": {
|
"resources": {
|
||||||
"cpu": 1,
|
"cpu": 1,
|
||||||
"ram": 1024,
|
"ram": 1024,
|
||||||
"hdd": 4,
|
"hdd": 4,
|
||||||
"os": "debian",
|
"os": "debian",
|
||||||
"version": "13"
|
"version": "12"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"default_credentials": {
|
"default_credentials": {
|
||||||
"username": null,
|
"username": null,
|
||||||
"password": null
|
"password": null
|
||||||
|
},
|
||||||
|
"notes": [
|
||||||
|
{
|
||||||
|
"text": "Database credentials: `cat mysql.creds`",
|
||||||
|
"type": "info"
|
||||||
},
|
},
|
||||||
"notes": [
|
{
|
||||||
{
|
"text": "With an option to install the MySQL 8.4 LTS release instead of MySQL 8.0",
|
||||||
"text": "Database credentials: `cat mysql.creds`",
|
"type": "info"
|
||||||
"type": "info"
|
},
|
||||||
},
|
{
|
||||||
{
|
"text": "If installed, access phpMyAdmin at `http://<LXC_IP>/phpMyAdmin`, case sensitive.",
|
||||||
"text": "With an option to install the MySQL 8.4 LTS release instead of MySQL 8.0",
|
"type": "info"
|
||||||
"type": "info"
|
}
|
||||||
},
|
]
|
||||||
{
|
|
||||||
"text": "If installed, access phpMyAdmin at `http://<LXC_IP>/phpMyAdmin`, case sensitive.",
|
|
||||||
"type": "info"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -13,51 +13,28 @@ setting_up_container
|
||||||
network_check
|
network_check
|
||||||
update_os
|
update_os
|
||||||
|
|
||||||
msg_info "Detecting Distro"
|
|
||||||
DISTRO_OS=$(awk -F= '/^ID=/{print $2}' /etc/os-release)
|
|
||||||
DISTRO_VER=$(awk -F= '/^VERSION_ID=/{print $2}' /etc/os-release | tr -d '"')
|
|
||||||
|
|
||||||
case "$DISTRO_OS" in
|
|
||||||
debian)
|
|
||||||
if [[ "$DISTRO_VER" == "12" ]]; then
|
|
||||||
DISTRO_VER="11"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
ubuntu)
|
|
||||||
if [[ "$DISTRO_VER" == "22.04" ]]; then
|
|
||||||
DISTRO_VER="20.04"
|
|
||||||
NEEDS_LIBSSL1_1=true
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
msg_ok "Detected $DISTRO_OS $DISTRO_VER"
|
|
||||||
|
|
||||||
msg_info "Installing Dependencies"
|
msg_info "Installing Dependencies"
|
||||||
if [[ "${NEEDS_LIBSSL1_1:-false}" == "true" ]]; then
|
temp_file=$(mktemp)
|
||||||
echo "deb http://security.ubuntu.com/ubuntu focal-security main" >/etc/apt/sources.list.d/focal-security.list
|
curl -fsSL "http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_amd64.deb" -o "$temp_file"
|
||||||
$STD apt update
|
$STD dpkg -i $temp_file
|
||||||
$STD apt install -y libssl1.1
|
|
||||||
rm -f /etc/apt/sources.list.d/focal-security.list
|
|
||||||
fi
|
|
||||||
msg_ok "Installed Dependencies"
|
msg_ok "Installed Dependencies"
|
||||||
|
|
||||||
msg_info "Setting up InvenTree Repository"
|
msg_info "Setting up InvenTree Repository"
|
||||||
mkdir -p /etc/apt/keyrings
|
mkdir -p /etc/apt/keyrings
|
||||||
curl -fsSL https://dl.packager.io/srv/inventree/InvenTree/key | gpg --dearmor -o /etc/apt/keyrings/inventree.gpg
|
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/${DISTRO_OS} ${DISTRO_VER} main" \
|
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
|
||||||
>/etc/apt/sources.list.d/inventree.list
|
|
||||||
$STD apt update
|
|
||||||
msg_ok "Set up InvenTree Repository"
|
msg_ok "Set up InvenTree Repository"
|
||||||
|
|
||||||
msg_info "Installing InvenTree"
|
msg_info "Setup ${APPLICATION} (Patience)"
|
||||||
$STD apt install -y inventree || msg_error "Failed to install InvenTree"
|
$STD apt-get update
|
||||||
msg_ok "Installed InvenTree"
|
$STD apt-get install -y inventree
|
||||||
|
msg_ok "Setup ${APPLICATION}"
|
||||||
|
|
||||||
motd_ssh
|
motd_ssh
|
||||||
customize
|
customize
|
||||||
|
|
||||||
msg_info "Cleaning up"
|
msg_info "Cleaning up"
|
||||||
$STD apt -y autoremove
|
rm -f $temp_file
|
||||||
$STD apt -y autoclean
|
$STD apt-get -y autoremove
|
||||||
$STD apt -y clean
|
$STD apt-get -y autoclean
|
||||||
msg_ok "Cleaned"
|
msg_ok "Cleaned"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user