Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Original base file in container (grouperScriptHooksBase.sh)

Code Block
#!/bin/sh

### DO NOT EDIT OR OVERLAY THIS FILE
# These definitions are here to define the functions.
# You can overlay the grouperCustomShellHooksgrouperScriptHooks.sh file with any definitions of these functions

# called at the beginning of the container startup
# after logging is setup
grouperScriptHooks_prepConfPost() {
  return
}

# called after the component command has been prepped
grouperScriptHooks_prepComponentPost() {
  return
}

# called after the finishPrep is called before the setupFiles
grouperScriptHooks_finishPrepPost() {
  return
}

# called after the setupFiles functions is called, almost before the process starts
grouperScriptHooks_setupFilesPost() {
  return
}

# called after the chown at end of setupFiles, right before the process starts
grouperScriptHooks_setupFilesPostChown() {
  return
}


Overlay /usr/local/bin/grouperScriptHooks.sh in subimage or mount

Code Block
#!/bin/sh

# called after the Grouper container config files are generated and massaged
# before the processes are started
grouperScriptHooks_finishPrepPost() {
  sed -i "s|SOMETHING|1234|g" /some/file.conf
  rm /some/path/anotherFile.conf
  echo "another line" >> /yet/another/config.file
  cat /some/append.file >> /yet/anotherAnother/config2.file
}

...