You can configure pre-receive hooks on the Node.js server to enable process enforcement
between Git and Rational Team Concert.
About this task
The following steps assume that the Git repositories are present in
/var/gitrepos on a Linux system. Repeat this task for each Git repository.
Procedure
-
Copy the pre-receive hook file from
rtc-git-integration-toolkit-install-folder/server/hooks/examples/pre-receive
to /var/gitrepos/repository-name/hooks.
-
Assign executable permission to the file:
chmod +x pre-receive.
-
Open the pre-receive file in a text editor and set the following environment variables:
| Environment variable |
Description |
| NODE_EXECUTABLE |
Absolute path to the node executable. Required if node executable cannot be found in the
system path. |
| RTC_GIT_SERVER_TOOLKIT_PATH |
Absolute path to the folder where the RTC Git Integration Toolkit has been
installed. |
| RTC_GIT_SERVER_TRACE_LEVEL |
Logging level for the hooks. Set this value to 4 while you set up
the integration. Revert it after you validate the integration. |