Commit fa734518 authored by David Hübner's avatar David Hübner

mod README

parent aa6d14de
......@@ -10,17 +10,11 @@ This respository contains all CI/CD related files for didmos2-demo. The main fea
3) Jenkins pipeline for building & testing the software both as docker deployment and package deployment (currently Ubuntu 18)
4) Jenkins pipeline and manual instructions for setting up a production docker deployment
didmos2-demo contains of multiple components, which are developed in individual repositories. The environment can be bootstraped with either develop branches (the default) or the latest release versions. This can be controlled with the flag `ENV=release`, which is available for `make bootstrap`. This is explained below in more detail.
## System requirements
Parts of these repositories (master and release tags) are published on the external gitlab. The develop branch is only published on the internal gitlab, hence all features, which refer to the develop branches are not applicable to use cases involving the external gitlab. For most commands this can be controlled with the flag `GIT_PROFILE=external`.
### General requirements
## Productive deployment
See README in the subdirectory deploy in this repository.
## Local deployment using docker containers (Quickstart)
Install Dependencies:
For all functionality docker & docker-compose is required and must be installed manually:
- docker: [Official docs](https://docs.docker.com/compose/install/)
- docker-compose: [Official docs](https://docs.docker.com/compose/install/), version 1.25.0 or later
......@@ -31,11 +25,44 @@ Unless you are connected to DAASI's Internal network you need to add the followi
127.0.0.1 auth.daasi.devel backend.daasi.devel frontend.daasi.devel
```
Execute:
### Full local development environment requirements
For a full local development environment (i.e. when _not_ using `DEPLOY=dockerOnly`, see below), specific requirements must be fulfilled:
- Root permissions (sudo) on the local systems
- Fedora OS 29+
It's certainly possible to use another OS. However, this is untested and the steps done in scripts/bootstrap-devel.sh must be adopted manually.
## Step 1: Bootstrap environment
didmos2-demo contains of multiple components, which are developed in individual repositories. In order to start with development, a process called "bootstrap" must be run once. During this process, the source code of all components is cloned and various preparation is done. The environment can be bootstraped with either develop branches (the default) or the latest release versions. This can be controlled with the flag `ENV=release`, which is available for `make bootstrap`. When omitting this parameter, the default develop configuration is used.
Parts of these repositories (master and release tags) are published on the external gitlab. The develop branch is only published on the internal gitlab, hence all features, which refer to the develop branches are not applicable to use cases involving the external gitlab. For most commands this can be controlled with the flag `GIT_PROFILE=external`. When omitting this parameter, the default configuration with internal repositories is used.
Finally, the environment can be bootstraped either for a full local development environment (default) or only for docker containers. The first option allows development on frontend and backend using a development server, but has various specific requirements (see below). This can be controlled with the flag `DEPLOY=dockerOnly`. When omitting this parameter, a full bootstrap is performed.
In summary, the following bootstrap options may be interesting for different use cases:
`make bootstrap`: With access to daasi.int-repositories for development of frontend & backend
`make bootstrap DEPLOY=dockerOnly`: With access to daasi.int-repositories for docker-only development or deployment
`make bootstrap ENV=release GIT_PROFILE=external DEPLOY=dockerOnly`: Without access to daasi.int-repositories, where no develop branches exist and for docker-only development or deployment
## Step 2: Different development / deployment scenarios
After successfully bootstraping the environment (see Step 1), different scenarios can be used as follows:
### Step 2.a) Productive deployment
See README in the subdirectory deploy in this repository.
### Step 2.b) Local deployment using docker containers (Quickstart)
_This scenario requires a bootstrapped environment (either full or dockerOnly) from either repository (internal or external) and in either version (develop or release)._
```
make bootstrap ENV=release DEPLOY=dockerOnly GIT_PROFILE=external
```
If you want to use functionalities which send email such as self-registration you need to change the variables in .env:
......@@ -61,28 +88,11 @@ make up
Open in Browser https://auth.daasi.devel and https://backend.daasi.devel and accept certificates. Next go to https://frontend.daasi.devel accept certificate again and you should be able to login as superadmin / secret.
### Local development on core / frontend
Open your firewall on ports 4200 and 8080. In Fedora OS you can use the following commands
```
#check
sudo firewall-cmd --list-all
# change in necesary:
sudo firewall-cmd --add-port='4200/tcp' --permanent
sudo firewall-cmd --add-port='8080/tcp' --permanent
sudo firewall-cmd --reload
```
You need Fedora OS and a user with sudo permissions to install dependencies. Now execute as user (not as root):
```
make bootstrap
```
### Step 2.c) Local development on core / frontend
_NOTE_: If you executed another bootstrap command previously, run `make clean-fs` once in order to reset your environment.
_This scenario requires a bootstrapped environment for __full local development__ from either repository (internal or external) and in either version (develop or release)._
Next, setup mail credentials in didmos2-core/src/general/credentials.py
Setup mail credentials in didmos2-core/src/general/credentials.py
Now chose one of the make-up-* commands (see below for a complete list of Make-Commands). If you want to start both the frontend and backend locally, run:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment