Skip to content

Commit

Permalink
Merge branch 'main' into ldap
Browse files Browse the repository at this point in the history
  • Loading branch information
fpotier authored May 28, 2024
2 parents 4e38454 + fad1408 commit 30604cf
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 15 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ SciCat with docker compose.

By running `docker compose up -d` these steps take place:
1. a [mongodb](./services/mongodb/) container is created with some initial data.
2. the SciCat [backend v4](./services/backend/v4/) container is created and connected to (1).
2. the SciCat [backend v4](./services/backend/services/v4/) container is created and connected to (1).
3. the SciCat [frontend](./services/frontend/) container is created and connected to (2).
4. a reverse [proxy](./services/proxy) container is created and routes traffic to (2) and (3) through localhost subdomains, in the form: `http://${service}.localhost`. The frontend is available at simply `http://localhost`.

Expand Down Expand Up @@ -109,12 +109,12 @@ Make sure to check the [backend compatibility](#docker-compose-profiles-and-env-

## Add a new service

To add a new service (see the [backend v4](./services/backend/v4/) for an extensive example):
To add a new service (see the [backend v4](./services/backend/services/v4/) for an extensive example):
1. create a dedicated folder in the [services](./services/) one
2. name it as the service
3. create the `compose.yaml` file with the required dependencies (if any)
4. eventually, include any service in (2) and (3) which is specific to the service and not shared across the global setup
5. eventually, add additional configurable logic (e.g. [BE_VERSION dependency](./services/frontend/compose.yaml#L14) and [JOBS_ENABLED dependency](./services/backend/v3/compose.yaml))
5. eventually, add additional configurable logic (e.g. [BE_VERSION dependency](./services/frontend/compose.yaml#L14) and [JOBS_ENABLED dependency](./services/backend/services/v3/compose.yaml))
6. eventually, add the platform field, as described [here](#supported-os-architectures)
7. eventually, create a `config` folder if it requires configuration
8. eventually, add a `README.md` file in the service
Expand Down
4 changes: 2 additions & 2 deletions services/backend/services/v3/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,11 @@ In the default configuration folder [config](./config), the backend is set to us

## Enable additional features

Additionally, by setting the env variable [ENABLE_JOBS](../../.env#L5), the [archive mock](../archivemock/) and [rabbitmq](../rabbitmq/) services are started and the backend is configured to connect to them.
Additionally, by setting the env variable [ENABLE_JOBS](../../.env#L5), the [archive mock](./services/archivemock/) and [rabbitmq](./services/rabbitmq/) services are started and the backend is configured to connect to them.

## Dependencies

Here below we show the internal dependencies of the service, which are not already covered [here](../../README.md) (if `B` depends on `A`, then we visualize it as `A --> B`). The same subdomain to service convention applies.
Here below we show the internal dependencies of the service, which are not already covered [here](../../../../README.md) (if `B` depends on `A`, then we visualize it as `A --> B`). The same subdomain to service convention applies.

```mermaid
graph TD
Expand Down
4 changes: 2 additions & 2 deletions services/backend/services/v3/services/archivemock/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ The Archive Mock simulates the interactions of an archival mock with SciCat.

## Service Requirements
- [RabbitMQ](../rabbitmq/)
- [backend v3](../backend/v3/) (configured to use the RabbitMQ instance above for jobs)
- [backend v3](../../) (configured to use the RabbitMQ instance above for jobs)

## [Config](./config/.env) - Environment Variables

The container uses [environment variables](https://github.com/SwissOpenEM/ScicatArchiveMock?tab=readme-ov-file#utility-scripts) for configuration.

## Default configuraiton

By default, it is configured to connect to the [backend v3](../backend/v3/) container with the `admin` account, and to the [RabbitMQ](../rabbitmq/) container with the `guest` account. It will then handle all archival and retrieval jobs posted to RabbitMQ, and update the corresponding Datasets accordingly in Scicat.
By default, it is configured to connect to the [backend v3](../../) container with the `admin` account, and to the [RabbitMQ](../rabbitmq/) container with the `guest` account. It will then handle all archival and retrieval jobs posted to RabbitMQ, and update the corresponding Datasets accordingly in Scicat.
8 changes: 2 additions & 6 deletions services/backend/services/v4/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,11 @@ In the default configuration folder [config](./config), the backend is set to us

## Enable additional features

<<<<<<< HEAD:services/backendv4/README.md
Additionally, by setting the env variable `ENABLE_JOBS`, the [elastic search](../elastic/) service is started and the backend is configured to connect to them.
=======
Additionally, by setting the env variable `ELASTIC_ENABLED`, the [elastic search](../elastic/) service is started and the backend is configured to connect to them.
>>>>>>> origin/main:services/backend/services/v4/README.md
Additionally, by setting the env variable `ELASTIC_ENABLED`, the [elastic search](./services/elastic/) service is started and the backend is configured to connect to them.

## Dependencies

Here below we show the internal dependencies of the service, which are not already covered [here](../../README.md) (if `B` depends on `A`, then we visualize as `A --> B`). The same subdomain to service convention applies.
Here below we show the internal dependencies of the service, which are not already covered [here](../../../../README.md) (if `B` depends on `A`, then we visualize as `A --> B`). The same subdomain to service convention applies.

```mermaid
graph TD
Expand Down
2 changes: 1 addition & 1 deletion services/frontend/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ For an extensive list of available options see [here](https://scicatproject.gith

## Default configuration

In the default configuration [config](./config/), the frontend is set to call the `backend service` available at `backend.localhost` (either [v4](../backend/v4/), by default, or [v3](../backend/v3/) if specified otherwise by setting `BE_VERSION`).
In the default configuration [config](./config/), the frontend is set to call the `backend service` available at `backend.localhost` (either [v4](../backend/services/v4/), by default, or [v3](../backend/services/v3/) if specified otherwise by setting `BE_VERSION`).

For an explanation of how setting `BE_VERSION` changes the environment creation see [here](../../README.md#docker-compose-profiles-and-env-variables-configuration-options).

Expand Down
2 changes: 1 addition & 1 deletion services/searchapi/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@ The searchapi configuration is set by the [.env file](./config/.env). For an ext

## Default configuration

In the default configuration [.env file](./config/.env), the searchapi is set to call the `backend service` available at `backend.localhost` (either [v4](../backend/v4/), by default, or [v3](../backend/v3/) if specified otherwise by setting `BE_VERSION`).
In the default configuration [.env file](./config/.env), the searchapi is set to call the `backend service` available at `backend.localhost` (either [v4](../backend/services/v4/), by default, or [v3](../backend/services/v3/) if specified otherwise by setting `BE_VERSION`).

For an explanation of how setting `BE_VERSION` changes the environment creation see [here](../../README.md#docker-compose-profiles-and-env-variables-configuration-options).

0 comments on commit 30604cf

Please sign in to comment.