-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
36d69dc
commit f444898
Showing
17 changed files
with
659 additions
and
189 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
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
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 |
---|---|---|
@@ -0,0 +1,92 @@ | ||
# DTaaS on Linux Operating System | ||
|
||
These are installation instructions for running DTaaS application on a Ubuntu Server 20.04 Operating System. The setup requires a machine which can spare 16GB RAM, 8 vCPUs and 50GB Hard Disk space. | ||
|
||
A dummy **foo.com** URL has been used for illustration. Please change this to your unique website URL. It is assumed that you are going to serve the application in only HTTPS mode. | ||
|
||
Please follow these steps to make this work in your local environment. Download the **DTaaS.zip** from the [releases page](https://github.com/INTO-CPS-Association/DTaaS/releases). Unzip the same into a directory named **DTaaS**. The rest of the instructions assume that your working directory is **DTaaS**. | ||
|
||
!!! note | ||
If you only want to test the application and are not setting up a production instance, you can follow the instructions of [trial installation](trial.md). | ||
|
||
## Configuration | ||
|
||
You need to configure the Traefik gateway, library microservice and react client website. | ||
|
||
The first step is to decide on the number of users and their usenames. The traefik gateway configuration has a template for two users. You can modify the usernames in the template to the usernames chosen by you. | ||
|
||
### The traefik gateway server | ||
|
||
You can run the Run the Traefik gateway server in both and HTTPS HTTPS mode to experience the DTaaS application. The installation guide assumes that you can run the application in HTTPS mode. | ||
|
||
The Traefik gateway configuration is at _deploy/config/gateway/fileConfig.yml_. Change `foo.com` to your local hostname and user1/user2 to the usernames chosen by you. | ||
|
||
!!! tip | ||
|
||
Do not use `http://` or `https://` in _deploy/config/gateway/fileConfig.yml_. | ||
|
||
#### Authentication | ||
|
||
The dummy username is `foo` and the password is `bar`. | ||
Please change this before starting the gateway. | ||
|
||
```bash | ||
rm deploy/config/gateway/auth | ||
touch deploy/config/gateway/auth | ||
htpasswd deploy/config/gateway/auth <first_username> | ||
password: <your password> | ||
``` | ||
|
||
The user credentials added in _deploy/config/gateway/auth_ should match the usernames in _deploy/config/gateway/fileConfig.yml_. | ||
|
||
## Configure lib microservice | ||
|
||
The first step in this configuration is to prepare the a filesystem for users. An example file system in `files/` directory. You can rename the top-level user1/user2 to the usernames chosen by you. | ||
|
||
Update the _deploy/config/lib_ of the library microservice. The simplest possibility is to use `local` mode with the following example. The filepath is the absolute filepath to `files/` directory. | ||
|
||
```env | ||
PORT='4001' | ||
MODE='local' | ||
LOCAL_PATH ='filepath' | ||
LOG_LEVEL='debug' | ||
APOLLO_PATH='/lib' | ||
GRAPHQL_PLAYGROUND='true' | ||
``` | ||
|
||
## Configure react website | ||
|
||
Change the React website configuration in _deploy/config/client/env.js_. | ||
|
||
```js | ||
window.env = { | ||
REACT_APP_ENVIRONMENT: 'prod', | ||
REACT_APP_URL: 'https://foo.com/', | ||
REACT_APP_URL_BASENAME: '', | ||
REACT_APP_URL_DTLINK: '/lab', | ||
REACT_APP_URL_LIBLINK: '', | ||
REACT_APP_WORKBENCHLINK_TERMINAL: '/terminals/main', | ||
REACT_APP_WORKBENCHLINK_VNCDESKTOP: '/tools/vnc/?password=vncpassword', | ||
REACT_APP_WORKBENCHLINK_VSCODE: '/tools/vscode/', | ||
REACT_APP_WORKBENCHLINK_JUPYTERLAB: '/lab', | ||
REACT_APP_WORKBENCHLINK_JUPYTERNOTEBOOK: '', | ||
}; | ||
``` | ||
|
||
## Update the installation script | ||
|
||
Open `deploy/install.sh` and update user1/user2 to usernames chosen by you. | ||
|
||
## Perform the Installation | ||
|
||
Go to the DTaaS directory and execute | ||
|
||
```sh | ||
source deploy/install.sh | ||
``` | ||
|
||
You can run this script multiple times until the installation is successful. | ||
|
||
## Access the application | ||
|
||
Now you should be able to access the DTaaS application at: _https://foo.com_ |
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 |
---|---|---|
@@ -0,0 +1,13 @@ | ||
|
||
# Trial Installation | ||
|
||
A single step install script is helpful in performing a trial run of the software. This script installs DTaaS software with default credentials and users on a Ubuntu server OS. You can use it to check a test installation of DTaaS. | ||
|
||
```bash | ||
wget https://github.com/INTO-CPS-Association/DTaaS/releases/download/v0.2.0/single-script-install.sh | ||
bash single-script-install.sh | ||
``` | ||
|
||
!!! warning | ||
|
||
This test installation has default credentials and is thus highly insecure. |
Oops, something went wrong.