servicectl

Name

servicectl -- manage and query wigwam services

Synopsis

servicectl [start | stop | status | test | restart] [service...]

servicectl start [service...]

servicectl stop [service...]

servicectl restart [service...]

servicectl status [service...]

servicectl test [service...]

servicectl new-service [service]

servicectl check-config [role | cluster] [--verbose | --script] [cluster_or_role_name]

Description

Like cvs, servicectl really encapsulates several different functions. If a list of services is specified, only those services are affected; otherwise the command operates on all the services defined for your current role, which is specified in $PLAYPEN_ROOT/etc/role. This may be overridden by PLAYPEN_ROLE in the environment.

The role's services are specified as a shell variable, playpen_services, in $PLAYPEN_ROOT/etc/roles/$ROLE/config.

servicectl start

Start the services.

servicectl stop

Stop the services.

servicectl status

Check the status of the services according to their pid files. Normally these are in LOCAL_RUNVAR, which is usually LOCAL_VAR/run named SERVICE.pid.

servicectl test

Check the status of the services, using their provided self-test scripts (or you can place such a script in your project, in the services/$SERVICE_NAME directory).

servicectl restart

Restart the specified services, using SIGHUP if they take it, or their own restart script, or by stopping and starting the service.

After restarting:

servicectl check-config

Find out what environment variables are still left to be configured in the project for each service.

You can use the --verbose flag to print out descriptions of missing environment variables.

You can use the --script flag to make a script that will set the missing environments to their default values.

servicectl new-service

Mark a service as available in the project. Used internally by the packaging system.