mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-06-07 16:15:55 +02:00
Switch to 1.8.2
This commit is contained in:
27
paperless_ngx/rootfs/entrypoint.sh
Normal file
27
paperless_ngx/rootfs/entrypoint.sh
Normal file
@@ -0,0 +1,27 @@
|
||||
#!/bin/bash
|
||||
echo "Starting..."
|
||||
|
||||
############################
|
||||
# Backup Dockerfile Script #
|
||||
############################
|
||||
|
||||
if [ -f /etc/cont-init.d/00-aaa_dockerfile_backup.sh ]; then
|
||||
chown "$(id -u)":"$(id -g)" /etc/cont-init.d/00-aaa_dockerfile_backup.sh
|
||||
chmod +x /etc/cont-init.d/00-aaa_dockerfile_backup.sh
|
||||
/./etc/cont-init.d/00-aaa_dockerfile_backup.sh
|
||||
rm /etc/cont-init.d/00-aaa_dockerfile_backup.sh
|
||||
fi
|
||||
|
||||
####################
|
||||
# Starting scripts #
|
||||
####################
|
||||
|
||||
for SCRIPTS in /etc/cont-init.d/*; do
|
||||
[ -e "$SCRIPTS" ] || continue
|
||||
echo "$SCRIPTS: executing"
|
||||
chown "$(id -u)":"$(id -g)" "$SCRIPTS"
|
||||
chmod a+x "$SCRIPTS"
|
||||
# Change shebang if no s6 supervision
|
||||
sed -i 's|/usr/bin/with-contenv bashio|/usr/bin/env bashio|g' "$SCRIPTS"
|
||||
/."$SCRIPTS" || echo "$SCRIPTS: exiting $?"
|
||||
done
|
||||
@@ -4,16 +4,8 @@
|
||||
slug=paperless_ng
|
||||
|
||||
if [ ! -d /config/addons_config/$slug ]; then
|
||||
|
||||
if [ -d /config/$slug ]; then
|
||||
echo "Moving to new location /config/addons_config/$slug"
|
||||
mkdir -p /config/addons_config/$slug
|
||||
chmod 777 /config/addons_config/$slug
|
||||
mv /config/$slug/* /config/addons_config/$slug/
|
||||
rm -r /config/$slug
|
||||
fi
|
||||
|
||||
echo "Creating /config/addons_config/$slug"
|
||||
mkdir -p /config/addons_config/$slug
|
||||
chmod 777 /config/addons_config/$slug
|
||||
fi
|
||||
|
||||
chmod 777 /config/addons_config/$slug
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
|
||||
echo "Installing pikepdf..."
|
||||
(
|
||||
export DEBIAN_FRONTEND="noninteractive"
|
||||
export TERM="xterm-256color"
|
||||
apt-get update
|
||||
apt-get install -yq libxml2-dev libxslt-dev python-dev
|
||||
apt-get install -yq libjpeg-dev zlib1g-dev
|
||||
apt-get install -yq python3-dev build-essential
|
||||
pip install pikepdf --force-reinstall
|
||||
) >/dev/null
|
||||
echo "... success!"
|
||||
@@ -1,16 +0,0 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
|
||||
OCRLANG=$(bashio::config 'OCRLANG')
|
||||
if [ -n "$OCRLANG" ]; then
|
||||
apt-get update &>/dev/null
|
||||
echo "OCRLANG variable is set, processing the language packages"
|
||||
for i in ${OCRLANG//,/ }; do
|
||||
if apt-cache show tesseract-ocr-"${i}" >/dev/null 2>&1; then
|
||||
apt-get install -yq tesseract-ocr-"${i}"
|
||||
bashio::log.info "OCR Language installed : $i" || bashio::log.fatal "Couldn't install OCR lang $i. Please check its format is conform"
|
||||
else
|
||||
echo "package tesseract-ocr-${i} not found in the repository, skipping"
|
||||
fi
|
||||
done
|
||||
fi
|
||||
@@ -1,4 +1,11 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
|
||||
# Staring redis
|
||||
exec redis-server & bashio::log.info "Starting redis"
|
||||
|
||||
# Avoid overcommit memory
|
||||
bashio::log.info "Avoid overcommit memory"
|
||||
sysctl vm.overcommit_memory=1
|
||||
|
||||
bashio::log.info "Initial username and password are admin. Please change in the administration panel of the webUI after login."
|
||||
|
||||
Reference in New Issue
Block a user