Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve Aerospike-related docs #122

Merged
merged 5 commits into from
Feb 27, 2024
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 38 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,47 @@ $ git clone https://github.com/prebid/prebid-cache-java.git
```

(2). Start Redis or Aerospike:
If you have installed Redis or Aerospike locally, you may start them both (or separately, depends on your needs) via bash:
```bash
$ nohup redis-server & sudo service aerospike start
```
Alternatively, you may start DB as Docker image. But before you should install [Docker Engine](https://docs.docker.com/engine/install/), if you doesn't have one.
VeryExtraordinaryUsername marked this conversation as resolved.
Show resolved Hide resolved

(2.1) Redis via Docker
1. Pull [Redis docker image](https://hub.docker.com/_/redis) of an appropriate version
```
docker pull redis:<version>
VeryExtraordinaryUsername marked this conversation as resolved.
Show resolved Hide resolved
```
2. Run Redis container
- the `<version>` should correspond to the pulled image version
- the `<host>` and `<port>` should correspond to the `spring.redis.host` and `spring.redis.port` properties values of the Prebid Cache
- the `<namespace>` should correspond to the spring.aerospike.namespace property value of the Prebid Cache
```bash
$ nohup redis-server &
$ docker run -d --name redis -p <host>:<port>:6379 redis:<version>
Net-burst marked this conversation as resolved.
Show resolved Hide resolved

$ sudo service aerospike start
// Example (the host will be defined as localhost by default)
$ docker run -d --name redis -p 6379:6379 redis:7.2.4
```

(2.2) Aerospike via Docker
1. Pull [Aerospike docker image](https://hub.docker.com/_/aerospike) of an appropriate version
```bash
docker pull aerospike:<version>
```
2. Run Aerospike container (the following instruction is enough for the Community Edition only)
- the `<version>` should correspond to the pulled image version
- the `<host>` and `<port>` should correspond to the `spring.aerospike.host` and `spring.aerospike.port` properties values of the Prebid Cache
- the `<namespace>` should correspond to the spring.aerospike.namespace property value of the Prebid Cache
```bash
$ docker run -d --name aerospike -e "NAMESPACE=<namespace>" -p <host>:<port>:3000 aerospike:<version>

// Example (the host will be defined as localhost by default)
$ docker run -d --name aerospike -e "NAMESPACE=prebid_cache" -p 3000:3000 aerospike:ce-6.4.0.2_1
```

(2.3) Make sure that the Aerospike and/or Redis is up and running
```bash
$ docker ps
```

(3). Start the Maven build
Expand Down