Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inclui novas variáveis de ambiente. #196

Merged
merged 20 commits into from
Dec 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
c71c32a
Muda descricao de OPAC_CACHE_ENABLED
samuelveigarangel Oct 14, 2024
1ec1cd0
Muda nome de arquivo de monitoramento para um nome mais generico
samuelveigarangel Oct 14, 2024
b51f7f6
Inclui variaveis faltantes
samuelveigarangel Oct 14, 2024
fd17533
Merge branch 'master' into issue-184
samuelveigarangel Nov 7, 2024
ff66c41
Adiciona novas variaveis de ambiente conforme default.py
samuelveigarangel Nov 11, 2024
353ea54
Insere variaveis removidas
samuelveigarangel Nov 11, 2024
e4340c1
Insere novos caminhos dos arquivos de variavel de ambiente
samuelveigarangel Nov 11, 2024
29bd2e4
Volta com os caminhos antigos das variaveis de ambiente
samuelveigarangel Nov 13, 2024
a35636c
Inclui variaveis de ambiente em THUMBNAIL_HEIGHT e THUMBNAIL_WIDTH
samuelveigarangel Nov 13, 2024
49f5a7c
Adiciona novas variaveis de ambiente
samuelveigarangel Nov 13, 2024
a19056f
Adiciona novos caminhos de arquivos de variavel de ambiente aos servi…
samuelveigarangel Nov 13, 2024
10350c2
Move variaves de social-media para .flask
samuelveigarangel Nov 26, 2024
45fe2a1
remove OPAC_FORCE_USE_HTTPS_GOOGLE_TAGS
samuelveigarangel Nov 26, 2024
1e366ef
Atribui valor em OPAC_SESSION_COOKIE_DOMAIN
samuelveigarangel Nov 26, 2024
561dec8
Set value for opac_mongodb_host
samuelveigarangel Nov 26, 2024
5709d5c
Remove value for opac_server_name e OPAC_SESSION_COOKIE_DOMAIN
samuelveigarangel Nov 26, 2024
1f1f66f
Remove OPAC_SEND_FILE_MAX_AGE_DEFAULT e OPAC_CACHE_CONTROL_MAX_AGE_HE…
samuelveigarangel Nov 26, 2024
8269e1f
Remove None de user e pass
samuelveigarangel Nov 26, 2024
7df7246
Update
samuelveigarangel Nov 26, 2024
dadc97c
Inclui novas variaveis
samuelveigarangel Dec 10, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .envs/.production-template/.db-sqlite
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# ------------------------ Banco SQL ------------------------
# ------------------------------------------------------------
# File name (sqlite) (default: 'opac.sqlite')
OPAC_DATABASE_FILE=opac.sqlite

# Folder where the database is located (sqlite) (default: '/tmp')
OPAC_DATABASE_DIR=/tmp

# [optional] SQL database URI (default: 'sqlite:////tmp/opac.sqlite')
OPAC_DATABASE_URI=sqlite:////tmp/opac.sqlite
188 changes: 180 additions & 8 deletions .envs/.production-template/.flask
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# -------------- OPAC Application configuration --------------
# ------------------------------------------------------------
# Possible values: True or False
# enables/disables the app's Debug mode. Possible values: True or False
OPAC_DEBUG_MODE=False

# Possible values: WARNING, INFO, ERROR, CRITICAL AND DEBUG
Expand All @@ -9,25 +9,48 @@ OPAC_LOG_LEVEL=WARNING
# Possible values: True or False
OPAC_MINIFY_PAGE=False

# Name for MongoDB. Ex: opac
OPAC_MONGODB_NAME=opac

# Path to directory app. Ex: /app/data
OPAC_DATABASE_DIR=/app/data

# Value for key. Ex: nmN73pR6
OPAC_SECRET_KEY=NWhWFn_ScpW6YR9yJKDLxg

# Name for MongoDB host
OPAC_MONGODB_HOST=opac_mongo

# Activate/Desactivate the cache of redis (default: True)
OPAC_CACHE_ENABLED=False

# Interface languages
OPAC_LANGUAGES="{'pt_BR': 'Português','en': 'English','es': 'Español'}"

ALERT_MSG_PT=
ALERT_MSG_EN=
ALERT_MSG_ES=

ACCESSIBILITY_FORM_PT=https://forms.gle/2Vpt2z26uGqHA7yy5
ACCESSIBILITY_FORM_EN=https://forms.gle/qHwovmddXdZRDxjm7
ACCESSIBILITY_FORM_ES=https://forms.gle/XZuJurSVMBp4E64j6

# enables/disables the presentation of collection metrics data (default: False). Possible values: True or False
OPAC_USE_HOME_METRICS=False

# Acronym Collection. Consult: https://articlemeta.scielo.org/api/v1/collection/identifiers/
OPAC_COLLECTION=

# Application version. Ex: v0.1.0
OPAC_WEBAPP_VERSION=

# LOCALZONE
# Default 'America/Sao_Paulo'. Consult: https://gist.github.com/heyalexej/8bf688fd67d7199be4a1682b3eec7568
LOCAL_ZONE=

# ORCID URL. default: http://orcid.org/
OPAC_ORCID_URL=http://orcid.org/

PREVIOUS_WEBSITE_URI=

HTML_GENERATOR_VERSION="3.0"

OPAC_PINGDOM_VISITOR_INSIGHTS_JS_SRC=
# -------------------- Journal path -------------------
# ------------------------------------------------------------

Expand All @@ -44,9 +67,11 @@ OPAC_JOURNAL_IMAGES_SOURCE_PATH=/app/data/img
OPAC_SSM_SCHEME=http
OPAC_SSM_DOMAIN=minio
OPAC_SSM_PORT=9000
OPAC_SSM_MEDIA_PATH=/media/assets/
OPAC_SSM_XML_URL_REWRITE=False

# ----------------- Table of contents sections ---------------------
# ------------------------------------------------------------
# -------------- Table of contents sections -----------------
# -----------------------------------------------------------

# This variable active/desactivate the sections on table of contents
# Possible values: True or False
Expand All @@ -55,3 +80,150 @@ OPAC_FILTER_SECTION_ENABLE=True
# This variable define a mininal count of study ares on the head of journal page
OPAC_FILTER_SECTION_ENABLE_FOR_MIN_STUDY_AREAS=5


# ------------------- Sending emails --------------------
# -------------------------------------------------------

# Email account for sending messages from the website
OPAC_DEFAULT_EMAIL=None

# mail server host (default: localhost)
OPAC_MAIL_SERVER=localhost

# Serve port email
OPAC_MAIL_PORT=1025

# enable/disable sending email with TLS
OPAC_MAIL_USE_TLS=False

# enable/disable sending email with SSL
OPAC_MAIL_USE_SSL=False


# ------------------ Google reCAPTCHA ------------------
# ------------------------------------------------------

# Google reCAPTCHA secret key, used by the backend to validate tokens sent by the client. Ex: 6L***********G7k7************F
OPAC_GOOGLE_RECAPTCHA_SECRET_KEY=

# Google reCAPTCHA public key used by the frontend to generate and send the reCAPTCHA token to the backend. (Ex: 6L***********9Tk************K)
OPAC_GOOGLE_VERIFY_RECAPTCHA_KEY=

# Google reCAPTCHA JavaScript URL. (default: //www.google.com/recaptcha/api.js)
OPAC_GOOGLE_RECAPTCHA_URL=//www.google.com/recaptcha/api.js

# URL de verificação do google (default: https://www.google.com/recaptcha/api/siteverify)
OPAC_GOOGLE_VERIFY_RECAPTCHA_URL=https://www.google.com/recaptcha/api/siteverify

# --------------------- Google ------------------------
# ------------------------------------------------------
OPAC_GOOGLE_SCHOLAR=https://scholar.google.com/scholar?q=
OPAC_GOOGLE=https://www.google.com/search?q=

# ------------------ Error form ------------------------
# ------------------------------------------------------

# Email accounts to receive interface error messages.
OPAC_EMAIL_ACCOUNTS_RECEIVE_ERRORS=

# --------------------- CRSF ---------------------------
# ------------------------------------------------------

# enables/disables CSRF feature (default: True)
OPAC_WTF_CSRF_ENABLED=True

# key to security in WTF forms. (default: JGvNWiwBIq2Iig89LWbV)
OPAC_WTF_CSRF_SECRET_KEY=JGvNWiwBIq2Iig89LWbV

# Forces the use of https in URLs for the OPAC website in Google tags. (default: True)
OPAC_FORCE_USE_HTTPS_GOOGLE_TAGS=True
OPAC_READCUBE_ENABLED=False
# --------------------- Links SciELO -------------------
# ------------------------------------------------------
# URL for SciELO.org (default: '//www.scielo.org')
URL_SCIELO_ORG=//www.scielo.org

# URIs in SciELO.org for specific sessions
SCIELO_ORG_URIS=

# URL for the SciELO in Perspective Blog. (default: '//blog.scielo.org')
URL_BLOG_SCIELO=//blog.scielo.org

# URL for Search SciELO. (default: '//search.scielo.org/')
URL_SEARCH=//search.scielo.org/

# URL for the SciELO in Perspective Blog Press releases. (default: '//pressreleases.scielo.org')
URL_BLOG_PRESSRELEASE=//pressreleases.scielo.org

# ----------------- Google Analytics -------------------
# ------------------------------------------------------
# google analytics code (go to https://goo.gl/HE77SO to redeem your code)
GA_TRACKING_CODE=

# ----------------- Upload Images -------------------
# ---------------------------------------------------
# Absolute path of the folder that will store the images uploaded by users through the admin.
# (default: /[repo dir]/opac/opac/webapp/media/)
OPAC_MEDIA_ROOT=

# URL to serve images. (default: '/media')
OPAC_MEDIA_URL=/media

# ------------------ Extensions ---------------------
# ---------------------------------------------------
# Thumbnail height (default: 100)
THUMBNAIL_HEIGHT=100

# Thumbnail width (default: 100)
THUMBNAIL_WIDTH=100

# -------------- Common Style List ---------------------
# ------------------------------------------------------
# Path to a .json file with the CSL.
OPAC_COMMON_STYLE_LIST=


# ------------------- Site License ---------------------
# ------------------------------------------------------
# Enables/disables the display of the creative commons logo in the website footer
OPAC_SITE_LICENSE_ENABLE=True

# License Name (default: "Creative Common - by 4.0")
OPAC_SITE_LICENSE_NAME="Creative Common - by 4.0"

# License Url (default: https://creativecommons.org/licenses/by-nc/4.0/)
OPAC_SITE_LICENSE_URL=https://creativecommons.org/licenses/by-nc/4.0/

# License Image (default: https://licensebuttons.net/l/by/4.0/88x31.png)
OPAC_SITE_LICENSE_IMG_URL=https://licensebuttons.net/l/by/4.0/88x31.png


# -------------------- Twitter ----------------------
# ---------------------------------------------------
# Twitter comuser key (default: 'consum3r-k3y')
OPAC_TWITTER_CONSUMER_KEY=

# Twitter comuser secret (default: 'consum3r-secr3t')
OPAC_TWITTER_CONSUMER_SECRET=

# Twitter access token (default: 'acc3ss-tok3n-secr3t')
OPAC_TWITTER_ACCESS_TOKEN=
# Twitter access token (default: 'acc3ss-tok3n-secr3t')
OPAC_TWITTER_ACCESS_TOKEN_SECRET=

# Twitter screen name (default: 'RedeSciELO')
OPAC_TWITTER_SCREEN_NAME=

# -------------------- SCIMAGO ----------------------
# ---------------------------------------------------
SCIMAGO_URL=https://www.scimagojr.com/journalsearch.php?tip=sid&clean=0&q=

SCIMAGO_ENABLED=True

# SCImago Institutions Ranking(IR)
SCIMAGO_URL_IR=https://www.scimagoir.com/

# -------------------- MathJax ----------------------
# ---------------------------------------------------
# string with the default mathjax URL; ex: "https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/latest.js?config=TeX-AMS-MML_HTMLorMML"
OPAC_MATHJAX_CDN_URL=https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/latest.js?config=TeX-AMS-MML_HTMLorMML
10 changes: 10 additions & 0 deletions .envs/.production-template/.metrics
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,19 @@ OPAC_DIMENSIONS_URL=https://badge.dimensions.ai/details/doi
# Enable PlumX metrics
# Possible values: True or False
OPAC_USE_PLUMX=True
# URL to PlumX (default: https://plu.mx/a)
OPAC_PLUMX_METRICS_URL=https://plu.mx/scielo/a

# Enable Altmetric metrics
# Possible values: True or False
OPAC_USE_ALTMETRIC=True
# Url PlumX
OPAC_ALTMETRIC_METRICS_URL=https://www.altmetric.com/details.php
# Url to JS PlumX. (default: //cdn.plu.mx/widget-popup.js)
OPAC_PLUMX_METRICS_JS=//cdn.plu.mx/widget-popup.js

# Enable SCITE
OPAC_USE_SCITE=False
# URL to SCITE_
OPAC_SCITE_URL=
OPAC_SCITE_METRICS_URL=
17 changes: 17 additions & 0 deletions .envs/.production-template/.mongo
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# ------------------- MongoDB Database --------------------
# -------------------------------------------------------

# Name of Database(default: 'opac')
OPAC_MONGODB_NAME=opac

# Host of Database (default: 'localhost')
OPAC_MONGODB_HOST=opac_mongo

# Port of Database(default: 27017)
OPAC_MONGODB_PORT=27017

# # (Optional) user to access the bank (default: None)
OPAC_MONGODB_USER=

# # (Optional) password to access the bank (default: None)
OPAC_MONGODB_PASS=
32 changes: 32 additions & 0 deletions .envs/.production-template/.monitoring
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# ---- APM (Application Performance Monitoring) settings -----
# ------------------------------------------------------------
# True or False
OPAC_APM_ENABLED=False

# Url for APM
OPAC_APM_SERVER_URL=

# Name for Service. Ex. Website
OPAC_APM_SERVICE_NAME=Website

# Type of enviroment. Ex: production or local
OPAC_APM_ENVIRONMENT=production
OPAC_APM_SECRET_TOKEN=
OPAC_APM_SERVER_TIMEOUT=
OPAC_APM_HOSTNAME=
OPAC_APM_COLLECT_LOCAL_VARIABLES=
OPAC_APM_LOCAL_VAR_MAX_LENGTH=
OPAC_APM_CAPTURE_BODY=
OPAC_APM_CAPTURE_HEADERS=
OPAC_APM_TRANSACTION_MAX_SPANS=
OPAC_APM_STACK_TRACE_LIMIT=
OPAC_APM_DEBUG=
OPAC_APM_DISABLE_SEND=
OPAC_APM_INSTRUMENT=
OPAC_APM_APM_VERIFY_SERVER_CERT=

# ------------------------ SENTRY ----------------------------
# ------------------------------------------------------------
# True or False
OPAC_USE_SENTRY=False
OPAC_SENTRY_DSN=
13 changes: 0 additions & 13 deletions .envs/.production-template/.monitoring-apm

This file was deleted.

31 changes: 28 additions & 3 deletions .envs/.production-template/.redis
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,40 @@ OPAC_RQ_REDIS_HOST=redis-cache
# Redis port for cache. Ex: 6379
OPAC_RQ_REDIS_PORT=6379

# # default cron value for sending emails (default: "0 7 * * *")
# OPAC_MAILING_CRON_STRING="0 7 * * *"

# #timeout do screduler cron (dafault: 1000).
# OPAC_DEFAULT_SCHEDULER_TIMEOUT=1000

# --------------------- Cache configuration ------------------
# ------------------------------------------------------------

# True or False
# Activate/Desactivate the cache of redis (default: False)
OPAC_CACHE_ENABLED=True

# Cache timeout (in seconds). Ex: 3600
# Type of cache backend: 'null', 'redis', outros (default: 'redis')
OPAC_CACHE_TYPE=redis

#enables/disables display of warnings when CACHE_TYPE is 'null' (default: True)
OPAC_CACHE_NO_NULL_WARNING=True

# Lifetime of objects in cache (in seconds). Ex: 3600
OPAC_CACHE_DEFAULT_TIMEOUT=3600

# Redis host for cache. Ex: redis-cache
# Cache Key Prefix. (default: 'opac_cache')
OPAC_CACHE_KEY_PREFIX=opac_cache

# Redis host for cache. (default: redis-cache)
OPAC_CACHE_REDIS_HOST=redis-cache

# Redis Port for cache. (default: 6379)
OPAC_CACHE_REDIS_PORT=6379

# Redis server db name that will be used in the cache (integer >= 0). (default: 0)
OPAC_CACHE_REDIS_DB=0

# Password of the redis server that will be used in the cache. (default = '')
OPAC_CACHE_REDIS_PASSWORD=


Loading