mirror of
https://github.com/Cian-H/invenio-config-iform.git
synced 2025-12-22 13:11:56 +00:00
dep: global dep bump
config: adds i18n vars & extracted from gitlab configs config: form defaults and tighter CSP
This commit is contained in:
@@ -29,6 +29,7 @@ INVENIO_CONFIG_TUGRAZ_IP_RANGES =
|
||||
[["127.0.0.2", "127.0.0.99"], ["127.0.1.3", "127.0.1.5"]]
|
||||
"""
|
||||
|
||||
|
||||
CONFIG_TUGRAZ_ROUTES = {
|
||||
"guide": "/guide",
|
||||
"terms": "/terms",
|
||||
@@ -40,6 +41,7 @@ CONFIG_TUGRAZ_ROUTES = {
|
||||
# ===========
|
||||
# See https://invenio-app.readthedocs.io/en/latest/configuration.html
|
||||
|
||||
# TODO: move this to gitlab vars.
|
||||
APP_ALLOWED_HOSTS = [
|
||||
"0.0.0.0",
|
||||
"localhost",
|
||||
@@ -54,11 +56,8 @@ APP_DEFAULT_SECURE_HEADERS = {
|
||||
"content_security_policy": {
|
||||
"default-src": [
|
||||
"'self'",
|
||||
"fonts.googleapis.com",
|
||||
"*.gstatic.com",
|
||||
"data:",
|
||||
"'unsafe-inline'",
|
||||
"'unsafe-eval'",
|
||||
"blob:",
|
||||
"ub-support.tugraz.at", # zammad contact form
|
||||
],
|
||||
@@ -78,6 +77,15 @@ APP_DEFAULT_SECURE_HEADERS = {
|
||||
"strict_transport_security_preload": False,
|
||||
}
|
||||
|
||||
# Invenio-I18N
|
||||
# ============
|
||||
# See https://invenio-i18n.readthedocs.io/en/latest/configuration.html
|
||||
BABEL_DEFAULT_LOCALE = "en"
|
||||
# Default time zone
|
||||
BABEL_DEFAULT_TIMEZONE = "Europe/Vienna"
|
||||
# Other supported languages (do not include BABEL_DEFAULT_LOCALE in list).
|
||||
I18N_LANGUAGES = [("de", _("German"))]
|
||||
|
||||
# Invenio-Mail
|
||||
# ===========
|
||||
# See https://invenio-mail.readthedocs.io/en/latest/configuration.html
|
||||
@@ -239,10 +247,15 @@ password from ``users.yaml`` will be used. If that is also absent, a password
|
||||
will be generated randomly.
|
||||
"""
|
||||
|
||||
RDM_RECORDS_DOI_DATACITE_FORMAT = "{prefix}/datacite.{id}"
|
||||
"""Customize the generated DOI string."""
|
||||
|
||||
# Invenio-app-rdm
|
||||
# =========================
|
||||
# See https://github.com/inveniosoftware/invenio-app-rdm/blob/master/invenio_app_rdm/config.py
|
||||
APP_RDM_DEPOSIT_FORM_DEFAULTS = {}
|
||||
APP_RDM_DEPOSIT_FORM_DEFAULTS = {
|
||||
"publisher": "Graz University of Technology",
|
||||
}
|
||||
"""Default values for new records in the deposit UI.
|
||||
|
||||
The keys denote the dot-separated path, where in the record's metadata
|
||||
|
||||
17
setup.py
17
setup.py
@@ -16,12 +16,11 @@ readme = open("README.rst").read()
|
||||
history = open("CHANGES.rst").read()
|
||||
|
||||
tests_require = [
|
||||
"pytest-invenio>=1.4.0",
|
||||
"invenio-app>=1.3.0,<2.0.0",
|
||||
"pytest-invenio>=1.4.1",
|
||||
]
|
||||
|
||||
# Should follow invenio-app-rdm
|
||||
invenio_search_version = ">=1.4.0,<1.5.0"
|
||||
invenio_search_version = ">=1.4.1,<1.5.0"
|
||||
invenio_db_version = ">=1.0.9,<1.1.0"
|
||||
|
||||
extras_require = {
|
||||
@@ -30,7 +29,7 @@ extras_require = {
|
||||
"postgresql": [f"invenio-db[postgresql,versioning]{invenio_db_version}"],
|
||||
"sqlite": [f"invenio-db[versioning]{invenio_db_version}"],
|
||||
"docs": [
|
||||
"Sphinx>=3",
|
||||
"Sphinx>=3,<3.4.2",
|
||||
],
|
||||
"tests": tests_require,
|
||||
}
|
||||
@@ -47,14 +46,13 @@ for name, reqs in extras_require.items():
|
||||
extras_require["all"].extend(reqs)
|
||||
|
||||
setup_requires = [
|
||||
"Babel>=1.3",
|
||||
"pytest-runner>=3.0.0,<5",
|
||||
"Babel>=2.8,<3",
|
||||
]
|
||||
|
||||
install_requires = [
|
||||
"Flask-BabelEx>=0.9.4",
|
||||
# keep this in sync with invenioRDM release
|
||||
"invenio_app_rdm==4.0.0",
|
||||
"invenio-rdm-records>=0.32.2,<0.33.0",
|
||||
"invenio-cache>=1.1.0"
|
||||
]
|
||||
|
||||
packages = find_packages()
|
||||
@@ -110,6 +108,7 @@ setup(
|
||||
"Programming Language :: Python :: 3.6",
|
||||
"Programming Language :: Python :: 3.7",
|
||||
"Programming Language :: Python :: 3.8",
|
||||
"Development Status :: 3 - Alpha",
|
||||
"Programming Language :: Python :: 3.9",
|
||||
"Development Status :: 5 - Production/Stable",
|
||||
],
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user