Skip to content

Commit

Permalink
chore(docs):[#408] add install instructions for umbrella chart
Browse files Browse the repository at this point in the history
  • Loading branch information
ds-jhartmann committed Aug 5, 2024
1 parent e0edb09 commit 197bb59
Show file tree
Hide file tree
Showing 2 changed files with 98 additions and 2 deletions.
96 changes: 95 additions & 1 deletion INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,105 @@ Create a new application in ArgoCD and point it to your repository / Helm chart
A detailed instruction on how to configure the IRS and EDC can be found here: [Administration Guide](https://eclipse-tractusx.github.io/item-relationship-service/docs/administration/administration-guide.html)

## Local Installation

IRS provides a local setup which can be deployed to kubernetes.
This setup includes all third-party services which IRS uses and interacts with.

Instructions can be found here [README](README.md).

## Sample Calls

Sample calls can be found here [USAGE](USAGE.md).
Sample calls can be found here [USAGE](USAGE.md).

## Local Installation with Umbrella

The eclipse-tractusx/umbrella chart provides a pre-configured Helm Chart with many Tractus-X Services. To integrate IRS
with this Chart, run the following steps:

For detailed instructions on how to set up the umbrella chart, see the chapters "Cluster setup" and "Network setup" in
the umbrella [README.md](https://github.com/eclipse-tractusx/tractus-x-umbrella/blob/main/charts/umbrella/README.md).

Clone the [Umbrella repo](https://github.com/eclipse-tractusx/tractus-x-umbrella) (only required once):

```
git clone https://github.com/eclipse-tractusx/tractus-x-umbrella.git
```

Check out
the [IRS umbrella integration branch](https://github.com/eclipse-tractusx/tractus-x-umbrella/tree/chore/e2e-irs-preparation):

```
cd tractus-x-umbrella/
git fetch origin
git checkout -b chore/e2e-irs-preparation origin/chore/e2e-irs-preparation
```

Build the required images for IATP mock.

```bash
eval $(minikube docker-env)
docker build iatp-mock/ -t tractusx/iatp-mock:testing --platform linux/amd64
```

Install the Umbrella chart

```bash
helm dependency update charts/tx-data-provider
helm dependency update charts/umbrella
helm install umbrella charts/umbrella -f charts/umbrella/values-adopter-irs.yaml -n e2e-testing --create-namespace
```

(Optional) Build IRS Docker image from local

```bash
docker build . -t tractusx/irs-api:local
```

Install the IRS Helm Chart with the local Docker image

```bash
helm dependency update ./charts/item-relationship-service
helm install irs ./charts/item-relationship-service --namespace e2e-testing -f ./charts/item-relationship-service/values-umbrella.yaml --set image.repository=tractusx/irs-api -- set image.tag=local
```

Or use the latest released version

```bash
helm repo add irs https://eclipse-tractusx.github.io/item-relationship-service
helm install irs irs/item-relationship-service --namespace e2e-testing -f ./charts/item-relationship-service/values-umbrella.yaml --set image.repository=tractusx/irs-api --set image.tag=latest
```

### upload testdata

To upload testdata, first forward the dataprovider pods to your localhost:

```bash
kubectl port-forward svc/umbrella-dataprovider-dtr 4444:8080 --namespace e2e-testing &
kubectl port-forward svc/umbrella-dataprovider-edc-controlplane 8888:8081 --namespace e2e-testing &
kubectl port-forward svc/umbrella-dataprovider-submodelserver 9999:8080 --namespace e2e-testing
```

then use the testdata upload script to seed the dataprovider services with testdata:

```bash
./local/testing/testdata/upload-testdata.sh "TEST2" "BPNL00000003AYRE" "BPNL00000003AZQP" \
"http://umbrella-dataprovider-submodelserver:8080" "http://localhost:9999" \
"http://umbrella-dataprovider-dtr:8080/api/v3" "http://localhost:4444/api/v3" \
"http://umbrella-dataprovider-edc-controlplane:8084" "http://localhost:8888" \
"http://umbrella-dataprovider-edc-dataplane:8081"
```

Now forward the IRS service port to access the API:

```bash
kubectl port-forward svc/irs-item-relationship-service 8080:8080 --namespace e2e-testing
```

### Uninstall

To uninstall the IRS and Umbrella chart

```bash
helm uninstall irs --namespace e2e-testing
helm uninstall umbrella --namespace e2e-testing
```
4 changes: 3 additions & 1 deletion docs/src/docs/arc42/cross-cutting/testing.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,6 @@ Test results are automatically added to the workflow summary and in case of the

Due to limitations in the IATP mock, the only way of using multiple BPNs in the test data is to spin up multiple EDC provider instances.
However, the chart is used inside GitHub Workflows, so compute resources are limited.
For this reason, the IRS test data was changed to include only data pointing to a single BPN.
For this reason, the IRS test data was changed to include only data pointing to a single BPN.

For instructions on how to use the Umbrella Chart locally, see https://github.com/eclipse-tractusx/item-relationship-service/blob/main/INSTALL.md#local-installation-with-umbrella[INSTALL.md]

0 comments on commit 197bb59

Please sign in to comment.