-
Notifications
You must be signed in to change notification settings - Fork 137
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- added configuration via environment variables to Dockerfile - amended authors list on container metadata - amended envsubst command to include all environment variables - extended config-local.js to include the majority of configuration options available in app.js - Added comment to app.js to remind future contributors to add configuration to Dockerfile and config-local.js
- Loading branch information
1 parent
dd9e49e
commit d8a1e26
Showing
5 changed files
with
219 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -92,7 +92,7 @@ jobs: | |
labels: | | ||
${{ steps.docker_meta.outputs.labels }} | ||
maintainer=Joris Borgdorff <[email protected]>, Lee Evans - www.ltscomputingllc.com | ||
org.opencontainers.image.authors=Joris Borgdorff <[email protected]>, Lee Evans - www.ltscomputingllc.com | ||
org.opencontainers.image.authors=Joris Borgdorff <[email protected]>, Lee Evans - www.ltscomputingllc.com, Shaun Turner <[email protected]> | ||
org.opencontainers.image.vendor=OHDSI | ||
# If the image was pushed, we need to pull it again to inspect it | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,16 +29,106 @@ RUN find . -type f "(" \ | |
FROM docker.io/nginxinc/nginx-unprivileged:1.23.3-alpine@sha256:c748ba587e7436aaa8729b64d4e0412410a486f0c592f0eec100fb3804ff9afd | ||
|
||
LABEL org.opencontainers.image.title="OHDSI-Atlas" | ||
LABEL org.opencontainers.image.authors="Joris Borgdorff <[email protected]>, Lee Evans - www.ltscomputingllc.com" | ||
LABEL org.opencontainers.image.authors="Joris Borgdorff <[email protected]>, Lee Evans - www.ltscomputingllc.com, Shaun Turner<[email protected]>" | ||
LABEL org.opencontainers.image.description="ATLAS is an open source software tool for researchers to \ | ||
conduct scientific analyses on standardized observational data" | ||
LABEL org.opencontainers.image.licenses="Apache-2.0" | ||
LABEL org.opencontainers.image.vendor="OHDSI" | ||
LABEL org.opencontainers.image.source="https://github.com/OHDSI/Atlas" | ||
|
||
# URL where WebAPI can be queried by the client | ||
ENV WEBAPI_URL=http://localhost:8080/WebAPI/ \ | ||
CONFIG_PATH=/etc/atlas/config-local.js | ||
ENV USE_DYNAMIC_WEBAPI_URL="false" | ||
ENV DYNAMIC_WEBAPI_SUFFIX="/WebAPI/" | ||
ENV WEBAPI_URL="http://localhost:8080/WebAPI/" | ||
ENV CONFIG_PATH="/etc/atlas/config-local.js" | ||
ENV APP_NAME="OHDSI" | ||
ENV COHORT_COMPARISON_RESULTS="false" | ||
ENV USER_AUTHENTICATION="false" | ||
ENV PLP_RESULTS="false" | ||
ENV CLEAR_LOCAL_STORAGE="false" | ||
ENV DISABLE_BROWSER_CHECK="false" | ||
ENV ENABLE_PERMISSIONS_MGMT="true" | ||
ENV CACHE_SOURCES="false" | ||
ENV POLL_INTERVAL="60000" | ||
ENV SKIP_LOGIN="false" | ||
ENV USE_EXECUTION_ENGINE="false" | ||
ENV VIEW_PROFILE_DATES="false" | ||
ENV ENABLE_COSTS="false" | ||
ENV SUPPORT_URL="https://github.com/ohdsi/atlas/issues" | ||
ENV SUPPORT_MAIL="[email protected]" | ||
ENV FEEDBACK_CONTACTS="For access or questions concerning the Atlas application please contact:" | ||
ENV FEEDBACK_HTML="" | ||
ENV COMPANYINFO_HTML="" | ||
ENV COMPANYINFO_SHOW="true" | ||
ENV DEFAULT_LOCALE="en" | ||
|
||
ENV WIN_PROVIDER_ENABLED="false" | ||
ENV WIN_PROVIDER_NAME="Windows" | ||
ENV WIN_PROVIDER_URL="user/login/windows" | ||
ENV WIN_PROVIDER_AJAX="true" | ||
ENV WIN_PROVIDER_ICON="fab fa-windows" | ||
|
||
ENV KERB_PROVIDER_ENABLED="false" | ||
ENV KERB_PROVIDER_NAME="Kerberos" | ||
ENV KERB_PROVIDER_URL="user/login/kerberos" | ||
ENV KERB_PROVIDER_AJAX="true" | ||
ENV KERB_PROVIDER_ICON="fab fa-windows" | ||
|
||
ENV OID_PROVIDER_ENABLED="false" | ||
ENV OID_PROVIDER_NAME="OpenID Connect" | ||
ENV OID_PROVIDER_URL="user/login/openid" | ||
ENV OID_PROVIDER_AJAX="false" | ||
ENV OID_PROVIDER_ICON="fa fa-openid" | ||
|
||
ENV GGL_PROVIDER_ENABLED="false" | ||
ENV GGL_PROVIDER_NAME="Google" | ||
ENV GGL_PROVIDER_URL="user/oauth/google" | ||
ENV GGL_PROVIDER_AJAX="false" | ||
ENV GGL_PROVIDER_ICON="fab fa-google" | ||
|
||
ENV FB_PROVIDER_ENABLED="false" | ||
ENV FB_PROVIDER_NAME="Facebook" | ||
ENV FB_PROVIDER_URL="user/oauth/facebook" | ||
ENV FB_PROVIDER_AJAX="false" | ||
ENV FB_PROVIDER_ICON="fab fa-facebook-f" | ||
|
||
ENV GH_PROVIDER_ENABLED="false" | ||
ENV GH_PROVIDER_NAME="Github" | ||
ENV GH_PROVIDER_URL="user/oauth/github" | ||
ENV GH_PROVIDER_AJAX="false" | ||
ENV GH_PROVIDER_ICON="fab fa-github" | ||
|
||
ENV DB_PROVIDER_ENABLED="false" | ||
ENV DB_PROVIDER_NAME="DB" | ||
ENV DB_PROVIDER_URL="user/login/db" | ||
ENV DB_PROVIDER_AJAX="true" | ||
ENV DB_PROVIDER_ICON="fa fa-database" | ||
ENV DB_PROVIDER_CREDFORM="true" | ||
|
||
ENV LDAP_PROVIDER_ENABLED="false" | ||
ENV LDAP_PROVIDER_NAME="LDAP" | ||
ENV LDAP_PROVIDER_URL="user/login/ldap" | ||
ENV LDAP_PROVIDER_AJAX="true" | ||
ENV LDAP_PROVIDER_ICON="fa fa-cubes" | ||
ENV LDAP_PROVIDER_CREDFORM="true" | ||
|
||
ENV SAML_PROVIDER_ENABLED="false" | ||
ENV SAML_PROVIDER_NAME="SAML" | ||
ENV SAML_PROVIDER_URL="user/login/saml" | ||
ENV SAML_PROVIDER_AJAX="false" | ||
ENV SAML_PROVIDER_ICON="fab fa-openid" | ||
|
||
ENV AD_PROVIDER_ENABLED="false" | ||
ENV AD_PROVIDER_NAME="Active Directory LDAP" | ||
ENV AD_PROVIDER_URL="user/login/ad" | ||
ENV AD_PROVIDER_AJAX="true" | ||
ENV AD_PROVIDER_ICON="fa fa-cubes" | ||
ENV AD_PROVIDER_CREDFORM="true" | ||
|
||
ENV ENABLE_TANDCS="true" | ||
ENV ENABLE_PERSONCOUNT="true" | ||
ENV ENABLE_TAGGING_SECTION="false" | ||
ENV REFRESH_TOKEN_THRESHOLD="240" | ||
|
||
# Configure webserver | ||
COPY ./docker/nginx-default.conf /etc/nginx/conf.d/default.conf | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,131 @@ | ||
define([], function () { | ||
var configLocal = {}; | ||
|
||
if ("${CLEAR_LOCAL_STORAGE}" == "true") { | ||
localStorage.clear(); | ||
} | ||
|
||
var webapi_url = "${WEBAPI_URL}"; | ||
|
||
if ("${USE_DYNAMIC_WEBAPI_URL}" == "true") { | ||
var getUrl = window.location; | ||
webapi_url = getUrl.protocol + "//" + getUrl.hostname + "${DYNAMIC_WEBAPI_SUFFIX}"; | ||
} | ||
|
||
// WebAPI | ||
configLocal.api = { | ||
name: 'OHDSI', | ||
url: '${WEBAPI_URL}' | ||
name: '${APP_NAME}', | ||
url: webapi_url | ||
}; | ||
|
||
configLocal.cohortComparisonResultsEnabled = false; | ||
configLocal.userAuthenticationEnabled = false; | ||
configLocal.plpResultsEnabled = false; | ||
configLocal.cohortComparisonResultsEnabled = ("${COHORT_COMPARISON_RESULTS}" == "true"); | ||
configLocal.plpResultsEnabled = ("${PLP_RESULTS}" === "true"); | ||
configLocal.userAuthenticationEnabled = ("${USER_AUTHENTICATION}" === "true"); | ||
configLocal.authProviders = []; | ||
configLocal.disableBrowserCheck = ("${DISABLE_BROWSER_CHECK}" === "true"); | ||
configLocal.enablePermissionManagement = ("${ENABLE_PERMISSIONS_MGMT}" === "true"); | ||
configLocal.cacheSources = ("${CACHE_SOURCES}" === "true"); | ||
configLocal.enableSkipLogin = ("${SKIP_LOGIN}" === "true"); // automatically opens login window when user is not authenticated | ||
configLocal.useExecutionEngine = ("${USE_EXECUTION_ENGINE}" === "true"); | ||
configLocal.viewProfileDates = ("${VIEW_PROFILE_DATES}" === "true"); | ||
configLocal.enableCosts = ("${ENABLE_COSTS}" === "true"); | ||
configLocal.supportUrl = "${SUPPORT_URL}"; | ||
configLocal.supportMail = "${SUPPORT_MAIL}"; | ||
configLocal.feedbackContacts = "${FEEDBACK_CONTACTS}"; | ||
configLocal.feedbackCustomHtmlTemplate = "${FEEDBACK_HTML}"; | ||
configLocal.companyInfoCustomHtmlTemplate = "${COMPANYINFO_HTML}"; | ||
configLocal.showCompanyInfo = ("${COMPANYINFO_SHOW}" === "true"); | ||
configLocal.defaultLocale = "${DEFAULT_LOCALE}"; | ||
configLocal.pollInterval = parseInt("${POLL_INTERVAL}"); | ||
|
||
|
||
if ("${WIN_PROVIDER_ENABLED}" === "true") { | ||
configLocal.authProviders.push(openIdProvider = { | ||
name: "${WIN_PROVIDER_NAME}", | ||
url: "${WIN_PROVIDER_URL}", | ||
ajax: ("${WIN_PROVIDER_AJAX}" === "true"), | ||
icon: "${WIN_PROVIDER_ICON}", | ||
}); | ||
} | ||
|
||
if ("${KERB_PROVIDER_ENABLED}" === "true") { | ||
configLocal.authProviders.push(openIdProvider = { | ||
name: "${KERB_PROVIDER_NAME}", | ||
url: "${KERB_PROVIDER_URL}", | ||
ajax: ("${KERB_PROVIDER_AJAX}" === "true"), | ||
icon: "${KERB_PROVIDER_ICON}", | ||
}); | ||
} | ||
|
||
if ("${OID_PROVIDER_ENABLED}" === "true") { | ||
configLocal.authProviders.push(openIdProvider = { | ||
name: "${OID_PROVIDER_NAME}", | ||
url: "${OID_PROVIDER_URL}", | ||
ajax: ("${OID_PROVIDER_AJAX}" === "true"), | ||
icon: "${OID_PROVIDER_ICON}", | ||
}); | ||
} | ||
|
||
if ("${GGL_PROVIDER_ENABLED}" === "true") { | ||
configLocal.authProviders.push(openIdProvider = { | ||
name: "${GGL_PROVIDER_NAME}", | ||
url: "${GGL_PROVIDER_URL}", | ||
ajax: ("${GGL_PROVIDER_AJAX}" === "true"), | ||
icon: "${GGL_PROVIDER_ICON}", | ||
}); | ||
} | ||
|
||
if ("${FB_PROVIDER_ENABLED}" === "true") { | ||
configLocal.authProviders.push(openIdProvider = { | ||
name: "${FB_PROVIDER_NAME}", | ||
url: "${FB_PROVIDER_URL}", | ||
ajax: ("${FB_PROVIDER_AJAX}" === "true"), | ||
icon: "${FB_PROVIDER_ICON}", | ||
}); | ||
} | ||
|
||
if ("${GH_PROVIDER_ENABLED}" === "true") { | ||
configLocal.authProviders.push(openIdProvider = { | ||
name: "${GH_PROVIDER_NAME}", | ||
url: "${GH_PROVIDER_URL}", | ||
ajax: ("${GH_PROVIDER_AJAX}" === "true"), | ||
icon: "${GH_PROVIDER_ICON}", | ||
}); | ||
} | ||
|
||
if ("${DB_PROVIDER_ENABLED}" === "true") { | ||
configLocal.authProviders.push(openIdProvider = { | ||
name: "${DB_PROVIDER_NAME}", | ||
url: "${DB_PROVIDER_URL}", | ||
ajax: ("${DB_PROVIDER_AJAX}" === "true"), | ||
icon: "${DB_PROVIDER_ICON}", | ||
isUseCredentialsForm: ("${DB_PROVIDER_CREDFORM}" === "true") | ||
}); | ||
} | ||
|
||
if ("${LDAP_PROVIDER_ENABLED}" === "true") { | ||
configLocal.authProviders.push(openIdProvider = { | ||
name: "${LDAP_PROVIDER_NAME}", | ||
url: "${LDAP_PROVIDER_URL}", | ||
ajax: ("${LDAP_PROVIDER_AJAX}" === "true"), | ||
icon: "${LDAP_PROVIDER_ICON}", | ||
isUseCredentialsForm: ("${LDAP_PROVIDER_CREDFORM}" === "true") | ||
}); | ||
} | ||
|
||
if ("${SAML_PROVIDER_ENABLED}" === "true") { | ||
configLocal.authProviders.push(openIdProvider = { | ||
name: "${SAML_PROVIDER_NAME}", | ||
url: "${SAML_PROVIDER_URL}", | ||
ajax: ("${SAML_PROVIDER_AJAX}" === "true"), | ||
icon: "${SAML_PROVIDER_ICON}", | ||
}); | ||
} | ||
|
||
configLocal.enableTermsAndConditions = ("${ENABLE_TANDCS}" === "true"); | ||
configLocal.enablePersonCount = ("${ENABLE_PERSONCOUNT}" === "true"); | ||
configLocal.enableTaggingSection = ("${ENABLE_TAGGING_SECTION}" === "true"); | ||
configLocal.refreshTokenThreshold = 1000 * 60 * parseInt("${REFRESH_TOKEN_THRESHOLD}"); | ||
|
||
return configLocal; | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters