lotus/scripts/curio-apt/DEBIAN/postinst
Andrew Jackson (Ajax) f5dd7665f6
Produce DEB files for amd64 for openCL and cuda (#11885)
* service changes

* better postinst

* better postinst

* fix: curio: Update pgx imports, fix db_storage alloc

* feat: curioweb: Improve task_history indexes (#11911)

* ready to test deb making

* deb files build

* it works

* fullname

* last bit of cleanup

* doc update

* future plans

* lint

* code comments

---------

Co-authored-by: Łukasz Magiera <magik6k@gmail.com>
Co-authored-by: Łukasz Magiera <magik6k@users.noreply.github.com>
2024-05-13 14:18:50 -05:00

24 lines
768 B
Bash
Executable File

#!/bin/sh
set -e
case "$1" in
configure)
# Reload systemd after installation or upgrade
systemctl daemon-reload
if [ -z "$2" ]; then
# This is an initial installation
systemctl enable curio.service
if [ ! -f "/etc/curio.env" ]; then
echo "CURIO_LAYERS=gui,post\nCURIO_ALL_REMAINING_FIELDS_ARE_OPTIONAL=true\nCURIO_DB_HOST=yugabyte\nCURIO_DB_USER=yugabyte\nCURIO_DB_PASSWORD=yugabyte\nCURIO_DB_PORT=5433\nCURIO_DB_NAME=yugabyte\nCURIO_REPO_PATH=~/.curio" >/etc/curio.env
echo "setup /etc/curio.env then run: systemctl start curio.service"
fi
else
# This is an upgrade
systemctl restart curio.service
fi
;;
esac
exit 0