Skip to content

Instantly share code, notes, and snippets.

@cbrunnkvist
Last active October 5, 2020 10:29
Show Gist options
  • Save cbrunnkvist/e3de055e65b3a6142d1ecdb5ad493ae6 to your computer and use it in GitHub Desktop.
Save cbrunnkvist/e3de055e65b3a6142d1ecdb5ad493ae6 to your computer and use it in GitHub Desktop.
Allow stubbing ADP client log directory with (and without-) Docker Compose
version: "3.5"
services:
with-adp-messaging:
image: cmd.cat/grep
command: sh -c "mount|egrep --color=always 'adp-messaging|^'"
volumes:
# THIS IS THE IMPORTANT LINE - defaults to /var/log/adp-messaging when env is undefined
- ${ADP_MESSAGING_LOG_DIR:-/var/log/adp-messaging}:/var/log/adp-messaging
# Ref:
# https://confluence.agodadev.io/display/ADPMES/Changing+JVM+Messaging+Client+Configurations
export ADP_MESSAGING_LOG_DIR=/tmp
# or if you need to be more fancy:
export ADP_MESSAGING_LOG_DIR=$(mktemp -d)
# yay, I can now also start sbt run / sbt test on my dev machine without having to sudo mkdir chmod chown anything.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment