Command Line Options

Top  Previous  Next

In addition to the standard start, stop, and restart options, the cp30c program supports some other control features to help bootstrap or manage an installation.  Most of these options require that you be logged in as "root" on Linux as an Administrator on Windows.

 

All errors are reported in the syntax "Error: message", providing a pattern to watch for.

 

Optional parameters are shown in brackets ([]).  Do not include the brackets in the command line.

 

Option lists separated by pipes (|) indicate one of the values should be used.

 

Options in italic type indicate variable values you supply.  Options with normal type must be entered as shown.

 

Options that contain spaces or operating system shell characters should be quoted.  It never hurts to quote an option.

 

Common options used by many command lines include:

 

-profile profileid to set the profile to be used for profile-specific commands

-pretty changes JSON output to use indention and line breaks for easier readability

-withpassword | -withpass | -wp indicates output that might contain passwords should display the password values, which are otherwise suppressed

-csv|-tsv changes the format of lists to comma-separated values or tab-separated values, instead of the default JSON format

-o "filename" send results to the named file instead of the screen or standard output.  To throw away output, you can use "nul", "null", or "/dev/null" as a filename, interchangeably on any operating system.

-z|-zx "filename" reads the specified text file for further command line arguments.  Any white space, including line breaks, delimit argument values.  If -zx is used, the file is immediately removed after reading.  Use this feature to protect command line elements from being visible in operating system process lists.

 

 

These options do not require a root or Administrator login:

 

cp30c -v        Displays a version message

 

cp30c -version        Displays a more verbose version message

 

cp30c -submit filename -target|-targets "loc1:dev1;loc2:dev2;..." -profile profile [-props "name1=val1;name2=val2;..."] [-delete]

Submits the file to the specified target or targets through the specified profile (using the profile's login), optionally with the specified job properties.  The action is always logged.  The targets are identified by location id and device id, and must exist within the company associated with the profile.

 

Since the client always runs in its install directory, the filename should generally be a full path.

 

If the -delete option is included, filename is removed once uploaded.

 

 

Admin Only Options

These options are only supported when logged in as root (Linux) or an administrator (Windows):

 

cp30c start | stop | restart starts, stops, or stops/starts the client service.

 

cp30c -passcode generates a temporary passcode for the client browser interface.  The code is displayed, and can be used to access the browser interface for approximately 10 minutes.  Once entered, a session is established that lasts 12 hours.

 

cp30c -get profile -profile profileid options

Returns the profile as a JSON object.  Use -withpass to display the password.

 

cp30c -put profile -profile profileid options

Updates or adds the profile record with the specified options

 

Options

-name "value"

-inactive | -!inactive - makes the profile inactive or active

-url | -server "server-url" - the http/https URL to the CirrusPrint server, including port, such as "https://example.com:27083".  If no protocol is provided, "https://" is assumed.

-login "locid@compid" - the location id and company login

-password "password"

-allowinsecure | -!allowinsecure - enables/disables access to a server using a self-signed certificate

 

cp30c -delete -profile profileid

This removes a profile.  The default profile cannot be deleted.

 

 

cp30c -list profiles options

Lists profiles based on these options:

 

-csv | -tsv - list is in comma-separated or tab-separated format, instead of the default JSON array of objects

-pretty - if JSON format, makes the output more readable

-withpass - enables passwords to be included in the list

 

cp30c -export filename

Exports a decrypted version of any file stored encrypted on disk by CirrusPrint.  Use a full path, or a path relative to the CirrusPrint installation location.