notify

The ClearCase® notify utility allows you to send notifications (typically emails) to team members about specific events or changes within a ClearCase® environment. From DevOps Code ClearCase® 11.0.0.3, notify can send mail using secure e-mail relays that use TLS to encrypt the emails.

Notify has an additional mode, which is used to save user credentials and other options to the configuration files.

Applicability

Product

Command type

ClearCase®

command

Platform

UNIX

Linux

Windows

Synopsis

  • notify [ -t ] [ -s e-mail subject ] recipient@example.com
  • notify -config -host smtp-server.example.com -p smtp-port [ -tls ] [ -username smtp-login ] [ -sender sender-email@example.com ] [ -password password ]
  • notify -sys -show_sys_config
  • notify -cred -register -host smtp-server.example.com -port smtp-port [ -tls ] [ -username smtp-login ] [ -sender sender-email@example.com ] [ -password password ]
  • notify -cred -list
  • notify -cred -search -host smtp-server.example.com -port smtp-port [ -tls ]
  • notify -cred -remove -host smtp-server.example.com -port smtp-port [-tls]

Description

For more information on notify, see technote 326081.

Sending e-mail using secure relays​

The CA certificate used by the secure e-mail server must be imported into the keystore (this is not applicable to the more common insecure relays):​

  • On UNIX-like systems, the CA certificate must be appended to cacert.pem​:

    /var/adm/clearcase/config/cacert.pem

  • On Windows, it has to be imported to the IBM GSKit keystore:​

    • For ClearCase® 11.0.0.3, the pathname for keystore is cc-installation-dir\var\config\TrustedCertificateAuthorities.kdb. For example:

      Example - gsk8capicmd_64" -cert -add -stashed -db "clearcase-installation-dir\var\config\TrustedCertificateAuthorities.kdb" -label CACert_Email -format ascii -trust enable -file "path\to\cacert.pem"​

System-wide credential configuration

To store the system-wide configuration, run the command:

notify –config –host smtp-hostname -port smtp-port -tls –sender sender-email -username smtp-username -password password​

Notes:
  • All options other than host name and port are optional.​
  • If a password is provided, it is encrypted and saved in the configuration file​.
  • Superuser privileges are required to store the system-wide configuration​.

To view the system-wide configuration​, run the command:

notify –sys –show_sys_config​

If a password was saved, an encrypted password is printed on the screen.​

Per-user credential configuration

  • To store per-user configuration,​ run the command:
    notify –cred –register –hostname smtp-hostname -port smtp-port -tls -username smtp-username 
    -sender sender-email -password password
    • -tls, -username, -sender, and –password are optional.​

      The per-user configuration takes precedence over and overrides the system-wide configuration. For example, if an option, such as sender-email exists in both configurations or only in the per-user configuration, the value from the per-user configuration is used. The system-wide configuration is only applied if the option is not available in the per-user configuration.​

  • To list the per-user credentials saved,​ run the command:
    notify –cred –list​
  • To delete a set of saved credentials,​ run the command:

    notify –cred –delete –hostname smtp-hostname -port smtp-port​
  • To replace a saved credential,​ run the command:
    notify –cred –replace –hostname smtp-hostname -port smtp-port -tls –username smtp-username 
    -sender sender-email -password password​
    The purpose is to replace the details like user name and password for a host name or port combination.​
  • To search the saved credentials for a specific one,​ run the command:
    notify –cred –search –hostname smtp-hostname -port smtp-port
    This command helps identify whether a credential exists in the user-specific credential store.

Restrictions

None.

Options and arguments

Default
None.
-t
Enable tracing.
-s {recipient}
Specify the email recipient.
-config
Set up the system-wide credential configuration.
-hostname {smtp-server}
Specify the smtp server host.
-port {port-number}
Specify the smtp server port.
-tls
Enable tls.
-username {smtp-login}
Specify the login user name for the smtp server (only if tls is on).
-sender {sender-email}
Specify the sender email.
-password {password}
Specify the login password for the smtp server (only if tls is on).
-sys -show_sys_config
Show the current set of system-wide credentials.
-cred -register
Register the user-specific credentials for the host, port, and tls combination described by the subsequent arguments.
-cred -search
Search for the user-specific credentials for the host, port, and tls combination described by the subsequent arguments.
-cred -list
List all available user-specific credentials.
-cred -remove
Remove the credentials specified by the host, port, and tls combination in the subsequent arguments.

Examples

For example, the commands -t Trace, -s email-subject, and so on are used for sending emails.

See also

None.