fcrepo-exts / fcrepo-camel-toolbox

A collection of ready-to-use messaging applications with fcrepo-camel
Apache License 2.0
13 stars 26 forks source link

Update reindexing usage text #183

Closed claussni closed 2 years ago

claussni commented 2 years ago

JIRA Ticket: https://fedora-repository.atlassian.net/browse/FCREPO-3804

What does this Pull Request do?

Add note about potential hostname issues while running in a Docker environment. Checks for Docker environment using undocumented 'hack' by looking for the presence of .dockerenv file.

What's new?

Add a new class DockerRunningProcessor which potentially detects the presence of a Docker environment and sets a specific Camel Exchange header.

How should this be tested?

Running outside of Docker should print the /reindexing usage message as before. Running inside a Docker environment supplements the /reindexing usage message with a Docker specific note.

Additional Notes:

There is no standard way of checking for a container environment. It all depends on the presence of the undocumented .dockerenv file which might disappear in future docker releases. This however, seems unlikely because it's a very common way of checking for Docker.

Interested parties

@dbernstein

claussni commented 2 years ago

Fixed it.