#!/usr/bin/sh
#----------------------------------------------------------------------------
# /tmp/install.sh - ktls-utils installation
#
# Creation   :  2026-01-22 holbru
# Last update:  $Id$
#
# Copyright (c) 2026-@@YEAR@@ Holger Bruenjes, holgerbruenjes(at)gmx(dot)net
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#----------------------------------------------------------------------------

# set package name
package_name=ktls-utils

# ---------------------------------------------------------------------------
# add menu
# ---------------------------------------------------------------------------
/var/install/bin/add-menu      \
            setup.services.menu    \
            setup.services.${package_name}.menu \
            "Ktls-utils Service"

# ---------------------------------------------------------------------------
# Create default config
# ---------------------------------------------------------------------------
if [ -f "/etc/config.d/${package_name}" ]
then
    update=true
fi

/var/install/config.d/${package_name}-update.sh
/usr/bin/rm -f /var/install/config.d/${package_name}-update.sh

# ---------------------------------------------------------------------------
# start package with update
# ---------------------------------------------------------------------------
if ${update:-false}
then
    /var/install/config.d/${package_name}.sh --quiet
fi

exit 0
# ---------------------------------------------------------------------------
# end
# ---------------------------------------------------------------------------
