mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-01-11 02:11:01 +01:00
Deprecated nobuild
This commit is contained in:
155
zzz_archived_papermerge/CHANGELOG.md
Normal file
155
zzz_archived_papermerge/CHANGELOG.md
Normal file
@@ -0,0 +1,155 @@
|
||||
- Feat : cifsdomain added
|
||||
|
||||
## v2.1.5-ls61 (19-02-2023)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
- WARNING : update to supervisor 2022.11 before installing
|
||||
|
||||
## v2.0.1-ls60 (26-08-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls59 (20-08-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls58 (06-08-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls57 (30-07-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls56 (23-07-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls55 (16-07-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls53 (09-07-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls52 (02-07-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls51 (25-06-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls50 (18-06-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls49 (11-06-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls48 (31-05-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls47 (21-05-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls46 (14-05-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls45 (06-05-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls44 (16-04-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls43 (09-04-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls42 (02-04-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls41 (25-03-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
- Add codenotary sign
|
||||
|
||||
## v2.0.1-ls40 (22-03-2022)
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
- OCR corrected
|
||||
- New feature : IMAP document import (@fkhofmann)
|
||||
- OCR configuration has been rewritten (@fkhofmann)
|
||||
- Import dir bug fix (@fkhofmann)
|
||||
- Allow custom config location
|
||||
- Config exposed in /config/addons_config/papermerge
|
||||
- New standardized logic for Dockerfile build and packages installation
|
||||
- OCR repaired
|
||||
- SMB : accepts several disks separated by commas mounted in /mnt/$sharename
|
||||
|
||||
## 2.0.1
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls36
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls35
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls34
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.1-ls33
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.0-ls32
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.0rc48-ls31
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.0rc48-ls30
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.0rc48-ls29
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.0rc45-ls29
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.0rc45-ls28
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.0rc43-ls28
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.0rc38-ls28
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
|
||||
## v2.0.0rc35-ls28
|
||||
|
||||
- Update to latest version from linuxserver/docker-papermerge
|
||||
- Enables PUID/PGID options
|
||||
- Enables english/french OCR
|
||||
- Enables mounting of local hdd or smb share
|
||||
123
zzz_archived_papermerge/Dockerfile
Normal file
123
zzz_archived_papermerge/Dockerfile
Normal file
@@ -0,0 +1,123 @@
|
||||
#============================#
|
||||
# ALEXBELGIUM'S DOCKERFILE #
|
||||
#============================#
|
||||
# _.------.
|
||||
# _.-` ('>.-`"""-.
|
||||
# '.--'` _'` _ .--.)
|
||||
# -' '-.-';` `
|
||||
# ' - _.' ``'--.
|
||||
# '---` .-'""`
|
||||
# /`
|
||||
#=== Home Assistant Addon ===#
|
||||
|
||||
#################
|
||||
# 1 Build Image #
|
||||
#################
|
||||
|
||||
ARG BUILD_FROM
|
||||
ARG BUILD_VERSION
|
||||
FROM ${BUILD_FROM}
|
||||
|
||||
##################
|
||||
# 2 Modify Image #
|
||||
##################
|
||||
|
||||
# Set S6 wait time
|
||||
ENV S6_CMD_WAIT_FOR_SERVICES=1 \
|
||||
S6_CMD_WAIT_FOR_SERVICES_MAXTIME=0 \
|
||||
S6_SERVICES_GRACETIME=0
|
||||
|
||||
|
||||
# Image specific
|
||||
RUN \
|
||||
# Change config path
|
||||
sed -i 's|papermerge/config|papermerge/confi|g' /etc/cont-init.d/* \
|
||||
&& sed -i 's|/config|/data/config|g' /etc/cont-init.d/* \
|
||||
&& sed -i 's|papermerge/confi|papermerge/config|g' /etc/cont-init.d/*
|
||||
|
||||
# Global LSIO modifications
|
||||
ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_lsio.sh" "/ha_lsio.sh"
|
||||
ARG CONFIGLOCATION="/config"
|
||||
RUN chmod 744 /ha_lsio.sh && if grep -qr "lsio" /etc; then /ha_lsio.sh "$CONFIGLOCATION"; fi && rm /ha_lsio.sh
|
||||
|
||||
##################
|
||||
# 3 Install apps #
|
||||
##################
|
||||
|
||||
# Add rootfs
|
||||
COPY rootfs/ /
|
||||
|
||||
# Uses /bin for compatibility purposes
|
||||
# hadolint ignore=DL4005
|
||||
RUN if [ ! -f /bin/sh ] && [ -f /usr/bin/sh ]; then ln -s /usr/bin/sh /bin/sh; fi && \
|
||||
if [ ! -f /bin/bash ] && [ -f /usr/bin/bash ]; then ln -s /usr/bin/bash /bin/bash; fi
|
||||
|
||||
# Modules
|
||||
ARG MODULES="00-banner.sh 01-custom_script.sh 00-smb_mounts.sh"
|
||||
|
||||
# Automatic modules download
|
||||
ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_automodules.sh" "/ha_automodules.sh"
|
||||
RUN chmod 744 /ha_automodules.sh && /ha_automodules.sh "$MODULES" && rm /ha_automodules.sh
|
||||
|
||||
# Manual apps
|
||||
ENV PACKAGES="jq \
|
||||
curl \
|
||||
cifs-utils \
|
||||
keyutils"
|
||||
|
||||
# Automatic apps & bashio
|
||||
ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_autoapps.sh" "/ha_autoapps.sh"
|
||||
RUN chmod 744 /ha_autoapps.sh && /ha_autoapps.sh "$PACKAGES" && rm /ha_autoapps.sh
|
||||
|
||||
################
|
||||
# 4 Entrypoint #
|
||||
################
|
||||
|
||||
# Add entrypoint
|
||||
ENV S6_STAGE2_HOOK=/ha_entrypoint.sh
|
||||
ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh"
|
||||
|
||||
# Entrypoint modifications
|
||||
ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint_modif.sh" "/ha_entrypoint_modif.sh"
|
||||
RUN chmod 777 /ha_entrypoint.sh /ha_entrypoint_modif.sh && /ha_entrypoint_modif.sh && rm /ha_entrypoint_modif.sh
|
||||
|
||||
#
|
||||
#WORKDIR /
|
||||
#ENTRYPOINT [ "/usr/bin/env" ]
|
||||
#CMD [ "/ha_entrypoint.sh" ]
|
||||
#SHELL ["/bin/bash", "-o", "pipefail", "-c"]
|
||||
|
||||
############
|
||||
# 5 Labels #
|
||||
############
|
||||
|
||||
ARG BUILD_ARCH
|
||||
ARG BUILD_DATE
|
||||
ARG BUILD_DESCRIPTION
|
||||
ARG BUILD_NAME
|
||||
ARG BUILD_REF
|
||||
ARG BUILD_REPOSITORY
|
||||
ARG BUILD_VERSION
|
||||
ENV BUILD_VERSION="${BUILD_VERSION}"
|
||||
LABEL \
|
||||
io.hass.name="${BUILD_NAME}" \
|
||||
io.hass.description="${BUILD_DESCRIPTION}" \
|
||||
io.hass.arch="${BUILD_ARCH}" \
|
||||
io.hass.type="addon" \
|
||||
io.hass.version=${BUILD_VERSION} \
|
||||
maintainer="alexbelgium (https://github.com/alexbelgium)" \
|
||||
org.opencontainers.image.title="${BUILD_NAME}" \
|
||||
org.opencontainers.image.description="${BUILD_DESCRIPTION}" \
|
||||
org.opencontainers.image.vendor="Home Assistant Add-ons" \
|
||||
org.opencontainers.image.authors="alexbelgium (https://github.com/alexbelgium)" \
|
||||
org.opencontainers.image.licenses="MIT" \
|
||||
org.opencontainers.image.url="https://github.com/alexbelgium" \
|
||||
org.opencontainers.image.source="https://github.com/${BUILD_REPOSITORY}" \
|
||||
org.opencontainers.image.documentation="https://github.com/${BUILD_REPOSITORY}/blob/main/README.md" \
|
||||
org.opencontainers.image.created=${BUILD_DATE} \
|
||||
org.opencontainers.image.revision=${BUILD_REF} \
|
||||
org.opencontainers.image.version=${BUILD_VERSION}
|
||||
|
||||
####################
|
||||
# 6 HealthcheckNOT #
|
||||
####################
|
||||
72
zzz_archived_papermerge/README.md
Normal file
72
zzz_archived_papermerge/README.md
Normal file
@@ -0,0 +1,72 @@
|
||||
## ⚠ Open Issue : [🐛 [Papermerge] Not installing with Home Assistant 2025.6 (opened 2025-06-08)](https://github.com/alexbelgium/hassio-addons/issues/1888) by [@dimitripb](https://github.com/dimitripb)
|
||||
|
||||
# Home assistant add-on: Papermerge
|
||||
|
||||
[![Donate][donation-badge]](https://www.buymeacoffee.com/alexbelgium)
|
||||
[![Donate][paypal-badge]](https://www.paypal.com/donate/?hosted_button_id=DZFULJZTP3UQA)
|
||||
|
||||

|
||||

|
||||

|
||||
|
||||
[](https://www.codacy.com/gh/alexbelgium/hassio-addons/dashboard?utm_source=github.com&utm_medium=referral&utm_content=alexbelgium/hassio-addons&utm_campaign=Badge_Grade)
|
||||
[](https://github.com/alexbelgium/hassio-addons/actions/workflows/weekly-supelinter.yaml)
|
||||
[](https://github.com/alexbelgium/hassio-addons/actions/workflows/onpush_builder.yaml)
|
||||
|
||||
[donation-badge]: https://img.shields.io/badge/Buy%20me%20a%20coffee%20(no%20paypal)-%23d32f2f?logo=buy-me-a-coffee&style=flat&logoColor=white
|
||||
[paypal-badge]: https://img.shields.io/badge/Buy%20me%20a%20coffee%20with%20Paypal-0070BA?logo=paypal&style=flat&logoColor=white
|
||||
|
||||
_Thanks to everyone having starred my repo! To star it click on the image below, then it will be on top right. Thanks!_
|
||||
|
||||
[](https://github.com/alexbelgium/hassio-addons/stargazers)
|
||||
|
||||

|
||||
|
||||
## About
|
||||
|
||||
Open source document management system (DMS)
|
||||
This addon is based on the [docker image](https://hub.docker.com/r/linuxserver/papermerge) from linuxserver.io.
|
||||
|
||||
## Installation
|
||||
|
||||
The installation of this add-on is pretty straightforward and not different in
|
||||
comparison to installing any other Hass.io add-on.
|
||||
|
||||
1. [Add my Hass.io add-ons repository][repository] to your Hass.io instance.
|
||||
1. Install this add-on.
|
||||
1. Click the `Save` button to store your configuration.
|
||||
1. Start the add-on.
|
||||
1. Check the logs of the add-on to see if everything went well.
|
||||
1. Carefully configure the add-on to your preferences, see the official documentation for for that.
|
||||
|
||||
## Configuration
|
||||
|
||||
Webui can be found at `<your-ip>:8000`.
|
||||
|
||||
Default name `admin` password `admin`
|
||||
|
||||
Options can be configured through two ways :
|
||||
|
||||
- Addon options
|
||||
|
||||
```yaml
|
||||
PGID: user
|
||||
GPID: user
|
||||
ocrlang: Any language can be set from this page (always three letters) [here](https://tesseract-ocr.github.io/tessdoc/Data-Files#data-files-for-version-400-november-29-2016).
|
||||
localdisks: sda1 #put the hardware name of your drive to mount separated by commas, or its label. ex. sda1, sdb1, MYNAS...
|
||||
networkdisks: "<//SERVER/SHARE>" # list of smbv2/3 servers to mount (optional)
|
||||
cifsusername: "username" # smb username (optional)
|
||||
cifspassword: "password" # smb password (optional)
|
||||
storage_dir: storage dir location (https://papermerge.readthedocs.io/en/v2.0.1/consumption.html)
|
||||
import_dir: import dir location (https://papermerge.readthedocs.io/en/v2.0.1/consumption.html)
|
||||
imaphost: import from email (https://papermerge.readthedocs.io/en/v2.0.1/consumption.html#imap-email)
|
||||
imapusername: import from email (https://papermerge.readthedocs.io/en/v2.0.1/consumption.html#imap-email)
|
||||
imappassword: import from email (https://papermerge.readthedocs.io/en/v2.0.1/consumption.html#imap-email)
|
||||
CONFIG_LOCATION: location of the papermerge.conf.py (see below)
|
||||
```
|
||||
|
||||
- papermerge.conf.py
|
||||
Custom env variables can be added to the /config/addons_config/papermerge/papermerge.conf.py.
|
||||
Full variables can be found here : https://papermerge.readthedocs.io/en/v2.0.1/settings.html.
|
||||
|
||||
[repository]: https://github.com/alexbelgium/hassio-addons
|
||||
66
zzz_archived_papermerge/apparmor.txt
Normal file
66
zzz_archived_papermerge/apparmor.txt
Normal file
@@ -0,0 +1,66 @@
|
||||
#include <tunables/global>
|
||||
|
||||
profile papermerge_addon flags=(attach_disconnected,mediate_deleted) {
|
||||
#include <abstractions/base>
|
||||
|
||||
capability,
|
||||
file,
|
||||
signal,
|
||||
mount,
|
||||
umount,
|
||||
remount,
|
||||
network udp,
|
||||
network tcp,
|
||||
network dgram,
|
||||
network stream,
|
||||
network inet,
|
||||
network inet6,
|
||||
network netlink raw,
|
||||
network unix dgram,
|
||||
|
||||
capability setgid,
|
||||
capability setuid,
|
||||
capability sys_admin,
|
||||
capability dac_read_search,
|
||||
# capability dac_override,
|
||||
# capability sys_rawio,
|
||||
|
||||
# S6-Overlay
|
||||
/init ix,
|
||||
/run/{s6,s6-rc*,service}/** ix,
|
||||
/package/** ix,
|
||||
/command/** ix,
|
||||
/run/{,**} rwk,
|
||||
/dev/tty rw,
|
||||
/bin/** ix,
|
||||
/usr/bin/** ix,
|
||||
/usr/lib/bashio/** ix,
|
||||
/etc/s6/** rix,
|
||||
/run/s6/** rix,
|
||||
/etc/services.d/** rwix,
|
||||
/etc/cont-init.d/** rwix,
|
||||
/etc/cont-finish.d/** rwix,
|
||||
/init rix,
|
||||
/var/run/** mrwkl,
|
||||
/var/run/ mrwkl,
|
||||
/dev/i2c-1 mrwkl,
|
||||
# Files required
|
||||
/dev/fuse mrwkl,
|
||||
/dev/sda1 mrwkl,
|
||||
/dev/sdb1 mrwkl,
|
||||
/dev/nvme0 mrwkl,
|
||||
/dev/nvme1 mrwkl,
|
||||
/dev/mmcblk0p1 mrwkl,
|
||||
/dev/* mrwkl,
|
||||
/tmp/** mrkwl,
|
||||
|
||||
# Data access
|
||||
/data/** rw,
|
||||
|
||||
# suppress ptrace denials when using 'docker ps' or using 'ps' inside a container
|
||||
ptrace (trace,read) peer=docker-default,
|
||||
|
||||
# docker daemon confinement requires explict allow rule for signal
|
||||
signal (receive) set=(kill,term) peer=/usr/bin/docker,
|
||||
|
||||
}
|
||||
10
zzz_archived_papermerge/build.json
Normal file
10
zzz_archived_papermerge/build.json
Normal file
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"build_from": {
|
||||
"aarch64": "lscr.io/linuxserver/papermerge:arm64v8-latest",
|
||||
"amd64": "lscr.io/linuxserver/papermerge:amd64-latest",
|
||||
"armv7": "lscr.io/linuxserver/papermerge:arm32v7-latest"
|
||||
},
|
||||
"codenotary": {
|
||||
"signer": "alexandrep.github@gmail.com"
|
||||
}
|
||||
}
|
||||
122
zzz_archived_papermerge/config.json
Normal file
122
zzz_archived_papermerge/config.json
Normal file
@@ -0,0 +1,122 @@
|
||||
{
|
||||
"arch": [
|
||||
"aarch64",
|
||||
"amd64",
|
||||
"armv7"
|
||||
],
|
||||
"codenotary": "alexandrep.github@gmail.com",
|
||||
"description": "Open source document management system (DMS)",
|
||||
"devices": [
|
||||
"/dev/dri",
|
||||
"/dev/dri/card0",
|
||||
"/dev/dri/card1",
|
||||
"/dev/dri/renderD128",
|
||||
"/dev/vchiq",
|
||||
"/dev/video10",
|
||||
"/dev/video11",
|
||||
"/dev/video12",
|
||||
"/dev/video13",
|
||||
"/dev/video14",
|
||||
"/dev/video15",
|
||||
"/dev/video16",
|
||||
"/dev/ttyUSB0",
|
||||
"/dev/sda",
|
||||
"/dev/sdb",
|
||||
"/dev/sdc",
|
||||
"/dev/sdd",
|
||||
"/dev/sde",
|
||||
"/dev/sdf",
|
||||
"/dev/sdg",
|
||||
"/dev/nvme",
|
||||
"/dev/nvme0",
|
||||
"/dev/nvme0n1",
|
||||
"/dev/nvme0n1p1",
|
||||
"/dev/nvme0n1p2",
|
||||
"/dev/nvme0n1p3",
|
||||
"/dev/nvme1n1",
|
||||
"/dev/nvme1n1p1",
|
||||
"/dev/nvme1n1p2",
|
||||
"/dev/nvme1n1p3",
|
||||
"/dev/nvme2n1",
|
||||
"/dev/nvme2n1p1",
|
||||
"/dev/nvme2n1p2",
|
||||
"/dev/nvme2n3p3",
|
||||
"/dev/mmcblk",
|
||||
"/dev/fuse",
|
||||
"/dev/sda1",
|
||||
"/dev/sdb1",
|
||||
"/dev/sdc1",
|
||||
"/dev/sdd1",
|
||||
"/dev/sde1",
|
||||
"/dev/sdf1",
|
||||
"/dev/sdg1",
|
||||
"/dev/sda2",
|
||||
"/dev/sdb2",
|
||||
"/dev/sdc2",
|
||||
"/dev/sdd2",
|
||||
"/dev/sde2",
|
||||
"/dev/sdf2",
|
||||
"/dev/sdg2",
|
||||
"/dev/sda3",
|
||||
"/dev/sdb3",
|
||||
"/dev/sda4",
|
||||
"/dev/sdb4",
|
||||
"/dev/sda5",
|
||||
"/dev/sda6",
|
||||
"/dev/sda7",
|
||||
"/dev/sda8",
|
||||
"/dev/nvme0",
|
||||
"/dev/nvme1",
|
||||
"/dev/nvme2"
|
||||
],
|
||||
"image": "ghcr.io/alexbelgium/papermerge-{arch}",
|
||||
"init": false,
|
||||
"map": [
|
||||
"share:rw",
|
||||
"media:rw",
|
||||
"ssl",
|
||||
"config:rw"
|
||||
],
|
||||
"name": "zzz_archived - Papermerge",
|
||||
"options": {
|
||||
"CONFIG_LOCATION": "/config/addons_config/papermerge",
|
||||
"PGID": 0,
|
||||
"PUID": 0,
|
||||
"import_dir": "/share/papermerge/import",
|
||||
"ocrlang": "eng,fra",
|
||||
"storage_dir": "/data/media"
|
||||
},
|
||||
"ports": {
|
||||
"8000/tcp": 8000
|
||||
},
|
||||
"ports_description": {
|
||||
"8000/tcp": "Web UI port (required)"
|
||||
},
|
||||
"privileged": [
|
||||
"SYS_ADMIN",
|
||||
"DAC_READ_SEARCH"
|
||||
],
|
||||
"schema": {
|
||||
"CONFIG_LOCATION": "str",
|
||||
"PGID": "int",
|
||||
"PUID": "int",
|
||||
"TZ": "str?",
|
||||
"cifsdomain": "str?",
|
||||
"cifspassword": "str?",
|
||||
"cifsusername": "str?",
|
||||
"imaphost": "str?",
|
||||
"imappassword": "str?",
|
||||
"imapusername": "str?",
|
||||
"import_dir": "str",
|
||||
"networkdisks": "str?",
|
||||
"ocrlang": "str",
|
||||
"smbv1": "bool?",
|
||||
"storage_dir": "str"
|
||||
},
|
||||
"slug": "papermerge",
|
||||
"stage": "deprecated",
|
||||
"udev": true,
|
||||
"url": "https://github.com/alexbelgium/hassio-addons",
|
||||
"version": "v2.0.1-ls60-bugfix",
|
||||
"webui": "[PROTO:ssl]://[HOST]:[PORT:8000]"
|
||||
}
|
||||
BIN
zzz_archived_papermerge/icon.png
Normal file
BIN
zzz_archived_papermerge/icon.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 4.5 KiB |
BIN
zzz_archived_papermerge/logo.png
Normal file
BIN
zzz_archived_papermerge/logo.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 4.5 KiB |
@@ -0,0 +1,15 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
set -e
|
||||
|
||||
# ==============================================================================
|
||||
# Displays a simple add-on banner on startup
|
||||
# ==============================================================================
|
||||
|
||||
echo ""
|
||||
bashio::log.yellow "####################"
|
||||
bashio::log.yellow "# ADDON deprecated #"
|
||||
bashio::log.yellow "####################"
|
||||
echo ""
|
||||
|
||||
sleep 5
|
||||
15
zzz_archived_papermerge/rootfs/etc/cont-init.d/00-folders.sh
Normal file
15
zzz_archived_papermerge/rootfs/etc/cont-init.d/00-folders.sh
Normal file
@@ -0,0 +1,15 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
set -e
|
||||
|
||||
# Config location
|
||||
CONFIGLOCATION="$(bashio::config 'CONFIG_LOCATION')"
|
||||
|
||||
# Text
|
||||
bashio::log.info "Setting config location to $CONFIGLOCATION"
|
||||
|
||||
# Adapt files
|
||||
sed -i "s|/data/config|$CONFIGLOCATION|g" /etc/cont-init.d/*
|
||||
|
||||
# Avoid tamper issues
|
||||
chown -R root:root "$CONFIGLOCATION"/custom*
|
||||
59
zzz_archived_papermerge/rootfs/etc/cont-init.d/91-OCR.sh
Normal file
59
zzz_archived_papermerge/rootfs/etc/cont-init.d/91-OCR.sh
Normal file
@@ -0,0 +1,59 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
set -e
|
||||
|
||||
# Allow OCR setting
|
||||
OCRLANG="$(bashio::config "ocrlang")"
|
||||
|
||||
#Define location place
|
||||
CONFIGLOCATION="$(bashio::config "CONFIG_LOCATION")"
|
||||
#If it's a file, get the folder
|
||||
if [ ! -d "$CONFIGLOCATION" ]; then
|
||||
CONFIGLOCATION="$(dirname "$CONFIGLOCATION")"
|
||||
fi
|
||||
|
||||
#Correct previous bug
|
||||
sed -i "s|OCRLANG|OCR_LANGUAGES|g" "$CONFIGLOCATION"/papermerge.conf.py
|
||||
|
||||
languageCount=$(echo "$OCRLANG" | tr -cd ',' | wc -c)
|
||||
languageCount=$((languageCount + 1))
|
||||
bashio::log.info "Configuring ${languageCount} languages"
|
||||
|
||||
if [ -n "$OCRLANG" ]; then
|
||||
lineStart=$(sed -n '/OCR_LANGUAGES/=' "$CONFIGLOCATION"/papermerge.conf.py)
|
||||
bashio::log.info "OCRLANG variable is set, processing the language packages"
|
||||
lineEnd=$(sed -n '/}/=' "$CONFIGLOCATION"/papermerge.conf.py)
|
||||
sed -i "${lineStart},${lineEnd}d" "$CONFIGLOCATION"/papermerge.conf.py || true
|
||||
|
||||
bashio::log.info "Writing new configuration"
|
||||
echo "OCR_LANGUAGES = {" >>"$CONFIGLOCATION"/papermerge.conf.py
|
||||
|
||||
languages=$(echo "$OCRLANG" | tr "," "\n")
|
||||
|
||||
apt-get update >/dev/null
|
||||
|
||||
i=0
|
||||
for language in $languages; do
|
||||
bashio::log.info "Processing language ${language}"
|
||||
if apt-cache show tesseract-ocr-"${language}" >/dev/null 2>&1; then
|
||||
bashio::log.info "Installing tesseract-ocr-${language}"
|
||||
apt-get install -yqq tesseract-ocr-"${language}" >/dev/null
|
||||
languageFullName=$(apt-cache show tesseract-ocr-"${language}" | grep -E '^(Description|Description-en):' | grep -oE '[^ ]+$')
|
||||
bashio::log.info "${language} identified as ${languageFullName}"
|
||||
i=$((i + 1))
|
||||
if [[ $i -eq $languageCount ]]; then
|
||||
echo " \"$language\" : \"$languageFullName\"" >>"$CONFIGLOCATION"/papermerge.conf.py
|
||||
elif [[ $i -eq 1 ]]; then
|
||||
echo " \"$language\" : \"$languageFullName\"," >>"$CONFIGLOCATION"/papermerge.conf.py
|
||||
bashio::log.info "Setting default language to ${language}"
|
||||
sed -i "s/^OCR_DEFAULT_LANGUAGE = \"eng\"/OCR_DEFAULT_LANGUAGE = \"${language}\"/g" "$CONFIGLOCATION"/papermerge.conf.py
|
||||
else
|
||||
echo " \"$language\" : \"$languageFullName\"," >>"$CONFIGLOCATION"/papermerge.conf.py
|
||||
fi
|
||||
bashio::log.info "... ${language} installed"
|
||||
else
|
||||
bashio::log.info "Package tesseract-ocr-${language} not found in the repository, skipping"
|
||||
fi
|
||||
done
|
||||
echo "}" >>"$CONFIGLOCATION"/papermerge.conf.py
|
||||
fi
|
||||
@@ -0,0 +1,74 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
set -e
|
||||
|
||||
##################
|
||||
# SELECT FOLDERS #
|
||||
##################
|
||||
|
||||
#Set media dir
|
||||
MEDIADIR=$(bashio::config 'storage_dir')
|
||||
#clean data
|
||||
sed -i '/MEDIA_DIR/d' /data/config/papermerge.conf.py
|
||||
#add data
|
||||
sed -i "2 i\MEDIA_DIR = \"$MEDIADIR\"" /data/config/papermerge.conf.py
|
||||
bashio::log.info "Storage dir set to $MEDIADIR"
|
||||
|
||||
#Set import dir
|
||||
IMPORTDIR=$(bashio::config 'import_dir')
|
||||
#clean data
|
||||
sed -i '/IMPORTER_DIR/d' /data/config/papermerge.conf.py || true
|
||||
#add data
|
||||
sed -i "2 i\IMPORTER_DIR = \"$IMPORTDIR\"" /data/config/papermerge.conf.py
|
||||
bashio::log.info "Import dir set to $IMPORTDIR"
|
||||
|
||||
##################
|
||||
# CREATE FOLDERS #
|
||||
##################
|
||||
|
||||
#if [ ! -d /data/config ]; then
|
||||
# echo "Creating /config"
|
||||
# mkdir -p /config
|
||||
#fi
|
||||
#chown -R "$PUID:$PGID" /config
|
||||
|
||||
if [ ! -d "$MEDIADIR" ]; then
|
||||
echo "Creating $MEDIADIR"
|
||||
mkdir -p "$MEDIADIR"
|
||||
fi
|
||||
chown -R "$PUID:$PGID" "$MEDIADIR"
|
||||
|
||||
if [ ! -d "$IMPORTDIR" ]; then
|
||||
echo "Creating $IMPORTDIR"
|
||||
mkdir -p "$IMPORTDIR"
|
||||
fi
|
||||
chown -R "$PUID:$PGID" "$IMPORTDIR"
|
||||
|
||||
##################
|
||||
# CONFIGURE IMAP #
|
||||
##################
|
||||
|
||||
IMAPHOST=$(bashio::config 'imaphost')
|
||||
IMAPUSERNAME=$(bashio::config 'imapusername')
|
||||
IMAPPASSWORD=$(bashio::config 'imappassword')
|
||||
|
||||
if [ "$IMAPHOST" != "null" ]; then
|
||||
printf "\nIMPORT_MAIL_HOST = \"%s\"" "$IMAPHOST" >>/data/config/papermerge.conf.py
|
||||
bashio::log.info "IMPORT_MAIL_HOST set to $IMAPHOST"
|
||||
|
||||
if [ "$IMAPUSERNAME" != "null" ]; then
|
||||
printf "\nIMPORT_MAIL_USER = \"%s\"" "$IMAPUSERNAME" >>/data/config/papermerge.conf.py
|
||||
bashio::log.info "IMPORT_MAIL_USER set to $IMAPUSERNAME"
|
||||
else
|
||||
bashio::log.info "! IMAPHOST has been set, but no IMAPUSERNAME. Please check your configuration!"
|
||||
fi
|
||||
|
||||
if [ "$IMAPPASSWORD" != "null" ]; then
|
||||
printf "\nIMPORT_MAIL_PASS = \"%s\"" "$IMAPPASSWORD" >>/data/config/papermerge.conf.py
|
||||
IMAPPASSWORDMASKED=$(echo "$IMAPPASSWORD" | sed -r 's/./x/g')
|
||||
bashio::log.info "IMPORT_MAIL_PASS set to $IMAPPASSWORDMASKED"
|
||||
else
|
||||
bashio::log.info "! IMAPHOST has been set, but no IMAPPASSWORD. Please check your configuration!"
|
||||
fi
|
||||
|
||||
fi
|
||||
BIN
zzz_archived_papermerge/stats.png
Normal file
BIN
zzz_archived_papermerge/stats.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.1 KiB |
9
zzz_archived_papermerge/updater.json
Normal file
9
zzz_archived_papermerge/updater.json
Normal file
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"github_fulltag": "true",
|
||||
"last_update": "19-02-2023",
|
||||
"repository": "alexbelgium/hassio-addons",
|
||||
"slug": "papermerge",
|
||||
"source": "github",
|
||||
"upstream_repo": "linuxserver/docker-papermerge",
|
||||
"upstream_version": "v2.1.5-ls61"
|
||||
}
|
||||
Reference in New Issue
Block a user