This commit is contained in:
Slaviša Arežina 2025-08-18 19:58:50 +02:00 committed by GitHub
parent a79392149e
commit aed25098e5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 47 additions and 50 deletions

View File

@ -32,11 +32,12 @@ function update_script() {
systemctl stop umami systemctl stop umami
msg_ok "Stopped $APP" msg_ok "Stopped $APP"
fetch_and_deploy_gh_release "umami" "umami-software/umami" "tarball"
msg_info "Updating ${APP}" msg_info "Updating ${APP}"
cd /opt/umami cd /opt/umami
git pull $STD yarn install
yarn install $STD yarn run build
yarn build
msg_ok "Updated ${APP}" msg_ok "Updated ${APP}"
msg_info "Starting ${APP}" msg_info "Starting ${APP}"

View File

@ -6,10 +6,10 @@
], ],
"date_created": "2024-05-09", "date_created": "2024-05-09",
"type": "ct", "type": "ct",
"updateable": false, "updateable": true,
"privileged": false, "privileged": false,
"interface_port": 3000, "interface_port": 3000,
"documentation": null, "documentation": "https://umami.is/docs",
"website": "https://umami.is/", "website": "https://umami.is/",
"logo": "https://cdn.jsdelivr.net/gh/selfhst/icons/webp/umami.webp", "logo": "https://cdn.jsdelivr.net/gh/selfhst/icons/webp/umami.webp",
"config_path": "/opt/umami/.env", "config_path": "/opt/umami/.env",

View File

@ -13,12 +13,9 @@ setting_up_container
network_check network_check
update_os update_os
msg_info "Installing Dependencies"
$STD apt-get install -y git
msg_ok "Installed Dependencies"
NODE_VERSION="22" NODE_MODULE="yarn@latest" setup_nodejs NODE_VERSION="22" NODE_MODULE="yarn@latest" setup_nodejs
PG_VERSION="16" setup_postgresql PG_VERSION="16" setup_postgresql
fetch_and_deploy_gh_release "umami" "umami-software/umami" "tarball"
msg_info "Setting up postgresql" msg_info "Setting up postgresql"
DB_NAME=umamidb DB_NAME=umamidb
@ -39,17 +36,16 @@ $STD sudo -u postgres psql -c "ALTER ROLE $DB_USER SET timezone TO 'UTC'"
} >>~/umami.creds } >>~/umami.creds
msg_ok "Set up postgresql" msg_ok "Set up postgresql"
msg_info "Installing Umami (Patience)" msg_info "Configuring Umami"
git clone -q https://github.com/umami-software/umami.git /opt/umami
cd /opt/umami cd /opt/umami
$STD yarn install $STD yarn install
echo -e "DATABASE_URL=postgresql://$DB_USER:$DB_PASS@localhost:5432/$DB_NAME" >>/opt/umami/.env echo -e "DATABASE_URL=postgresql://$DB_USER:$DB_PASS@localhost:5432/$DB_NAME" >>/opt/umami/.env
$STD yarn run build $STD yarn run build
msg_ok "Installed Umami" msg_ok "Configured Umami"
msg_info "Creating Service" msg_info "Creating Service"
cat <<EOF >/etc/systemd/system/umami.service cat <<EOF >/etc/systemd/system/umami.service
echo "[Unit] [Unit]
Description=umami Description=umami
[Service] [Service]