An examplary application for the microservice-architecture provided under https://gitlab.reutlingen-university.de/poegel/microservice-architecture.
An examplary application for the microservice-architecture provided under https://gitlab.reutlingen-university.de/poegel/microservice-architecture.
## Getting started
## Getting started
To make use of this example-application, the [base microservice-architecture](https://gitlab.reutlingen-university.de/poegel/microservice-architecture) is required. Make sure it is deployed correctly before deploying the example provided in this repository.
To make use of this example-application, the [base microservice-architecture](https://gitlab.reutlingen-university.de/poegel/microservice-architecture) is required. Make sure it is deployed correctly before deploying the example provided in this repository.
The code used for this example uses [myaktion-go-2023](https://github.com/turngeek/myaktion-go-2023) as it's basis and only has been slighty adjusted to make use of the authentication service provided by the base microservices-architecture.
The code used for this example uses [myaktion-go-2023](https://github.com/turngeek/myaktion-go-2023) as it's basis and only has been slighty adjusted to make use of the authentication service provided by the base microservices-architecture.
## Deploying the application
## Deploying the application
After deploying the [base microservice-architecture](https://gitlab.reutlingen-university.de/poegel/microservice-architecture), this application can be simply deployed in the kubernetes cluster by applying all files found in the configuration directory.
After deploying the [base microservice-architecture](https://gitlab.reutlingen-university.de/poegel/microservice-architecture), this application can be simply deployed in the kubernetes cluster by applying all files found in the configuration directory.
This can be achieved using following command:
This can be achieved using following command:
```
```
kubectl apply -f {filename}
kubectl apply -f {filename}
```
```
Make sure to deploy them in the correct order of: Namespace > PersistentVolume > Deployment > Service > IngressRoute
Make sure to deploy them in the correct order of: Namespace > PersistentVolume > Deployment > Service > IngressRoute
\ No newline at end of file
## Testing the API
To try out the application you can execute the following examplary curl-commands.
Should the architecture not be deployed locally, change the localhost address to the actual IP-address. Every `{JWT}` needs to be replaced with a valid JWT received from the Auth-Service.
### Register first user (first registered user is the administrator)