In the following, we embark on a journey to deploy our application, navigating through a landscape marked by the intricacies of a microservice architecture. As we delve into the installation process, be prepared for a slightly more technical endeavor, where each step is meticulously crafted to ensure the seamless integration of our application's components. Embrace the challenge, for with it comes the opportunity to harness the power of modern infrastructure and unlock the full potential of our distributed system.
The following steps are required to install and configure the underlying Calculation Engine for the Data Computation Platform.
.pem
)Perform the following steps to install the calculation engine.
git clone http://gitlab.com/digitalclone/acdc/core.git acdc
<sourceFileDir>/acdc/certs
.acdc
folder: cd <sourceFileDir>/acdc
.sudo bash build.sh
.username
, password
and email
during the installation process./etc/httpd/conf/httpd.conf
.R –e ‘install.packages("acdcClient", type = "source", repos = list("https://gitlab.com/artifactory/AC-DC-Universe", "https://gitlab.com/artifactory/acdc-local"))’
export PATH="/usr/local/texlive/2021/bin/x86_64-linux:$PATH"
tlmgr conf auxtrees add /usr/lib/acdc/templates/texmf
tlmgr conf auxtrees add /usr/share/R/texmf
/etc/opencpu/Renviron
and add the following lines:
CURL_SSL_BACKEND = "openssl"
ACDC_CA_PATH = "<sourceFileDir>/acdc/certs/{certname}.pem "
systemctl restart httpd
.Now you should be ready to continue with the installation of backend and frontend of the Data Computation Platform.
Depending on your desired installation scope, none, one or multiple R packages need to be deployed to the prepared calculation engine instance. Therefore, the following steps need to be completed:
{{packageName}}
with the corresponding package name:
R –e 'install.packages("{{packageName}}", type = "source",repos = list("https://domain.com/artifactory/AC-DC-Universe","https://domain.com/artifactory/acdc-local"))'
systemctl restart httpd
.The following official packages for DCP are available:
The following steps are required to install and configure the Data Computation Platform and its components.
The following infrastructure components are required:
web.config
file.Open the Windows Server Manager Application and add the following roles and features.
In the Server Roles:
In the Web Server Roles:
The installation of php is required for the Simplified Analytics Workbench (SAW) backend only.
Environment configuration is applied during the build, my modifying the build settings for frontend applications located at project-root/settings.json
.
This file contains a few strings and booleans defining the environment specific logic. See an example below:
{
"apiUrl": "https://api-domain.com",
"baseAppUrl": "https://domain.com/",
"production": true,
"privacyPolicyUrl": "https://domain.com/privacy_policy.htm",
"backendPortCheckUrl": "domain.com:"
}
This file needs to be generated before triggering the npm build
command (either manually or within the CI). During local development this file need to be added and configured manually. The file is excluded via .gitignore
, therefore not included into repositories.
The configuration file settings.json
has the following impact:
Property | Type | Angular Apps | VueJS Apps | Description |
---|---|---|---|---|
apiUrl | string | ☑ | ☑ | Current application BE URL like "https://domain.com" |
baseAppUrl | string | ☑ | ☐ | Base app deploy url (with trailing slash) like "https://domain.com/" |
privacyPolicyUrl | string | ☑ | ☐ | Url to applicable privacy policy "privacyPolicyUrl": "https://domain.com/privacy_policy.htm" used inside Login page. |
backendPortCheckUrl | string | ☑ | ☐ | Needs to be in format "domain.com:" so we can use it in interceptor, to assume if there is an port part of the url. |
production | string | ☑ | ☐ | Base app deploy url (with trailing slash) like "https://domain.com/" |
There is one place in Angular Applications where settings.json
cannot be used as the configuration source, tis is the angular.json
file. Therefore placeholders which are replaced during the build are used in the file. The placeholders are replaced prior to the build. This can be done manually or using scrips e.g. sed. The current replacement can be done using the following commands:
sed -i "s|CLI_DEPLOY_URL|https://${DCP_SERVER}/${APP_NAME}/|g" ${CI_PROJECT_DIR}/angular.json
The following placeholders are used:
CLI_DEPLOY_URL
which is assigned at configuration.production.deployUrl
containing the application root, where the app should be deployed.