First commit

This commit is contained in:
EC2 Default User
2025-01-27 15:21:57 +00:00
commit 607f72659d
49 changed files with 791219 additions and 0 deletions

2
.dockerignore Normal file
View File

@@ -0,0 +1,2 @@
# Ignore local virtualenv (if present)
.venv/

78
.gitignore vendored Normal file
View File

@@ -0,0 +1,78 @@
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
# C extensions
*.so
# Distribution / packaging
.Python
env/
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
*.egg-info/
.installed.cfg
*.egg
# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec
# Installer logs
pip-log.txt
pip-delete-this-directory.txt
# Unit test / coverage reports
htmlcov/
.tox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*,cover
# Translations
*.mo
*.pot
# Django stuff:
*.log
# Sphinx documentation
docs/_build/
# PyBuilder
target/
test.db
# Environments
.venv/
# Logs
logs/
# Invenio-cli per machine file
.invenio.private
# S3 default bucket location
data/default/*
data/.minio.sys
# Celery
celerybeat-schedule
# Configuration secrets
secrets.toml

40
.invenio Normal file
View File

@@ -0,0 +1,40 @@
[cli]
flavour = RDM
logfile = /logs/invenio-cli.log
[cookiecutter]
project_name = AM-D-Model Data Repository
project_shortname = am-d-model-data-repository
package_name = am_d_model_data_repository
project_site = am-d-model.eu
author_name = Cian Hughes
author_email = repo@am-d-model.eu
year = 2025
database = postgresql
search = opensearch2
file_storage = S3
development_tools = no
site_code = yes
use_reduced_vocabs = no
_template = https://github.com/inveniosoftware/cookiecutter-invenio-rdm.git
_output_dir = /home/ec2-user
[files]
app_data = {'pages': {'.gitkeep': '22818f8c9f68fb11b7ca893ad1c082f844ae9f691f082d2174e32738d9ae6114'}, 'vocabularies': {'cc_licences.csv': '19a8bfd2488c7adb90d1dbe1c70f57cf2e0a737cb11814cc814f917072843de7', 'languages.yaml': 'd3bdb59940e8e6cd2401785ad55733f5fc6a1fb0bb0a2005a8fe4e5148e5f286', 'names.yaml': '6dc80984186ec960bcf53fbb6c482554d0aaf386d345bf82f504fdbd896e5848', 'subjects_oecd_fos.yaml': 'eef38714c506d956193c3be17e6004049525d252bf22424f4804dfc1ad46db44', 'affiliations_ror.yaml': '2e913fbecacd3694cba1b9a10739164911c2d45db3b32f1cb923027c48e0ac3e'}, 'README.md': 'd58978488626bdeddc791a15a39e341a4ed06f202b84d0c0d4aa9ef49481c6d9', 'vocabularies.yaml': '86f780281913b4ed5683775632d36511b16dff4b4f90fa7f14127cf69ab4e0cc'}
assets = {'js': {'invenio_app_rdm': {'overridableRegistry': {'mapping.js': '7fb63c1b801d11f1c1bb9b7d5cad6662ae475210df2bbba6919cda402684590a'}}}, 'less': {'site': {'globals': {'site.overrides': 'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855', 'site.variables': 'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855'}}, 'theme.config': 'ee68441b779400585a3a1ed4445ab5727e3a47a09aa708976dd506c0e081f0d8'}, 'templates': {'custom_fields': {'.gitkeep': 'd4756cdf68d94c670c924f9d57d44718f666e457727701486435b57a97e52c5f'}, 'search': {'.gitkeep': 'd4756cdf68d94c670c924f9d57d44718f666e457727701486435b57a97e52c5f'}}}
docker = {'nginx': {'conf.d': {'default.conf': '732bdcce7677169820b28d8571779ee2f7837dfe9f8c0005584a44215fc1945c'}, 'Dockerfile': '541326766beaba2e8492255c99e11aa76640d71329ceab5bcab1c8d6a979bd5c', 'nginx.conf': '6c9a6e372fc340dfcd3b49e6a30bd7bd36af41d79d1d093b7b3ba5f4c9d781b4', 'test.key': '7f1487edd7967d03852e7c81294d076cab18a3b39fe49b54e43d0f48d128c98e', 'test.crt': '5a1f34bb9ceda8f06b3d87daec138b8518656a8be4fa335d1daf57f4a5463c61'}, 'pgadmin': {'servers.json': 'b539a3e71371ac83fa0a77c3c31aec2b7be9ae893f04cb4cb0a6059279be60f8'}, 'uwsgi': {'uwsgi_rest.ini': 'c36fc5021baf15f375b3b6c825f7753e5d166319c5fe38a85b604391ce5b37b6', 'uwsgi_ui.ini': 'aeb0797a1fadb462e0ed208c979d5152cc58a85958d4de9c4e989637c70b9005'}}
site = {'tests': {'.gitkeep': 'd4756cdf68d94c670c924f9d57d44718f666e457727701486435b57a97e52c5f'}, 'am_d_model_data_repository': {'assets': {'semantic-ui': {'js': {'am_d_model_data_repository': {'.gitkeep': '3253a6fe7fc74a1279fb374e67ffd3383eded63cd28c4877afd77dffc8cc5da4'}}, 'less': {'am_d_model_data_repository': {'.gitkeep': 'de96a61fec5b6b168bced6dda58bd11e353f618ae9bee45aad9253cb0d6c5617'}}}}, 'templates': {'semantic-ui': {'am_d_model_data_repository': {'.gitkeep': 'd4756cdf68d94c670c924f9d57d44718f666e457727701486435b57a97e52c5f'}}}, '__init__.py': 'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855', 'views.py': '5c34c570daaa127b694718727708ee73392cfeb4462cd1707c72cedc43971dfb', 'webpack.py': 'a53aca73a72522efc1e52607471e19455dadd5cfbd798ec8df6f55e37b170b0c'}, '.gitkeep': 'c2d6e68b24a41b5f076fafaa1c24aad3ebe9ee3234c00ea54396c508dc6f69ae', 'pyproject.toml': 'e1acd833b38f03f26cc31439246cbeeb82e2edf56c751f28c3247cb44e95caca', 'setup.cfg': 'fb99bdf193c1e775d24858486983e7b0628c9ac7da9590d0e44e5c872bdbaab6', 'setup.py': '843ac26c38a41abae578250bc0f9419194b320a0f67327d941037a4268f6cfe7'}
static = {'images': {'invenio-rdm.svg': '50f09b4d83244a69c58f44aa436a3fa097726d9b47fd0e0782ea92d31f854b65', 'logo-invenio-white.svg': '5af2c7b67a09798cba3d50cc2e811ca9fd2ff73b40d9d2a52a97237b9ed44008'}, 'robots.txt': 'bb37b06b33e7d97f41aef939f8ef3052898c7f6d6fdfc7c9d37b6d0605c86ff3'}
templates = {'.gitkeep': 'd4756cdf68d94c670c924f9d57d44718f666e457727701486435b57a97e52c5f'}
translations = {'babel.ini': '3fb6bff73460aa031d4f90fc1e1d16235cab84d2385c9831efacb2ce32e5409b'}
.dockerignore = 21241bc12cdf4ac5f209d6b191adc8f25eb89af93ce5c4c3f72c86661162d7b5
.gitignore = af1182c70588e583daeb35809e6cdfe3408425d438c3ceb282b1f4b8360290e2
dockerfile = 44e5c207cf3e82cddda086f73e6fa5f3bacfc06d11f55a95f954d744a773c605
readme.md = 528941c73490b753a680ad7228ae4ac2e4289432dd12ff0710a08e7ce5b5c059
pipfile = 78535681d6205c07134a485b443f33af820b122e52e568fb2a62aa90a6ae6db2
docker-compose.full.yml = 6443ea366a766fb0d02e15c55edd11f1840f23ac34613c343cadc7a573f8f951
docker-compose.yml = fbae67bb30a5b01d10b166059a3d1914e5b217b924c5535c6d73bf1974d752ce
docker-services.yml = 6cd691120f2fffcb7a07cde4405493c06534103fc3ad5c4e32162c89d7278e04
invenio.cfg = 8f2fa8199dd91a375f1dbe197258c247c2cb7b5a93c5300600770c40a713eead
data = {'default': {'.gitkeep': 'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855'}}

29
Dockerfile Normal file
View File

@@ -0,0 +1,29 @@
# Dockerfile that builds a fully functional image of your app.
#
# This image installs all Python dependencies for your application. It's based
# on Almalinux (https://github.com/inveniosoftware/docker-invenio)
# and includes Pip, Pipenv, Node.js, NPM and some few standard libraries
# Invenio usually needs.
#
# Note: It is important to keep the commands in this file in sync with your
# bootstrap script located in ./scripts/bootstrap.
FROM registry.cern.ch/inveniosoftware/almalinux:1
COPY site ./site
COPY Pipfile Pipfile.lock ./
RUN pipenv install --deploy --system
COPY ./docker/uwsgi/ ${INVENIO_INSTANCE_PATH}
COPY ./invenio.cfg ${INVENIO_INSTANCE_PATH}
COPY ./templates/ ${INVENIO_INSTANCE_PATH}/templates/
COPY ./app_data/ ${INVENIO_INSTANCE_PATH}/app_data/
COPY ./translations/ ${INVENIO_INSTANCE_PATH}/translations/
COPY ./ .
RUN cp -r ./static/. ${INVENIO_INSTANCE_PATH}/static/ && \
cp -r ./assets/. ${INVENIO_INSTANCE_PATH}/assets/ && \
invenio collect --verbose && \
invenio webpack buildall
ENTRYPOINT [ "bash", "-c"]

22
Pipfile Normal file
View File

@@ -0,0 +1,22 @@
[[source]]
name = "pypi"
url = "https://pypi.org/simple"
verify_ssl = true
[dev-packages]
check-manifest = ">=0.25"
[packages]
invenio-app-rdm = {extras = ["opensearch2", "s3"], version = "~=12.0.0"}
am-d-model-data-repository = {editable = true, path="./site"}
uwsgi = ">=2.0"
uwsgitop = ">=0.11"
uwsgi-tools = ">=1.1.1"
flask-admin = "==1.6.1"
tomli = "*"
[requires]
python_version = "3.9"
[pipenv]
allow_prereleases = false

3778
Pipfile.lock generated Normal file

File diff suppressed because it is too large Load Diff

49
README.md Normal file
View File

@@ -0,0 +1,49 @@
# AM-D-Model Data Repository
Welcome to your InvenioRDM instance.
## Getting started
Run the following commands in order to start your new InvenioRDM instance:
```console
invenio-cli containers start --lock --build --setup
```
The above command first builds the application docker image and afterwards
starts the application and related services (database, Opensearch, Redis
and RabbitMQ). The build and boot process will take some time to complete,
especially the first time as docker images have to be downloaded during the
process.
Once running, visit https://127.0.0.1 in your browser.
**Note**: The server is using a self-signed SSL certificate, so your browser
will issue a warning that you will have to by-pass.
## Overview
Following is an overview of the generated files and folders:
| Name | Description |
|---|---|
| ``Dockerfile`` | Dockerfile used to build your application image. |
| ``Pipfile`` | Python requirements installed via [pipenv](https://pipenv.pypa.io) |
| ``Pipfile.lock`` | Locked requirements (generated on first install). |
| ``app_data`` | Application data such as vocabularies. |
| ``assets`` | Web assets (CSS, JavaScript, LESS, JSX templates) used in the Webpack build. |
| ``docker`` | Example configuration for NGINX and uWSGI. |
| ``docker-compose.full.yml`` | Example of a full infrastructure stack. |
| ``docker-compose.yml`` | Backend services needed for local development. |
| ``docker-services.yml`` | Common services for the Docker Compose files. |
| ``invenio.cfg`` | The Invenio application configuration. |
| ``logs`` | Log files. |
| ``static`` | Static files that need to be served as-is (e.g. images). |
| ``templates`` | Folder for your Jinja templates. |
| ``.invenio`` | Common file used by Invenio-CLI to be version controlled. |
| ``.invenio.private`` | Private file used by Invenio-CLI *not* to be version controlled. |
## Documentation
To learn how to configure, customize, deploy and much more, visit
the [InvenioRDM Documentation](https://inveniordm.docs.cern.ch/).

6
app_data/README.md Normal file
View File

@@ -0,0 +1,6 @@
# README
Place in this directory the subdirectories containing application data.
For example, you can create the `vocabularies/` folder to hold
your custom controlled vocabularies.

1
app_data/pages/.gitkeep Normal file
View File

@@ -0,0 +1 @@
# This file exists only to add pages/ folder to git repository.

View File

@@ -0,0 +1,22 @@
subjects:
pid-type: sub
schemes:
- id: FOS
name: Fields of Science and Technology
uri: "http://www.oecd.org/science/inno/38235147.pdf"
data-file: vocabularies/subjects_oecd_fos.yaml
# Minimal example vocabularies
# can be used for quick testing, or a basis for building your own customized vocabularies.
#names:
# pid-type: names
# data-file: vocabularies/names.yaml
#licenses:
# pid-type: lic
# data-file: vocabularies/cc_licences.csv
#languages:
# pid-type: lng
# data-file: vocabularies/languages.yaml
# TODO: Uncomment this if you want to have all affiliations with ROR identifiers.
# affiliations:
# pid-type: aff
# data-file: vocabularies/affiliations_ror.yaml

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,37 @@
id;title__en;description__en;icon;tags;props__url;props__scheme;props__osi_approved
cc-by-1.0;Creative Commons Attribution 1.0 Generic;;cc-by-icon;all,data;https://creativecommons.org/licenses/by/1.0/legalcode;spdx;
cc-by-2.0;Creative Commons Attribution 2.0 Generic;;cc-by-icon;all,data;https://creativecommons.org/licenses/by/2.0/legalcode;spdx;
cc-by-2.5;Creative Commons Attribution 2.5 Generic;;cc-by-icon;all,data;https://creativecommons.org/licenses/by/2.5/legalcode;spdx;
cc-by-3.0;Creative Commons Attribution 3.0 Unported;;cc-by-icon;all,data;https://creativecommons.org/licenses/by/3.0/legalcode;spdx;
cc-by-3.0-at;Creative Commons Attribution 3.0 Austria;;cc-by-icon;all,data;https://creativecommons.org/licenses/by/3.0/at/legalcode;spdx;
cc-by-3.0-us;Creative Commons Attribution 3.0 United States;;cc-by-icon;all,data;https://creativecommons.org/licenses/by/3.0/us/legalcode;spdx;
cc-by-4.0;Creative Commons Attribution 4.0 International;The Creative Commons Attribution license allows re-distribution and re-use of a licensed work on the condition that the creator is appropriately credited.;cc-by-icon;recommended,all,data;https://creativecommons.org/licenses/by/4.0/legalcode;spdx;
cc-by-nc-1.0;Creative Commons Attribution Non Commercial 1.0 Generic;;cc-by-nc-icon;all,data;https://creativecommons.org/licenses/by-nc/1.0/legalcode;spdx;
cc-by-nc-2.0;Creative Commons Attribution Non Commercial 2.0 Generic;;cc-by-nc-icon;all,data;https://creativecommons.org/licenses/by-nc/2.0/legalcode;spdx;
cc-by-nc-2.5;Creative Commons Attribution Non Commercial 2.5 Generic;;cc-by-nc-icon;all,data;https://creativecommons.org/licenses/by-nc/2.5/legalcode;spdx;
cc-by-nc-3.0;Creative Commons Attribution Non Commercial 3.0 Unported;;cc-by-nc-icon;all,data;https://creativecommons.org/licenses/by-nc/3.0/legalcode;spdx;
cc-by-nc-4.0;Creative Commons Attribution Non Commercial 4.0 International;;cc-by-nc-icon;all,data;https://creativecommons.org/licenses/by-nc/4.0/legalcode;spdx;
cc-by-nc-nd-1.0;Creative Commons Attribution Non Commercial No Derivatives 1.0 Generic;;cc-by-nc-nd-icon;all,data;https://creativecommons.org/licenses/by-nd-nc/1.0/legalcode;spdx;
cc-by-nc-nd-2.0;Creative Commons Attribution Non Commercial No Derivatives 2.0 Generic;;cc-by-nc-nd-icon;all,data;https://creativecommons.org/licenses/by-nc-nd/2.0/legalcode;spdx;
cc-by-nc-nd-2.5;Creative Commons Attribution Non Commercial No Derivatives 2.5 Generic;;cc-by-nc-nd-icon;all,data;https://creativecommons.org/licenses/by-nc-nd/2.5/legalcode;spdx;
cc-by-nc-nd-3.0;Creative Commons Attribution Non Commercial No Derivatives 3.0 Unported;;cc-by-nc-nd-icon;all,data;https://creativecommons.org/licenses/by-nc-nd/3.0/legalcode;spdx;
cc-by-nc-nd-3.0-igo;Creative Commons Attribution Non Commercial No Derivatives 3.0 IGO;;cc-by-nc-nd-icon;all,data;https://creativecommons.org/licenses/by-nc-nd/3.0/igo/legalcode;spdx;
cc-by-nc-nd-4.0;Creative Commons Attribution Non Commercial No Derivatives 4.0 International;;cc-by-nc-nd-icon;all,data;https://creativecommons.org/licenses/by-nc-nd/4.0/legalcode;spdx;
cc-by-nc-sa-1.0;Creative Commons Attribution Non Commercial Share Alike 1.0 Generic;;cc-by-nc-sa-icon;all,data;https://creativecommons.org/licenses/by-nc-sa/1.0/legalcode;spdx;
cc-by-nc-sa-2.0;Creative Commons Attribution Non Commercial Share Alike 2.0 Generic;;cc-by-nc-sa-icon;all,data;https://creativecommons.org/licenses/by-nc-sa/2.0/legalcode;spdx;
cc-by-nc-sa-2.5;Creative Commons Attribution Non Commercial Share Alike 2.5 Generic;;cc-by-nc-sa-icon;all,data;https://creativecommons.org/licenses/by-nc-sa/2.5/legalcode;spdx;
cc-by-nc-sa-3.0;Creative Commons Attribution Non Commercial Share Alike 3.0 Unported;;cc-by-nc-sa-icon;all,data;https://creativecommons.org/licenses/by-nc-sa/3.0/legalcode;spdx;
cc-by-nc-sa-4.0;Creative Commons Attribution Non Commercial Share Alike 4.0 International;;cc-by-nc-sa-icon;all,data;https://creativecommons.org/licenses/by-nc-sa/4.0/legalcode;spdx;
cc-by-nd-1.0;Creative Commons Attribution No Derivatives 1.0 Generic;;cc-by-nd-icon;all,data;https://creativecommons.org/licenses/by-nd/1.0/legalcode;spdx;
cc-by-nd-2.0;Creative Commons Attribution No Derivatives 2.0 Generic;;cc-by-nd-icon;all,data;https://creativecommons.org/licenses/by-nd/2.0/legalcode;spdx;
cc-by-nd-2.5;Creative Commons Attribution No Derivatives 2.5 Generic;;cc-by-nd-icon;all,data;https://creativecommons.org/licenses/by-nd/2.5/legalcode;spdx;
cc-by-nd-3.0;Creative Commons Attribution No Derivatives 3.0 Unported;;cc-by-nd-icon;all,data;https://creativecommons.org/licenses/by-nd/3.0/legalcode;spdx;
cc-by-nd-4.0;Creative Commons Attribution No Derivatives 4.0 International;;cc-by-nd-icon;all,data;https://creativecommons.org/licenses/by-nd/4.0/legalcode;spdx;
cc-by-sa-1.0;Creative Commons Attribution Share Alike 1.0 Generic;;cc-by-sa-icon;all,data;https://creativecommons.org/licenses/by-sa/1.0/legalcode;spdx;
cc-by-sa-2.0;Creative Commons Attribution Share Alike 2.0 Generic;;cc-by-sa-icon;all,data;https://creativecommons.org/licenses/by-sa/2.0/legalcode;spdx;
cc-by-sa-2.0-uk;Creative Commons Attribution Share Alike 2.0 England and Wales;;;all,data;https://creativecommons.org/licenses/by-sa/2.0/uk/legalcode;spdx;
cc-by-sa-2.5;Creative Commons Attribution Share Alike 2.5 Generic;;cc-by-sa-icon;all,data;https://creativecommons.org/licenses/by-sa/2.5/legalcode;spdx;
cc-by-sa-3.0;Creative Commons Attribution Share Alike 3.0 Unported;;cc-by-sa-icon;all,data;https://creativecommons.org/licenses/by-sa/3.0/legalcode;spdx;
cc-by-sa-3.0-at;Creative Commons Attribution-Share Alike 3.0 Austria;;cc-by-sa-icon;all,data;https://creativecommons.org/licenses/by-sa/3.0/at/legalcode;spdx;
cc-by-sa-4.0;Creative Commons Attribution Share Alike 4.0 International;Permits almost any use subject to providing credit and license notice. Frequently used for media assets and educational materials. The most common license for Open Access scientific publications. Not recommended for software.;cc-by-sa-icon;recommended,all,data;https://creativecommons.org/licenses/by-sa/4.0/legalcode;spdx;
cc-pddc;Creative Commons Public Domain Dedication and Certification;;cc-pddc-icon;all;https://creativecommons.org/licenses/publicdomain/;spdx;
1 id title__en description__en icon tags props__url props__scheme props__osi_approved
2 cc-by-1.0 Creative Commons Attribution 1.0 Generic cc-by-icon all,data https://creativecommons.org/licenses/by/1.0/legalcode spdx
3 cc-by-2.0 Creative Commons Attribution 2.0 Generic cc-by-icon all,data https://creativecommons.org/licenses/by/2.0/legalcode spdx
4 cc-by-2.5 Creative Commons Attribution 2.5 Generic cc-by-icon all,data https://creativecommons.org/licenses/by/2.5/legalcode spdx
5 cc-by-3.0 Creative Commons Attribution 3.0 Unported cc-by-icon all,data https://creativecommons.org/licenses/by/3.0/legalcode spdx
6 cc-by-3.0-at Creative Commons Attribution 3.0 Austria cc-by-icon all,data https://creativecommons.org/licenses/by/3.0/at/legalcode spdx
7 cc-by-3.0-us Creative Commons Attribution 3.0 United States cc-by-icon all,data https://creativecommons.org/licenses/by/3.0/us/legalcode spdx
8 cc-by-4.0 Creative Commons Attribution 4.0 International The Creative Commons Attribution license allows re-distribution and re-use of a licensed work on the condition that the creator is appropriately credited. cc-by-icon recommended,all,data https://creativecommons.org/licenses/by/4.0/legalcode spdx
9 cc-by-nc-1.0 Creative Commons Attribution Non Commercial 1.0 Generic cc-by-nc-icon all,data https://creativecommons.org/licenses/by-nc/1.0/legalcode spdx
10 cc-by-nc-2.0 Creative Commons Attribution Non Commercial 2.0 Generic cc-by-nc-icon all,data https://creativecommons.org/licenses/by-nc/2.0/legalcode spdx
11 cc-by-nc-2.5 Creative Commons Attribution Non Commercial 2.5 Generic cc-by-nc-icon all,data https://creativecommons.org/licenses/by-nc/2.5/legalcode spdx
12 cc-by-nc-3.0 Creative Commons Attribution Non Commercial 3.0 Unported cc-by-nc-icon all,data https://creativecommons.org/licenses/by-nc/3.0/legalcode spdx
13 cc-by-nc-4.0 Creative Commons Attribution Non Commercial 4.0 International cc-by-nc-icon all,data https://creativecommons.org/licenses/by-nc/4.0/legalcode spdx
14 cc-by-nc-nd-1.0 Creative Commons Attribution Non Commercial No Derivatives 1.0 Generic cc-by-nc-nd-icon all,data https://creativecommons.org/licenses/by-nd-nc/1.0/legalcode spdx
15 cc-by-nc-nd-2.0 Creative Commons Attribution Non Commercial No Derivatives 2.0 Generic cc-by-nc-nd-icon all,data https://creativecommons.org/licenses/by-nc-nd/2.0/legalcode spdx
16 cc-by-nc-nd-2.5 Creative Commons Attribution Non Commercial No Derivatives 2.5 Generic cc-by-nc-nd-icon all,data https://creativecommons.org/licenses/by-nc-nd/2.5/legalcode spdx
17 cc-by-nc-nd-3.0 Creative Commons Attribution Non Commercial No Derivatives 3.0 Unported cc-by-nc-nd-icon all,data https://creativecommons.org/licenses/by-nc-nd/3.0/legalcode spdx
18 cc-by-nc-nd-3.0-igo Creative Commons Attribution Non Commercial No Derivatives 3.0 IGO cc-by-nc-nd-icon all,data https://creativecommons.org/licenses/by-nc-nd/3.0/igo/legalcode spdx
19 cc-by-nc-nd-4.0 Creative Commons Attribution Non Commercial No Derivatives 4.0 International cc-by-nc-nd-icon all,data https://creativecommons.org/licenses/by-nc-nd/4.0/legalcode spdx
20 cc-by-nc-sa-1.0 Creative Commons Attribution Non Commercial Share Alike 1.0 Generic cc-by-nc-sa-icon all,data https://creativecommons.org/licenses/by-nc-sa/1.0/legalcode spdx
21 cc-by-nc-sa-2.0 Creative Commons Attribution Non Commercial Share Alike 2.0 Generic cc-by-nc-sa-icon all,data https://creativecommons.org/licenses/by-nc-sa/2.0/legalcode spdx
22 cc-by-nc-sa-2.5 Creative Commons Attribution Non Commercial Share Alike 2.5 Generic cc-by-nc-sa-icon all,data https://creativecommons.org/licenses/by-nc-sa/2.5/legalcode spdx
23 cc-by-nc-sa-3.0 Creative Commons Attribution Non Commercial Share Alike 3.0 Unported cc-by-nc-sa-icon all,data https://creativecommons.org/licenses/by-nc-sa/3.0/legalcode spdx
24 cc-by-nc-sa-4.0 Creative Commons Attribution Non Commercial Share Alike 4.0 International cc-by-nc-sa-icon all,data https://creativecommons.org/licenses/by-nc-sa/4.0/legalcode spdx
25 cc-by-nd-1.0 Creative Commons Attribution No Derivatives 1.0 Generic cc-by-nd-icon all,data https://creativecommons.org/licenses/by-nd/1.0/legalcode spdx
26 cc-by-nd-2.0 Creative Commons Attribution No Derivatives 2.0 Generic cc-by-nd-icon all,data https://creativecommons.org/licenses/by-nd/2.0/legalcode spdx
27 cc-by-nd-2.5 Creative Commons Attribution No Derivatives 2.5 Generic cc-by-nd-icon all,data https://creativecommons.org/licenses/by-nd/2.5/legalcode spdx
28 cc-by-nd-3.0 Creative Commons Attribution No Derivatives 3.0 Unported cc-by-nd-icon all,data https://creativecommons.org/licenses/by-nd/3.0/legalcode spdx
29 cc-by-nd-4.0 Creative Commons Attribution No Derivatives 4.0 International cc-by-nd-icon all,data https://creativecommons.org/licenses/by-nd/4.0/legalcode spdx
30 cc-by-sa-1.0 Creative Commons Attribution Share Alike 1.0 Generic cc-by-sa-icon all,data https://creativecommons.org/licenses/by-sa/1.0/legalcode spdx
31 cc-by-sa-2.0 Creative Commons Attribution Share Alike 2.0 Generic cc-by-sa-icon all,data https://creativecommons.org/licenses/by-sa/2.0/legalcode spdx
32 cc-by-sa-2.0-uk Creative Commons Attribution Share Alike 2.0 England and Wales all,data https://creativecommons.org/licenses/by-sa/2.0/uk/legalcode spdx
33 cc-by-sa-2.5 Creative Commons Attribution Share Alike 2.5 Generic cc-by-sa-icon all,data https://creativecommons.org/licenses/by-sa/2.5/legalcode spdx
34 cc-by-sa-3.0 Creative Commons Attribution Share Alike 3.0 Unported cc-by-sa-icon all,data https://creativecommons.org/licenses/by-sa/3.0/legalcode spdx
35 cc-by-sa-3.0-at Creative Commons Attribution-Share Alike 3.0 Austria cc-by-sa-icon all,data https://creativecommons.org/licenses/by-sa/3.0/at/legalcode spdx
36 cc-by-sa-4.0 Creative Commons Attribution Share Alike 4.0 International Permits almost any use subject to providing credit and license notice. Frequently used for media assets and educational materials. The most common license for Open Access scientific publications. Not recommended for software. cc-by-sa-icon recommended,all,data https://creativecommons.org/licenses/by-sa/4.0/legalcode spdx
37 cc-pddc Creative Commons Public Domain Dedication and Certification cc-pddc-icon all https://creativecommons.org/licenses/publicdomain/ spdx

View File

@@ -0,0 +1,96 @@
- id: ara
props:
alpha_2: ar
tags:
- macrolanguage
- living
title:
en: Arabic
- id: cym
props:
alpha_2: cy
tags:
- individual
- living
title:
en: Welsh
- id: deu
props:
alpha_2: de
tags:
- individual
- living
title:
en: German
- id: eng
props:
alpha_2: en
tags:
- individual
- living
title:
en: English
- id: fra
props:
alpha_2: fr
tags:
- individual
- living
title:
en: French
- id: ita
props:
alpha_2: it
tags:
- individual
- living
title:
en: Italian
- id: nor
props:
alpha_2: 'no'
tags:
- macrolanguage
- living
title:
en: Norwegian
- id: roh
props:
alpha_2: rm
tags:
- individual
- living
title:
en: Romansh
- id: spa
props:
alpha_2: es
tags:
- individual
- living
title:
en: Spanish
- id: tur
props:
alpha_2: tr
tags:
- individual
- living
title:
en: Turkish
- id: aag
props:
alpha_2: ''
tags:
- individual
- living
title:
en: Ambrak
- id: aah
props:
alpha_2: ''
tags:
- individual
- living
title:
en: Abu' Arapesh

View File

@@ -0,0 +1,20 @@
- affiliations:
- name: University of Zurich
- name: Humboldt University of Berlin
- name: Kaiser Wilhelm Institute for Physics
family_name: Einstein
given_name: Albert
id: gnd:118529579
identifiers:
- identifier: gnd:118529579
scheme: gnd
- affiliations:
- name: University of Cambridge
- name: California Institute of Technology
- name: University of Oxford
family_name: Hawking
given_name: Stephen
id: 0000-0002-9079-593X
identifiers:
- identifier: https://orcid.org/0000-0002-9079-593X
scheme: orcid

View File

@@ -0,0 +1,144 @@
- id: "http://www.oecd.org/science/inno/38235147.pdf?1"
scheme: FOS
subject: "Natural sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?1.1"
scheme: FOS
subject: "Mathematics"
- id: "http://www.oecd.org/science/inno/38235147.pdf?1.2"
scheme: FOS
subject: "Computer and information sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?1.3"
scheme: FOS
subject: "Physical sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?1.4"
scheme: FOS
subject: "Chemical sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?1.5"
scheme: FOS
subject: "Earth and related environmental sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?1.6"
scheme: FOS
subject: "Biological sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?1.7"
scheme: FOS
subject: "Other natural sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?2"
scheme: FOS
subject: "Engineering and technology"
- id: "http://www.oecd.org/science/inno/38235147.pdf?2.1"
scheme: FOS
subject: "Civil engineering"
- id: "http://www.oecd.org/science/inno/38235147.pdf?2.2"
scheme: FOS
subject: "Electrical engineering, electronic engineering, information engineering"
- id: "http://www.oecd.org/science/inno/38235147.pdf?2.3"
scheme: FOS
subject: "Mechanical engineering"
- id: "http://www.oecd.org/science/inno/38235147.pdf?2.4"
scheme: FOS
subject: "Chemical engineering"
- id: "http://www.oecd.org/science/inno/38235147.pdf?2.5"
scheme: FOS
subject: "Materials engineering"
- id: "http://www.oecd.org/science/inno/38235147.pdf?2.6"
scheme: FOS
subject: "Medical engineering"
- id: "http://www.oecd.org/science/inno/38235147.pdf?2.7"
scheme: FOS
subject: "Environmental engineering"
- id: "http://www.oecd.org/science/inno/38235147.pdf?2.8"
scheme: FOS
subject: "Environmental biotechnology"
- id: "http://www.oecd.org/science/inno/38235147.pdf?2.9"
scheme: FOS
subject: "Industrial biotechnology"
- id: "http://www.oecd.org/science/inno/38235147.pdf?2.10"
scheme: FOS
subject: "Nano technology"
- id: "http://www.oecd.org/science/inno/38235147.pdf?2.11"
scheme: FOS
subject: "Other engineering and technologies"
- id: "http://www.oecd.org/science/inno/38235147.pdf?3"
scheme: FOS
subject: "Medical and health sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?3.1"
scheme: FOS
subject: "Basic medicine"
- id: "http://www.oecd.org/science/inno/38235147.pdf?3.2"
scheme: FOS
subject: "Clinical medicine"
- id: "http://www.oecd.org/science/inno/38235147.pdf?3.3"
scheme: FOS
subject: "Health sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?3.4"
scheme: FOS
subject: "Health biotechnology"
- id: "http://www.oecd.org/science/inno/38235147.pdf?3.5"
scheme: FOS
subject: "Other medical sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?4"
scheme: FOS
subject: "Agricultural sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?4.1"
scheme: FOS
subject: "Agriculture, forestry, and fisheries"
- id: "http://www.oecd.org/science/inno/38235147.pdf?4.2"
scheme: FOS
subject: "Animal and dairy science"
- id: "http://www.oecd.org/science/inno/38235147.pdf?4.3"
scheme: FOS
subject: "Veterinary science"
- id: "http://www.oecd.org/science/inno/38235147.pdf?4.4"
scheme: FOS
subject: "Agricultural biotechnology"
- id: "http://www.oecd.org/science/inno/38235147.pdf?4.5"
scheme: FOS
subject: "Other agricultural sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?5"
scheme: FOS
subject: "Social science"
- id: "http://www.oecd.org/science/inno/38235147.pdf?5.1"
scheme: FOS
subject: "Psychology"
- id: "http://www.oecd.org/science/inno/38235147.pdf?5.2"
scheme: FOS
subject: "Economics and business"
- id: "http://www.oecd.org/science/inno/38235147.pdf?5.3"
scheme: FOS
subject: "Educational sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?5.4"
scheme: FOS
subject: "Sociology"
- id: "http://www.oecd.org/science/inno/38235147.pdf?5.5"
scheme: FOS
subject: "Law"
- id: "http://www.oecd.org/science/inno/38235147.pdf?5.6"
scheme: FOS
subject: "Political science"
- id: "http://www.oecd.org/science/inno/38235147.pdf?5.7"
scheme: FOS
subject: "Social and economic geography"
- id: "http://www.oecd.org/science/inno/38235147.pdf?5.8"
scheme: FOS
subject: "Media and communications"
- id: "http://www.oecd.org/science/inno/38235147.pdf?5.9"
scheme: FOS
subject: "Other social sciences"
- id: "http://www.oecd.org/science/inno/38235147.pdf?6"
scheme: FOS
subject: "Humanities"
- id: "http://www.oecd.org/science/inno/38235147.pdf?6.1"
scheme: FOS
subject: "History and archaeology"
- id: "http://www.oecd.org/science/inno/38235147.pdf?6.2"
scheme: FOS
subject: "Languages and literature"
- id: "http://www.oecd.org/science/inno/38235147.pdf?6.3"
scheme: FOS
subject: "Philosophy, ethics and religion"
- id: "http://www.oecd.org/science/inno/38235147.pdf?6.4"
scheme: FOS
subject: "Arts (arts, history of arts, performing arts, music)"
- id: "http://www.oecd.org/science/inno/38235147.pdf?6.5"
scheme: FOS
subject: "Other humanities"

View File

@@ -0,0 +1,11 @@
// This file is part of InvenioRDM
// Copyright (C) 2023 CERN.
//
// Invenio App RDM is free software; you can redistribute it and/or modify it
// under the terms of the MIT License; see LICENSE file for more details.
/**
* Add here all the overridden components of your app.
*/
export const overriddenComponents = {}

View File

View File

96
assets/less/theme.config Normal file
View File

@@ -0,0 +1,96 @@
/*
████████╗██╗ ██╗███████╗███╗ ███╗███████╗███████╗
╚══██╔══╝██║ ██║██╔════╝████╗ ████║██╔════╝██╔════╝
██║ ███████║█████╗ ██╔████╔██║█████╗ ███████╗
██║ ██╔══██║██╔══╝ ██║╚██╔╝██║██╔══╝ ╚════██║
██║ ██║ ██║███████╗██║ ╚═╝ ██║███████╗███████║
╚═╝ ╚═╝ ╚═╝╚══════╝╚═╝ ╚═╝╚══════╝╚══════╝
*/
/*******************************
Theme Selection
*******************************/
/* To override a theme for an individual element
specify theme name below
*/
/* Global */
@site : 'rdm';
@reset : 'default';
/* Elements */
@button : 'rdm';
@container : 'rdm';
@divider : 'rdm';
@flag : 'rdm';
@header : 'rdm';
@icon : 'default';
@image : 'rdm';
@input : 'rdm';
@label : 'rdm';
@list : 'rdm';
@loader : 'rdm';
@placeholder : 'rdm';
@rail : 'rdm';
@reveal : 'rdm';
@segment : 'rdm';
@step : 'rdm';
/* Collections */
@breadcrumb : 'rdm';
@form : 'rdm';
@grid : 'rdm';
@menu : 'rdm';
@message : 'rdm';
@table : 'rdm';
/* Modules */
@accordion : 'rdm';
@checkbox : 'rdm';
@dimmer : 'rdm';
@dropdown : 'rdm';
@embed : 'rdm';
@modal : 'rdm';
@nag : 'rdm';
@popup : 'rdm';
@progress : 'rdm';
@rating : 'rdm';
@search : 'rdm';
@shape : 'rdm';
@sidebar : 'rdm';
@sticky : 'rdm';
@tab : 'rdm';
@transition : 'default';
/* Views */
@ad : 'rdm';
@card : 'rdm';
@comment : 'rdm';
@feed : 'rdm';
@item : 'rdm';
@statistic : 'rdm';
/*******************************
Folders
*******************************/
/* Path to theme packages */
@themesFolder : '~semantic-ui-less/themes';
/* Path to site override folder */
@siteFolder : '../../less/site';
@imagesFolder : '../../images';
/*******************************
Import Theme
*******************************/
@import (multiple) "themes/rdm/theme.less";
@fontPath : "../../../themes/@{theme}/assets/fonts";
/* End Config */

View File

@@ -0,0 +1 @@
# This file exists only to add templates/ folder to git repository.

View File

@@ -0,0 +1 @@
# This file exists only to add templates/ folder to git repository.

96
docker-compose.full.yml Normal file
View File

@@ -0,0 +1,96 @@
# Example of a full infrastructure stack
#
# Note, this file is not suitable for a production deployment. It is only an
# example of all the infrastructure components needed in a real production
# deployment.
#
# Usage::
#
# $ docker-compose up -f docker-compose.full.yml -d
#
# Following services are included:
# - Frontend: Nginx (exposed ports: 40 and 443)
# - UI application: UWSGI (not exposed)
# - API application: UWSGI (not exposed)
# - Cache: Redis (exposed port: 6379)
# - DB: (PostgresSQL/MySQL) (exposed port: 5432 or 3306)
# - Message queue: RabbitMQ (exposed ports: 5672, 15672)
# - Search platform: (OpenSearch) (exposed ports: 9200, 9600)
# - OpenSearch Dashboard/Kibana (view OS/ES indexes) (exposed ports: 5601)
#
version: '2.2'
services:
cache:
extends:
file: docker-services.yml
service: cache
db:
extends:
file: docker-services.yml
service: db
mq:
extends:
file: docker-services.yml
service: mq
search:
extends:
file: docker-services.yml
service: search
s3:
extends:
file: docker-services.yml
service: s3
# Frontend
frontend:
extends:
file: docker-services.yml
service: frontend
volumes:
- static_data:/opt/invenio/var/instance/static
depends_on:
- web-ui
- web-api
ports:
- "80:80"
- "443:443"
# UI Application
web-ui:
extends:
file: docker-services.yml
service: app
command: ["uwsgi /opt/invenio/var/instance/uwsgi_ui.ini"]
image: am-d-model-data-repository:latest
ports:
- "5000"
volumes:
- static_data:/opt/invenio/var/instance/static
# API Rest Application
web-api:
extends:
file: docker-services.yml
service: app
command: ["uwsgi /opt/invenio/var/instance/uwsgi_rest.ini"]
image: am-d-model-data-repository:latest
ports:
- "5000"
# Worker
worker:
extends:
file: docker-services.yml
service: app
command: ["celery -A invenio_app.celery worker --beat --loglevel=INFO"]
image: am-d-model-data-repository:latest
depends_on:
search:
condition: service_started
cache:
condition: service_started
db:
condition: service_started
mq:
condition: service_started
volumes:
static_data:
data:

40
docker-compose.yml Normal file
View File

@@ -0,0 +1,40 @@
# Backend services needed for development.
#
# This file will start all the backend services needed to run InvenioRDM
# locally in development mode.
#
# Usage::
#
# $ docker-compose up -d
#
# Following services are included:
# - Cache: Redis (exposed port: 6379)
# - DB: (PostgresSQL/MySQL) (exposed port: 5432 or 3306)
# - Message queue: RabbitMQ (exposed ports: 5672, 15672)
# - OpenSearch (exposed ports: 9200, 9600)
# - Kibana (view ES indexes) (exposed ports: 5601)
#
version: '2.2'
services:
cache:
extends:
file: docker-services.yml
service: cache
db:
extends:
file: docker-services.yml
service: db
mq:
extends:
file: docker-services.yml
service: mq
search:
extends:
file: docker-services.yml
service: search
s3:
extends:
file: docker-services.yml
service: s3
volumes:
data:

108
docker-services.yml Normal file
View File

@@ -0,0 +1,108 @@
version: '2.2'
services:
app:
build:
context: ./
args:
- ENVIRONMENT=DEV
image: am-d-model-data-repository
restart: "unless-stopped"
environment:
- "INVENIO_ACCOUNTS_SESSION_REDIS_URL=redis://cache:6379/1"
- "INVENIO_BROKER_URL=amqp://guest:guest@mq:5672/"
- "INVENIO_CACHE_REDIS_URL=redis://cache:6379/0"
- "INVENIO_CACHE_TYPE=redis"
- "INVENIO_CELERY_BROKER_URL=amqp://guest:guest@mq:5672/"
- "INVENIO_CELERY_RESULT_BACKEND=redis://cache:6379/2"
- "INVENIO_COMMUNITIES_IDENTITIES_CACHE_REDIS_URL=redis://cache:6379/4"
- "INVENIO_SEARCH_HOSTS=['search:9200']"
- "INVENIO_SECRET_KEY=CHANGE_ME"
- "INVENIO_SQLALCHEMY_DATABASE_URI=postgresql+psycopg2://am-d-model-data-repository:am-d-model-data-repository@db/am-d-model-data-repository"
- "INVENIO_WSGI_PROXIES=2"
- "INVENIO_RATELIMIT_STORAGE_URL=redis://cache:6379/3"
frontend:
build: ./docker/nginx/
image: am-d-model-data-repository-frontend
restart: "unless-stopped"
ports:
- "80"
- "443"
cache:
image: redis:7
restart: "unless-stopped"
read_only: true
ports:
- "6379:6379"
db:
image: postgres:14.13
restart: "unless-stopped"
environment:
- "POSTGRES_USER=am-d-model-data-repository"
- "POSTGRES_PASSWORD=am-d-model-data-repository"
- "POSTGRES_DB=am-d-model-data-repository"
ports:
- "5432:5432"
pgadmin:
image: dpage/pgadmin4:6
restart: "unless-stopped"
ports:
- "5050:80"
environment:
PGADMIN_DEFAULT_EMAIL: "repo@am-d-model.eu"
PGADMIN_DEFAULT_PASSWORD: "am-d-model-data-repository"
volumes:
- ./docker/pgadmin/servers.json:/pgadmin4/servers.json
mq:
image: rabbitmq:3-management
restart: "unless-stopped"
ports:
- "15672:15672"
- "5672:5672"
search:
image: opensearchproject/opensearch:2.17.1
restart: "unless-stopped"
environment:
# settings only for development. DO NOT use in production!
- bootstrap.memory_lock=true
- "OPENSEARCH_JAVA_OPTS=-Xms512m -Xmx512m"
- "DISABLE_INSTALL_DEMO_CONFIG=true"
- "DISABLE_SECURITY_PLUGIN=true"
- "discovery.type=single-node"
ulimits:
memlock:
soft: -1
hard: -1
nofile:
soft: 65536
hard: 65536
mem_limit: 2g
ports:
- "9200:9200"
- "9600:9600"
opensearch-dashboards:
image: opensearchproject/opensearch-dashboards:2.17.1
ports:
- "5601:5601"
expose:
- "5601"
environment:
# settings only for development. DO NOT use in production!
- 'OPENSEARCH_HOSTS=["http://search:9200"]'
- "DISABLE_SECURITY_DASHBOARDS_PLUGIN=true"
s3:
image: minio/minio:RELEASE.2022-10-24T18-35-07Z
restart: "unless-stopped"
ports:
- "9000:9000"
- "9001:9001"
environment:
MINIO_ROOT_USER: CHANGE_ME
MINIO_ROOT_PASSWORD: CHANGE_ME
volumes:
- ./data:/data
command: server /data --console-address :9001
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
interval: 30s
timeout: 20s
retries: 3

5
docker/nginx/Dockerfile Normal file
View File

@@ -0,0 +1,5 @@
FROM nginx
COPY nginx.conf /etc/nginx/nginx.conf
COPY conf.d/* /etc/nginx/conf.d/
COPY test.key /etc/ssl/private/test.key
COPY test.crt /etc/ssl/certs/test.crt

View File

@@ -0,0 +1,133 @@
# This nginx configuration defines two servers, one on port 80 and one on port
# 443. All traffix on port 80 is redirect to port 443 on SSL.
#
# Nginx proxies all requests on port 443 to upstream the application server
# which is expected to be running on port 5000/5001.
upstream ui_server {
server web-ui:5000 fail_timeout=0;
}
upstream api_server {
server web-api:5000 fail_timeout=0;
}
# HTTP server
server {
# Redirects all requests to https. - this is in addition to HAProxy which
# already redirects http to https. This redirect is needed in case you access
# the server directly (e.g. useful for debugging).
listen 80 default_server; # IPv4
listen [::]:80 default_server; # IPv6
server_name _;
return 301 https://$host$request_uri;
}
# HTTPS server
server {
listen 443 default_server ssl http2; # IPv4
listen [::]:443 default_server ssl http2; # IPv6
server_name _;
charset utf-8;
keepalive_timeout 5;
# SSL configuration according to best practices from
# https://mozilla.github.io/server-side-tls/ssl-config-generator/
# The provided certificate (test.crt) and private key (test.key) is only for
# testing and must never be used in production environment.
ssl_certificate /etc/ssl/certs/test.crt;
ssl_certificate_key /etc/ssl/private/test.key;
ssl_session_timeout 1d;
ssl_session_cache shared:SSL:50m;
ssl_session_tickets off;
# Accepted protocols and ciphers
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_ciphers 'ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256';
ssl_prefer_server_ciphers on;
add_header Strict-Transport-Security "max-age=15768000"; # 6 months
# Request ID tracing (allows end-to-end tracking of requests for better
# troubleshooting)
add_header X-Request-ID $request_id;
# The request body is sent to the proxied server immediately as it is
# received
proxy_request_buffering off;
# Sets the HTTP protocol v1.1 for proxying in order to not use the buffer
# in case of chunked transfer encoding
proxy_http_version 1.1;
# Proxying to the application server
## UI server
location / {
uwsgi_pass ui_server;
include uwsgi_params;
uwsgi_buffering off;
uwsgi_request_buffering off;
chunked_transfer_encoding off;
uwsgi_param Host $host;
uwsgi_param X-Forwarded-For $proxy_add_x_forwarded_for;
uwsgi_param X-Forwarded-Proto $scheme;
# Pass request id to the ui server
uwsgi_param X-Request-ID $request_id;
# X-Session-ID / X-User-ID is read by nginx and included in the logs,
# however we don't want to expose them to clients so we are hiding them.
uwsgi_hide_header X-Session-ID;
uwsgi_hide_header X-User-ID;
# Max upload size (except for files) is set to 100mb as default.
client_max_body_size 100m;
}
## Most API
location /api {
uwsgi_pass api_server;
include uwsgi_params;
uwsgi_buffering off;
uwsgi_request_buffering off;
chunked_transfer_encoding off;
uwsgi_param Host $host;
uwsgi_param X-Forwarded-For $proxy_add_x_forwarded_for;
uwsgi_param X-Forwarded-Proto $scheme;
# Pass request id to the api server
uwsgi_param X-Request-ID $request_id;
# X-Session-ID / X-User-ID is read by nginx and included in the logs,
# however we don't want to expose them to clients so we are hiding them.
uwsgi_hide_header X-Session-ID;
uwsgi_hide_header X-User-ID;
# Max upload size (except for files) is set to 100mb as default.
client_max_body_size 100m;
}
## API files
# Another location is defined in order to allow large file uploads in the files
# API without exposing the other parts of the application to receive huge
# request bodies.
location ~ /api/records/.+/draft/files/.+/content {
gzip off;
uwsgi_pass api_server;
include uwsgi_params;
uwsgi_buffering off;
uwsgi_request_buffering off;
chunked_transfer_encoding off;
uwsgi_param Host $host;
uwsgi_param X-Forwarded-For $proxy_add_x_forwarded_for;
uwsgi_param X-Forwarded-Proto $scheme;
# Pass request id to api server
uwsgi_param X-Request-ID $request_id;
# X-Session-ID / X-User-ID is read by nginx and included in the logs,
# however we don't want to expose them to clients so we are hiding them.
uwsgi_hide_header X-Session-ID;
uwsgi_hide_header X-User-ID;
# Max upload size for files is set to 50GB (configure as needed).
client_max_body_size 50G;
}
# Static content is served directly by nginx and not the application server.
location /static {
alias /opt/invenio/var/instance/static;
autoindex off;
}
# Robots.txt file is served by nginx.
location /robots.txt {
alias /opt/invenio/var/instance/static/robots.txt;
autoindex off;
}
}

76
docker/nginx/nginx.conf Normal file
View File

@@ -0,0 +1,76 @@
user nginx;
worker_processes 1;
error_log /var/log/nginx/error.log warn;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
}
http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
# Standard log format
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
# Request tracing log format - includes request id, session id, user id,
# and request timing.
log_format trace '$remote_addr - [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for" $request_id '
'$msec $request_time '
'$upstream_http_x_session_id $upstream_http_x_user_id';
access_log /var/log/nginx/access.log trace;
sendfile on;
tcp_nopush on;
tcp_nodelay on;
keepalive_timeout 65;
gzip on;
gzip_disable "msie6";
gzip_http_version 1.1;
gzip_comp_level 5; # or anything between 4-6
gzip_min_length 100;
gzip_proxied any;
# We may need more mime-types here (eg. 'application/x-bibtex')
gzip_types
application/atom+xml
application/javascript
application/json
application/ld+json
application/manifest+json
application/octet-stream
application/rss+xml
application/vnd.geo+json
application/vnd.ms-fontobject
application/x-font-ttf
application/x-javascript
application/x-web-app-manifest+json
application/xhtml+xml
application/xml
application/xml+rss
font/opentype
image/bmp
image/svg+xml
image/x-icon
text/cache-manifest
text/css
text/javascript
text/plain
text/vcard
text/vnd.rim.location.xloc
text/vtt
text/x-component
text/x-cross-domain-policy
text/xml;
gzip_vary on;
include /etc/nginx/conf.d/*.conf;
}

33
docker/nginx/test.crt Normal file
View File

@@ -0,0 +1,33 @@
-----BEGIN CERTIFICATE-----
MIIFpzCCA4+gAwIBAgIUUYJ6tvU7tTyQgpunblH/obBk/WAwDQYJKoZIhvcNAQEL
BQAwYzELMAkGA1UEBhMCQ0gxCjAIBgNVBAgMAS4xCjAIBgNVBAcMAS4xCjAIBgNV
BAoMAS4xCjAIBgNVBAsMAS4xEjAQBgNVBAMMCWxvY2FsaG9zdDEQMA4GCSqGSIb3
DQEJARYBLjAeFw0yNTAxMjcwOTUwMjBaFw0yNjAxMjcwOTUwMjBaMGMxCzAJBgNV
BAYTAkNIMQowCAYDVQQIDAEuMQowCAYDVQQHDAEuMQowCAYDVQQKDAEuMQowCAYD
VQQLDAEuMRIwEAYDVQQDDAlsb2NhbGhvc3QxEDAOBgkqhkiG9w0BCQEWAS4wggIi
MA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDi2I5Ew61Lfbz9ZfYTrtI4Zln/
hwnCf0umd+z4JzZe7IPpnCmFVk+cVMNGgCOLNsBvJCqlXI4xKu+4xtSGP1uG9T/G
NsMURD0M6BP/wTzydPBTqhIkxI9IwGS9l9qOAbQGcfX+1hKB3F1KoQ/blp5HIfim
MlHPmwE2V6GRT5TCOZ7rB3fj48bSSCVND52D1z9DkfnTHiWBNehg1RLGaxv13lud
20DKmKMZZRuDcx7GfVwCyuXjUQ1kYfWZG2b64eBR8aqshWjH118JrU/EB7FZ0+Td
puc8l+beH8uzTWn0kLUXAGKCsL429ptKi/JmQm4kuV9pJMwf6hWtvfJ6Iz85WnfE
ISJ5gQe5WkIZALhDOjOUDKI85p9lNalU12yulDwHj403WukabZFC8QoLp1HU/l0o
YebgfW/o/uDOkCk4N+nN/rkm0F25KN+qMMV2muZgXCOyRi75SYtbXAhWxbSwJDdj
PhQ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r
3hZ66Qvn/zNMwRkuIEbB0I7k5nNiISA=
-----END PRIVATE KEY-----

View File

@@ -0,0 +1,13 @@
{
"Servers": {
"1": {
"Name": "am-d-model-data-repository-db",
"Group": "Servers",
"Host": "am-d-model-data-repository-db-1",
"Port": 5432,
"MaintenanceDB": "postgres",
"Username": "am-d-model-data-repository",
"SSLMode": "prefer"
}
}
}

View File

@@ -0,0 +1,13 @@
[uwsgi]
socket = 0.0.0.0:5000
stats = 0.0.0.0:9001
module = invenio_app.wsgi_rest:application
master = true
die-on-term = true
processes = 2
threads = 2
mount = /api=invenio_app.wsgi_rest:application
manage-script-name = true
wsgi-disable-file-wrapper = true
single-interpreter = true
buffer-size = 8192

11
docker/uwsgi/uwsgi_ui.ini Normal file
View File

@@ -0,0 +1,11 @@
[uwsgi]
socket = 0.0.0.0:5000
stats = 0.0.0.0:9000
module = invenio_app.wsgi_ui:application
master = true
die-on-term = true
processes = 2
threads = 2
single-interpreter = true
buffer-size = 8192
wsgi-disable-file-wrapper = true

231
invenio.cfg Normal file
View File

@@ -0,0 +1,231 @@
"""
InvenioRDM settings for AM-D-Model Data Repository project.
This file was automatically generated by 'invenio-cli init'.
For the full list of settings and their values, see
https://inveniordm.docs.cern.ch/reference/configuration/.
"""
from datetime import datetime
from invenio_i18n import lazy_gettext as _
def _(x): # needed to avoid start time failure with lazy strings
return x
# Custom function and constant to manage secrets more easily
def read_secrets():
import tomli
with open("secrets.toml", "rb") as f:
return tomli.load(f)
SECRETS = read_secrets()
# Flask
# =====
# See https://flask.palletsprojects.com/en/1.1.x/config/
# Define the value of the cache control header `max-age` returned by the server when serving
# public files. Files will be cached by the browser for the provided number of seconds.
# See flask documentation for more information:
# https://flask.palletsprojects.com/en/2.1.x/config/#SEND_FILE_MAX_AGE_DEFAULT
SEND_FILE_MAX_AGE_DEFAULT = 300
# SECURITY WARNING: keep the secret key used in production secret!
# Do not commit it to a source code repository.
# TODO: Set
SECRET_KEY=SECRETS["SECRET_KEY"]
# Since HAProxy and Nginx route all requests no matter the host header
# provided, the allowed hosts variable is set to localhost. In production it
# should be set to the correct host and it is strongly recommended to only
# route correct hosts to the application.
APP_ALLOWED_HOSTS = ['0.0.0.0', 'localhost', '127.0.0.1', 'am-d-modeleu-caddy-1']
# Flask-SQLAlchemy
# ================
# See https://flask-sqlalchemy.palletsprojects.com/en/2.x/config/
# TODO: Set
SQLALCHEMY_DATABASE_URI="postgresql+psycopg2://am-d-model-data-repository:am-d-model-data-repository@localhost/am-d-model-data-repository"
# Invenio-App
# ===========
# See https://invenio-app.readthedocs.io/en/latest/configuration.html
APP_DEFAULT_SECURE_HEADERS = {
'content_security_policy': {
'default-src': [
"'self'",
'data:', # for fonts
"'unsafe-inline'", # for inline scripts and styles
"blob:", # for pdf preview
# Add your own policies here (e.g. analytics)
],
},
'content_security_policy_report_only': False,
'content_security_policy_report_uri': None,
'force_file_save': False,
'force_https': True,
'force_https_permanent': False,
'frame_options': 'sameorigin',
'frame_options_allow_from': None,
'session_cookie_http_only': True,
'session_cookie_secure': True,
'strict_transport_security': True,
'strict_transport_security_include_subdomains': True,
'strict_transport_security_max_age': 31556926, # One year in seconds
'strict_transport_security_preload': False,
}
# Flask-Babel
# ===========
# See https://python-babel.github.io/flask-babel/#configuration
# Default locale (language)
BABEL_DEFAULT_LOCALE = 'en_IE'
# Default time zone
BABEL_DEFAULT_TIMEZONE = 'Europe/Dublin'
# Invenio-I18N
# ============
# See https://invenio-i18n.readthedocs.io/en/latest/configuration.html
# Other supported languages (do not include BABEL_DEFAULT_LOCALE in list).
I18N_LANGUAGES = [
('de', _('German')),
('fr', _('French')),
('es', _('Spanish')),
('it', _('Italian')),
# ('tr', _('Turkish')),
]
# Invenio-Theme
# =============
# See https://invenio-theme.readthedocs.io/en/latest/configuration.html
# Name used in header and UI
THEME_SITENAME = "AM-D-Model Data Repository"
# Frontpage title
THEME_FRONTPAGE_TITLE = "AM-D-Model Data Repository"
# Header logo
THEME_LOGO = 'images/invenio-rdm.svg'
# Invenio-App-RDM
# ===============
# See https://github.com/inveniosoftware/invenio-app-rdm/blob/master/invenio_app_rdm/config.py
# Instance's theme entrypoint file. Path relative to the ``assets/`` folder.
INSTANCE_THEME_FILE = './less/theme.less'
# Email address for administrator emails (like file checksum alerts)
APP_RDM_ADMIN_EMAIL_RECIPIENT = "repo@am-d-model.eu"
# Default values for the deposit form
APP_RDM_DEPOSIT_FORM_DEFAULTS = {
"publication_date": lambda: datetime.now().strftime("%Y-%m-%d"),
"rights": [
{
"id": "cc-by-4.0",
"title": "Creative Commons Attribution 4.0 International",
"description": ("The Creative Commons Attribution license allows "
"re-distribution and re-use of a licensed work "
"on the condition that the creator is "
"appropriately credited."),
"link": "https://creativecommons.org/licenses/by/4.0/legalcode",
}
],
"publisher": "AM-D-Model Data Repository",
}
APP_RDM_DEPOSIT_FORM_AUTOCOMPLETE_NAMES = 'search' # "search_only" or "off"
# Invenio-Files-Rest
# ==================
FILES_REST_STORAGE_FACTORY='invenio_s3.s3fs_storage_factory'
# Invenio-S3
# ==========
S3_ENDPOINT_URL='http://localhost:9000/'
S3_ACCESS_KEY_ID='CHANGE_ME'
S3_SECRET_ACCESS_KEY='CHANGE_ME'
# Allow S3 endpoint in the CSP rules
APP_DEFAULT_SECURE_HEADERS['content_security_policy']['default-src'].append(
S3_ENDPOINT_URL
)
# Invenio-Records-Resources
# =========================
# See https://github.com/inveniosoftware/invenio-records-resources/blob/master/invenio_records_resources/config.py
# TODO: Set with your own hostname when deploying to production
SITE_UI_URL = "https://am-d-model.eu/repo"
SITE_API_URL = "https://am-d-model.eu/repo/api"
# Invenio-RDM-Records
# ===================
# See https://inveniordm.docs.cern.ch/customize/dois/
DATACITE_ENABLED = False
DATACITE_USERNAME = ""
DATACITE_PASSWORD = ""
DATACITE_PREFIX = ""
DATACITE_TEST_MODE = True
DATACITE_DATACENTER_SYMBOL = ""
# Authentication - Invenio-Accounts and Invenio-OAuthclient
# =========================================================
# See: https://inveniordm.docs.cern.ch/customize/authentication/
# Invenio-Accounts
# ----------------
# See https://github.com/inveniosoftware/invenio-accounts/blob/master/invenio_accounts/config.py
ACCOUNTS_LOCAL_LOGIN_ENABLED = True # enable local login
SECURITY_REGISTERABLE = True # local login: allow users to register
SECURITY_RECOVERABLE = True # local login: allow users to reset the password
SECURITY_CHANGEABLE = True # local login: allow users to change psw
SECURITY_CONFIRMABLE = True # local login: users can confirm e-mail address
SECURITY_LOGIN_WITHOUT_CONFIRMATION = False # require users to confirm email before being able to login
# Invenio-OAuthclient
# -------------------
# See https://github.com/inveniosoftware/invenio-oauthclient/blob/master/invenio_oauthclient/config.py
OAUTHCLIENT_REMOTE_APPS = {} # configure external login providers
from invenio_oauthclient.views.client import auto_redirect_login
ACCOUNTS_LOGIN_VIEW_FUNCTION = auto_redirect_login # autoredirect to external login if enabled
OAUTHCLIENT_AUTO_REDIRECT_TO_EXTERNAL_LOGIN = False # autoredirect to external login
# Invenio-UserProfiles
# --------------------
USERPROFILES_READ_ONLY = False # allow users to change profile info (name, email, etc...)
# OAI-PMH
# =======
# See https://github.com/inveniosoftware/invenio-oaiserver/blob/master/invenio_oaiserver/config.py
OAISERVER_ID_PREFIX = "am-d-model.eu"
"""The prefix that will be applied to the generated OAI-PMH ids."""
OAISERVER_ADMIN_EMAILS = [
"repo@am-d-model.eu",
]
# Invenio-Search
# --------------
SEARCH_INDEX_PREFIX = "am-d-model-data-repository-"
# Invenio-Users-Resources
# -----------------------
USERS_RESOURCES_ADMINISTRATION_ENABLED = True
"""Enable the user administration"""

1
site/.gitkeep Normal file
View File

@@ -0,0 +1 @@
# This file exists only to add am_d_model_data_repository/ folder to git repository.

View File

@@ -0,0 +1 @@
# This file exists only to add js/ folder to git repository.

View File

@@ -0,0 +1 @@
# This file exists only to add less/ folder to git repository.

View File

@@ -0,0 +1 @@
# This file exists only to add templates/ folder to git repository.

View File

@@ -0,0 +1,17 @@
"""Additional views."""
from flask import Blueprint
#
# Registration
#
def create_blueprint(app):
"""Register blueprint routes on app."""
blueprint = Blueprint(
"am_d_model_data_repository",
__name__,
template_folder="./templates",
)
# Add URL rules
return blueprint

View File

@@ -0,0 +1,16 @@
"""JS/CSS Webpack bundles for AM-D-Model Data Repository."""
from invenio_assets.webpack import WebpackThemeBundle
theme = WebpackThemeBundle(
__name__,
"assets",
default="semantic-ui",
themes={
"semantic-ui": dict(
entry={
# Add your webpack entrypoints
},
),
},
)

3
site/pyproject.toml Normal file
View File

@@ -0,0 +1,3 @@
[build-system]
requires = ["setuptools", "wheel", "babel>2.8"]
build-backend = "setuptools.build_meta"

13
site/setup.cfg Normal file
View File

@@ -0,0 +1,13 @@
[metadata]
name = am-d-model-data-repository
[options.extras_require]
tests =
pytest-invenio>=2.1.0,<3.0.0
[options.entry_points]
invenio_base.blueprints =
am_d_model_data_repository_views = am_d_model_data_repository.views:create_blueprint
invenio_assets.webpack =
am_d_model_data_repository_theme = am_d_model_data_repository.webpack:theme

3
site/setup.py Normal file
View File

@@ -0,0 +1,3 @@
from setuptools import setup
setup()

1
site/tests/.gitkeep Normal file
View File

@@ -0,0 +1 @@
# This file exists only to add templates/ folder to git repository.

View File

@@ -0,0 +1,45 @@
<?xml version="1.0" encoding="utf-8"?>
<svg viewBox="683.385 263.073 71.61 17.206" xmlns="http://www.w3.org/2000/svg">
<defs>
<clipPath clipPathUnits="userSpaceOnUse" id="clipPath150">
<rect style="fill:none" id="rect152" width="89.156677" height="26.135302" x="26.392477" y="51.413708"/>
</clipPath>
<clipPath clipPathUnits="userSpaceOnUse" id="clipPath146">
<rect style="fill:none;stroke-width:1.91481" id="rect148" width="178.04289" height="47.98505" x="-1109.9677" y="-174.10544"/>
</clipPath>
<clipPath clipPathUnits="userSpaceOnUse" id="clipPath142">
<rect style="fill:none" id="rect144" width="92.982246" height="25.060017" x="27.524937" y="49.298393"/>
</clipPath>
<clipPath clipPathUnits="userSpaceOnUse" id="clipPath138">
<rect style="fill:none" id="rect140" width="92.982246" height="25.060017" x="27.524937" y="49.298393"/>
</clipPath>
<clipPath clipPathUnits="userSpaceOnUse" id="clipPath134">
<rect style="fill:none" id="rect136" width="92.982246" height="25.060017" x="27.524937" y="49.298393"/>
</clipPath>
</defs>
<g transform="matrix(1, 0, 0, 1, 644.704163, 211.397293)" style="display:inline" id="g5138">
<g aria-label="RDM" transform="scale(1.0429084,0.95885698)" id="text5106" clip-path="url(#clipPath150)" style="font-style:normal;font-variant:normal;font-weight:bold;font-stretch:condensed;font-size:18.1003px;line-height:1.25;font-family:'DIN Condensed';-inkscape-font-specification:'DIN Condensed, Bold Condensed';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#fb8273;fill-opacity:1;stroke:none;stroke-width:3.66485;stroke-miterlimit:4;stroke-dasharray:none">
<path d="M 83.86 57.784 L 83.86 61.802 L 84.909 61.802 C 85.235 61.802 85.495 61.76 85.688 61.675 C 85.881 61.579 86.032 61.446 86.14 61.277 C 86.237 61.108 86.303 60.903 86.339 60.662 C 86.375 60.408 86.394 60.119 86.394 59.793 C 86.394 59.467 86.375 59.184 86.339 58.942 C 86.303 58.689 86.231 58.472 86.122 58.291 C 85.893 57.953 85.458 57.784 84.819 57.784 L 83.86 57.784 Z M 82.013 68.934 L 82.013 56.046 L 84.982 56.046 C 87.154 56.046 88.24 57.307 88.24 59.829 C 88.24 60.589 88.119 61.235 87.878 61.766 C 87.649 62.297 87.238 62.725 86.647 63.051 L 88.638 68.934 L 86.683 68.934 L 84.964 63.431 L 83.86 63.431 L 83.86 68.934 L 82.013 68.934 Z" style="stroke-width:3.66485" id="path154"/>
<path d="M 89.72 68.934 L 89.72 56.046 L 92.453 56.046 C 93.515 56.046 94.318 56.336 94.861 56.915 C 95.416 57.494 95.693 58.315 95.693 59.377 L 95.693 65.404 C 95.693 66.611 95.398 67.504 94.806 68.083 C 94.227 68.65 93.388 68.934 92.29 68.934 L 89.72 68.934 Z M 91.566 57.784 L 91.566 67.196 L 92.417 67.196 C 92.936 67.196 93.304 67.069 93.521 66.816 C 93.738 66.55 93.847 66.14 93.847 65.585 L 93.847 59.377 C 93.847 58.87 93.744 58.478 93.539 58.2 C 93.334 57.923 92.96 57.784 92.417 57.784 L 91.566 57.784 Z" style="stroke-width:3.66485" id="path156"/>
<path d="M 97.427 68.934 L 97.427 56.046 L 99.201 56.046 L 101.572 62.87 L 101.608 62.87 L 103.961 56.046 L 105.753 56.046 L 105.753 68.934 L 103.907 68.934 L 103.907 61.096 L 103.871 61.096 L 102.042 66.635 L 101.119 66.635 L 99.309 61.096 L 99.273 61.096 L 99.273 68.934 L 97.427 68.934 Z" style="stroke-width:3.66485" id="path158"/>
</g>
<g style="display:inline" transform="matrix(0.52224634,0,0,0.52224634,607.20148,140.22432)" id="layer1-0" clip-path="url(#clipPath146)">
<g transform="matrix(0.238125,0,0,0.238125,-1173.8821,-166.25235)" style="display:inline" id="g25963-9">
<path id="rect25941-7" style="fill:#ffffff" d="M 358.114 36.556 L 372.162 36.556 L 372.162 100.8 L 358.114 100.8 L 358.114 36.556 Z"/>
<path style="fill:#ffffff" id="path25943-1" d="M 686.276 33.005 C 667.509 33.005 652.244 48.273 652.244 67.039 C 652.244 74.319 654.55 81.067 658.458 86.607 L 628.38 113.039 C 626.499 114.917 628.447 119.906 630.324 121.788 C 632.203 123.664 637.194 125.61 639.072 123.731 L 665.337 93.837 C 671.116 98.362 678.384 101.07 686.276 101.07 C 705.044 101.07 720.31 85.803 720.31 67.038 C 720.31 48.273 705.044 33.005 686.276 33.005 Z M 686.276 89.727 C 673.766 89.727 663.587 79.55 663.587 67.039 C 663.587 54.528 673.767 44.349 686.276 44.349 C 698.789 44.349 708.964 54.529 708.964 67.039 C 708.964 79.549 698.789 89.727 686.276 89.727 Z"/>
<path transform="translate(358.11441,28.33968)" id="polygon25947-7" style="fill:#ffffff" d="M 113.62 36.814 L 125.814 8.325 L 140.814 8.325 L 113.512 72.427 L 86.21 8.433 L 101.318 8.433 L 113.62 36.814 Z"/>
<path transform="translate(358.11441,28.33968)" id="polygon25949-4" style="fill:#ffffff" d="M 218.848 72.318 L 218.848 43.075 L 254.537 74.124 L 254.537 7.961 L 239.34 7.961 L 239.34 36.974 L 203.65 8.076 L 203.65 72.318 L 218.848 72.318 Z"/>
<path transform="translate(358.11441,28.33968)" id="polygon25951-5" style="fill:#ffffff" d="M 78.537 8.127 L 63.34 8.127 L 63.34 37.14 L 27.65 8.242 L 27.65 72.484 L 42.848 72.484 L 42.848 43.241 L 78.537 74.29 L 78.537 8.127 Z"/>
<path id="rect25953-17" style="fill:#ffffff" d="M 626.114 35.39 L 640.163 35.39 L 640.163 99.633 L 626.114 99.633 L 626.114 35.39 Z"/>
<path transform="translate(358.11441,28.33968)" id="polygon25955-8" style="fill:#ffffff" d="M 193.649 72.079 L 193.649 59.346 L 166.976 59.346 L 166.976 45.624 L 191.783 45.624 L 191.783 32.672 L 166.976 32.672 L 166.976 20.927 L 192.991 20.927 L 192.991 7.974 L 149.193 7.974 L 149.193 72.079 L 193.649 72.079 Z"/>
<g id="g25961-2" transform="matrix(0.38742049,0,0,0.38742049,554.83512,53.02433)">
<path d="M 375.104 38.079 C 375.278 56.263 366.981 70.205 363.594 75.599 C 371.777 70.252 383.492 56.239 383.268 37.938 C 383.442 19.755 371.837 5.811 363.637 0.418 C 366.96 5.765 375.328 19.778 375.104 38.079 Z" id="path25957-5" style="fill:#ffffff"/>
<path d="M 375.104 38.079 C 375.278 56.263 366.981 70.205 363.594 75.599 C 371.777 70.252 383.492 56.239 383.268 37.938 C 383.442 19.755 371.837 5.811 363.637 0.418 C 366.96 5.765 375.328 19.778 375.104 38.079 Z" id="path25959-4" style="fill:none;stroke:#ffffff"/>
</g>
</g>
</g>
<path id="rect122" clip-path="url(#clipPath142)" style="fill:none;fill-rule:evenodd" d="M 39.317 56.478 L 106.911 51.676 L 108.712 66.345 L 40.517 64.544 L 39.317 56.478 Z"/>
<path id="rect126" style="fill:none" d="M 49.04 62.641 L 50.24 61.259 L 108.849 63.06 L 107.048 57.839 L 49.04 62.641 Z" clip-path="url(#clipPath138)"/>
<path id="rect130" clip-path="url(#clipPath134)" style="fill:none" d="M 48.903 60.997 L 101.707 56.195 L 103.508 62.511 L 50.103 60.71 L 48.903 60.997 Z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 6.7 KiB

View File

@@ -0,0 +1,129 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="86.247925mm"
height="21.786226mm"
viewBox="0 0 86.247925 21.786226"
version="1.1"
id="svg19281"
inkscape:version="0.92.2 5c3e80d, 2017-08-06"
sodipodi:docname="invenio-logo-white-new.svg">
<defs
id="defs19275" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="8.8165889"
inkscape:cx="162.9882"
inkscape:cy="41.170821"
inkscape:document-units="mm"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:pagecheckerboard="true"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:window-width="3440"
inkscape:window-height="1395"
inkscape:window-x="0"
inkscape:window-y="1"
inkscape:window-maximized="1" />
<metadata
id="metadata19278">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(1088.6061,158.39311)">
<a
transform="matrix(0.26458333,0,0,0.26458333,-1186.9384,-166.74773)"
style="display:inline"
id="a4998">
<g
transform="matrix(0.9,0,0,0.9,49.346774,1.872297)"
style="display:inline"
id="g25963">
<rect
y="36.555683"
width="14.048"
height="64.244003"
id="rect25941"
x="358.11441"
style="fill:#ffffff" />
<g
transform="translate(358.11441,28.33968)"
id="g25945">
<path
inkscape:connector-curvature="0"
d="m 328.162,4.665 c -18.767,0 -34.032,15.268 -34.032,34.034 0,7.28 2.306,14.028 6.214,19.568 l -30.078,26.432 c -1.881,1.878 0.067,6.867 1.944,8.749 1.879,1.876 6.87,3.822 8.748,1.943 l 26.265,-29.894 c 5.779,4.525 13.047,7.233 20.939,7.233 18.768,0 34.034,-15.267 34.034,-34.032 0,-18.765 -15.266,-34.033 -34.034,-34.033 z m 0,56.722 c -12.51,0 -22.689,-10.177 -22.689,-22.688 0,-12.511 10.18,-22.69 22.689,-22.69 12.513,0 22.688,10.18 22.688,22.69 0,12.51 -10.175,22.688 -22.688,22.688 z"
id="path25943"
style="fill:#ffffff" />
</g>
<polygon
points="125.814,8.325 140.814,8.325 113.512,72.427 86.21,8.433 101.318,8.433 113.62,36.814 "
id="polygon25947"
style="fill:#ffffff"
transform="translate(358.11441,28.33968)" />
<polygon
points="239.34,36.974 203.65,8.076 203.65,72.318 218.848,72.318 218.848,43.075 254.537,74.124 254.537,7.961 239.34,7.961 "
id="polygon25949"
style="fill:#ffffff"
transform="translate(358.11441,28.33968)" />
<polygon
points="42.848,72.484 42.848,43.241 78.537,74.29 78.537,8.127 63.34,8.127 63.34,37.14 27.65,8.242 27.65,72.484 "
id="polygon25951"
style="fill:#ffffff"
transform="translate(358.11441,28.33968)" />
<rect
x="626.11444"
y="35.389698"
width="14.049"
height="64.242996"
id="rect25953"
style="fill:#ffffff" />
<polygon
points="193.649,59.346 166.976,59.346 166.976,45.624 191.783,45.624 191.783,32.672 166.976,32.672 166.976,20.927 192.991,20.927 192.991,7.974 149.193,7.974 149.193,72.079 193.649,72.079 "
id="polygon25955"
style="fill:#ffffff"
transform="translate(358.11441,28.33968)" />
<g
id="g25961"
transform="matrix(0.38742049,0,0,0.38742049,554.83512,53.02433)">
<path
inkscape:connector-curvature="0"
d="m 375.104,38.079 c 0.174,18.184 -8.123,32.126 -11.51,37.52 8.183,-5.347 19.898,-19.36 19.674,-37.661 0.174,-18.183 -11.431,-32.127 -19.631,-37.52 3.323,5.347 11.691,19.36 11.467,37.661 z"
id="path25957"
style="fill:#ffffff" />
<path
inkscape:connector-curvature="0"
d="m 375.104,38.079 c 0.174,18.184 -8.123,32.126 -11.51,37.52 8.183,-5.347 19.898,-19.36 19.674,-37.661 0.174,-18.183 -11.431,-32.127 -19.631,-37.52 3.323,5.347 11.691,19.36 11.467,37.661 z"
id="path25959"
style="fill:none;stroke:#ffffff" />
</g>
</g>
</a>
</g>
</svg>

After

Width:  |  Height:  |  Size: 5.0 KiB

5
static/robots.txt Normal file
View File

@@ -0,0 +1,5 @@
User-agent: *
Disallow: /search
Disallow: /api
Disallow: /administration
Crawl-delay: 10

1
templates/.gitkeep Normal file
View File

@@ -0,0 +1 @@
# This file exists only to add templates/ folder to git repository.

12
translations/babel.ini Normal file
View File

@@ -0,0 +1,12 @@
# This file is required to allow string extraction for translations.
# Extraction from Python source files
[python: **.py]
encoding = utf-8
# Extraction from Python config files
[python: **.cfg]
encoding = utf-8
# Extraction from Jinja2 templates
[jinja2: **/templates/**.html]
encoding = utf-8