Package org.ctan.site
Class CtanConfiguration
java.lang.Object
io.dropwizard.core.Configuration
org.ctan.site.CtanConfiguration
public class CtanConfiguration
extends io.dropwizard.core.Configuration
The class
CtanConfiguration contains the Dropwizard
configuration specific to the CTAN site.
The configuration is externally stored in a yaml file and read at startup.
The configuration might contain references to environment variables. This can
be achieved with a construct like ${VARIABLE}. This takes the
value of VARIABLE from the environment. If the variable might not be defined
then ${VARIABLE:-FALLBACK} can be used to revert to FALLBACK in
this case.
The following example demonstrates the major configuration parameters.
appName: Comprehensive TeX Archive Network
version: 3.0.0
#---------------------------------------------------------------------------
# Server settings.
server:
rootPath: '/api/*'
applicationConnectors:
- type: http
port: 9000
adminConnectors:
- type: http
port: 9001
#---------------------------------------------------------------------------
# CTAN settings.
ctan:
defaultLanguage: en
languages:
- en
- de
#---------------------------------------------------------------------------
# CTAN searching settings.
index:
directory: /serv/www/www.ctan.org/index
#---------------------------------------------------------------------------
# CTAN content settings.
content:
directory: /serv/www/www.ctan.org/src/ctan-content
#---------------------------------------------------------------------------
# CTAN incoming settings.
upload:
addendum: /home/ftp/pub/tex/help/ctan/CTAN-upload-addendum.html
incoming: /serv/www/www.ctan.org/incoming
managers: ctan@ctan.org
#---------------------------------------------------------------------------
# CTAN TeX Catalogue settings.
catalogue:
entries: /serv/www/www.ctan.org/texcatalogue/entries
#---------------------------------------------------------------------------
# CTAN tex-archive settings.
texArchive:
directory: /home/ftp/pub/tex
#---------------------------------------------------------------------------
# CTAN ctan-ann settings.
ctanAnnounce:
directory: /serv/www/www.ctan.org/ctan-ann
#---------------------------------------------------------------------------
# MirrMon settings.
mirrmon:
url: https://ctan.org/mirmon
#---------------------------------------------------------------------------
# LUGs database settings.
lugs:
url: https://www.ntg.nl/lug/lugs/
#---------------------------------------------------------------------------
# Mail settings.
mail:
smtp:
host: localhost
port: 587
from: no-reply@ctan.org
list:
mirror-registration:
template: mirror-registration
to: ctan@ctan.org
#---------------------------------------------------------------------------
# Database settings.
site_db:
driverClass: org.postgresql.Driver
user: ${SITE_DB_USER:-www}
password: ${SITE_DB_PASSWD}
url: jdbc:postgresql://localhost:5432/${SITE_DB:-portal}
properties:
charSet: UTF-8
hibernate.dialect: org.hibernate.dialect.PostgreSQLDialect
maxWaitForConnection: 1s
validationQuery: "SELECT 1"
minSize: 8
maxSize: 32
checkConnectionWhileIdle: false
mirrors:
driverClass: org.postgresql.Driver
user: ${MIRRORS_DB_USER:-www}
password: ${MIRRORS_DB_PASSWD}
url: jdbc:postgresql://localhost:5432/${MIRRORS_DB:-ctan}
properties:
charSet: UTF-8
hibernate.dialect: org.hibernate.dialect.PostgreSQLDialect
maxWaitForConnection: 1s
validationQuery: "SELECT 1"
minSize: 8
maxSize: 32
checkConnectionWhileIdle: false
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classThe classCatalogueConfigcontains the Dropwizard configuration for the Catalogue.static classThe classContentConfigcontains the definition of the sub-configurationcontent.static classThe classCtanAnnounceConfigcontains the definition of the sub-configurationctanAnnounce.static classThe classCtanParamscontains the description of the sectionctanof the configuration.static classThe classIndexConfigcontains the definition of the sub-configurationindex.static classThe classLugsConfigcontains the Dropwizard configuration for the Lugs.static classThe mail configuration.static classThe SMTP configuration.static classThe SMTP starttls configuration.static classThe mail list type configuration.static classThe classMirrMonConfigcontains the Dropwizard configuration for MirrMon.static classThe classTexArchiveConfigcontains the definition of the sub-configurationtexArchive.static classThe classUploadConfigcontains the definition of the sub-configurationupload. -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class io.dropwizard.core.Configuration
getAdminFactory, getHealthFactory, getLoggingFactory, getMetricsFactory, getServerFactory, setAdminFactory, setHealthFactory, setLoggingFactory, setMetricsFactory, setServerFactory, toString
-
Constructor Details
-
CtanConfiguration
public CtanConfiguration()
-