From 6c7281ae889976c1b33b87231c4bbeda36d88796 Mon Sep 17 00:00:00 2001 From: jonaswinkler Date: Sun, 10 Jan 2021 01:35:56 +0100 Subject: [PATCH 1/3] add sslmode configuration option fixes #298 --- docs/configuration.rst | 6 ++++++ paperless.conf.example | 1 + src/paperless/settings.py | 1 + 3 files changed, 8 insertions(+) diff --git a/docs/configuration.rst b/docs/configuration.rst index d122216a1..4828c4fa5 100644 --- a/docs/configuration.rst +++ b/docs/configuration.rst @@ -53,6 +53,12 @@ PAPERLESS_DBPASS= Defaults to "paperless". +PAPERLESS_DBSSLMODE= + SSL mode to use when connecting to PostgreSQL. + + See `the official documentation about sslmode `_. + + Default is ``prefer``. Paths and folders ################# diff --git a/paperless.conf.example b/paperless.conf.example index 50d79c720..7e6185765 100644 --- a/paperless.conf.example +++ b/paperless.conf.example @@ -13,6 +13,7 @@ #PAPERLESS_DBNAME=paperless #PAPERLESS_DBUSER=paperless #PAPERLESS_DBPASS=paperless +#PAPERLESS_DBSSLMODE=prefer # Paths and folders diff --git a/src/paperless/settings.py b/src/paperless/settings.py index d0e32b4a0..f2f1a45b1 100644 --- a/src/paperless/settings.py +++ b/src/paperless/settings.py @@ -253,6 +253,7 @@ if os.getenv("PAPERLESS_DBHOST"): "NAME": os.getenv("PAPERLESS_DBNAME", "paperless"), "USER": os.getenv("PAPERLESS_DBUSER", "paperless"), "PASSWORD": os.getenv("PAPERLESS_DBPASS", "paperless"), + 'OPTIONS': {'sslmode': os.getenv("PAPERLESS_DBSSLMODE", "prefer")}, } if os.getenv("PAPERLESS_DBPORT"): DATABASES["default"]["PORT"] = os.getenv("PAPERLESS_DBPORT") From 2c065da98758e01bdc926d3ce61aa9c400a118e1 Mon Sep 17 00:00:00 2001 From: jonaswinkler Date: Sun, 10 Jan 2021 01:59:47 +0100 Subject: [PATCH 2/3] fixes #292 --- .../app/components/common/input/select/select.component.html | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src-ui/src/app/components/common/input/select/select.component.html b/src-ui/src/app/components/common/input/select/select.component.html index 780dc5686..aa500d0d1 100644 --- a/src-ui/src/app/components/common/input/select/select.component.html +++ b/src-ui/src/app/components/common/input/select/select.component.html @@ -6,9 +6,11 @@ [style.color]="textColor" [style.background]="backgroundColor" [clearable]="allowNull" + [items]="items" + bindLabel="name" + bindValue="id" (change)="onChange(value)" (blur)="onTouched()"> - {{i.name}}
From 4cf0ce1b06542a1d98366f2924a2e4bb60ac21ac Mon Sep 17 00:00:00 2001 From: jonaswinkler Date: Sun, 10 Jan 2021 19:26:38 +0100 Subject: [PATCH 3/3] version push --- docker/hub/docker-compose.postgres.yml | 2 +- docker/hub/docker-compose.sqlite.yml | 2 +- docker/hub/docker-compose.tika.yml | 2 +- src-ui/src/environments/environment.prod.ts | 2 +- src/paperless/version.py | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/docker/hub/docker-compose.postgres.yml b/docker/hub/docker-compose.postgres.yml index dc32a5d84..215199d1f 100644 --- a/docker/hub/docker-compose.postgres.yml +++ b/docker/hub/docker-compose.postgres.yml @@ -15,7 +15,7 @@ services: POSTGRES_PASSWORD: paperless webserver: - image: jonaswinkler/paperless-ng:0.9.13 + image: jonaswinkler/paperless-ng:0.9.14 restart: always depends_on: - db diff --git a/docker/hub/docker-compose.sqlite.yml b/docker/hub/docker-compose.sqlite.yml index ffb8a0560..c1904f81a 100644 --- a/docker/hub/docker-compose.sqlite.yml +++ b/docker/hub/docker-compose.sqlite.yml @@ -5,7 +5,7 @@ services: restart: always webserver: - image: jonaswinkler/paperless-ng:0.9.13 + image: jonaswinkler/paperless-ng:0.9.14 restart: always depends_on: - broker diff --git a/docker/hub/docker-compose.tika.yml b/docker/hub/docker-compose.tika.yml index a303ba206..b78ca95dc 100644 --- a/docker/hub/docker-compose.tika.yml +++ b/docker/hub/docker-compose.tika.yml @@ -5,7 +5,7 @@ services: restart: always webserver: - image: jonaswinkler/paperless-ng:0.9.13 + image: jonaswinkler/paperless-ng:0.9.14 restart: always depends_on: - broker diff --git a/src-ui/src/environments/environment.prod.ts b/src-ui/src/environments/environment.prod.ts index de212d2d5..c5ef431cd 100644 --- a/src-ui/src/environments/environment.prod.ts +++ b/src-ui/src/environments/environment.prod.ts @@ -2,5 +2,5 @@ export const environment = { production: true, apiBaseUrl: "/api/", appTitle: "Paperless-ng", - version: "0.9.13" + version: "0.9.14" }; diff --git a/src/paperless/version.py b/src/paperless/version.py index f5815078f..ac1d6312c 100644 --- a/src/paperless/version.py +++ b/src/paperless/version.py @@ -1 +1 @@ -__version__ = (0, 9, 13) +__version__ = (0, 9, 14)