configchannel

The following spacecmd commands are available for use with configuration channels.

1. configchannel_addfile

Creates a configuration file.

usage: configchannel_addfile [CHANNEL] [options]

options:
  -c CHANNEL
  -p PATH
  -r REVISION
  -o OWNER [default: root]
  -g GROUP [default: root]
  -m MODE [defualt: 0644]
  -x SELINUX_CONTEXT
  -d path is a directory
  -s path is a symlink
  -b path is a binary (or other file which needs base64 encoding)
  -t SYMLINK_TARGET
  -f local path to file contents

  Note re binary/base64: Some text files, notably those containing trailing newlines, those containing ASCII escape characters (or other charaters not allowed in XML) need to be sent as binary (-b). Some effort is made to auto- detect files which require this, but you may need to explicitly specify.

2. configchannel_backup

Backup a configuration channel.

usage: configchannel_backup CHANNEL [OUTDIR]

OUTDIR defaults to $HOME/spacecmd-backup/configchannel/YYYY-MM-DD/CHANNEL

3. configchannel_clone

Clone configuration channels.

usage examples:
                 configchannel_clone foo_label -c bar_label
                 configchannel_clone foo_label1 foo_label2 -c prefix
                 configchannel_clone foo_label -x "s/foo/bar"
                 configchannel_clone foo_label1 foo_label2 -x "s/foo/bar"

options:
  -c CLONE_LABEL : name/label of the resulting cc (note does not update
                   description, see -x option), treated as a prefix if
                   multiple keys are passed
  -x "s/foo/bar" : Optional regex replacement, replaces foo with bar in the
                   clone name, label and description
  Note : If no -c or -x option is specified, interactive is assumed

4. configchannel_create

Create a configuration channel.

usage: configchannel_create [options]

options:
  -n NAME
  -l LABEL
  -d DESCRIPTION

5. configchannel_delete

Delete a configuration channel.

使用方法: configchannel_delete チャンネル ...

6. configchannel_details

Show the details of a configuration channel.

使用方法: configchannel_details チャンネル ...

7. configchannel_diff

Find differences between configuration channels.

使用方法: configchannel_diff チャンネル_1 チャンネル_2

8. configchannel_export

Export configuration channels to a json formatted file.

usage: configchannel_export <CHANNEL>... [options]
options:
    -f outfile.json : specify an output filename, defaults to <CHANNEL>.json
                      if exporting a single channel, ccs.json for multiple
                      channels, or cc_all.json if no CHANNEL specified
                      e.g (export ALL)

Note : CHANNEL list is optional, default is to export ALL

9. configchannel_filedetails

Show the details of a file in a configuration channel.

使用方法: configchannel_filedetails チャンネル ファイル [リビジョン]

10. configchannel_forcedeploy

Forces a redeployment of files within a channel on all subscribed systems.

使用方法: configchannel_forcedeploy チャンネル

11. configchannel_import

Import configuration channels from a json file.

使用方法: configchannel_import <JSONファイル...>

12. configchannel_list

List all configuration channels.

使用方法: configchannel_list

13. configchannel_listfiles

List all files in a configuration channel.

使用方法: configchannel_listfiles チャンネル ...

14. configchannel_listsystems

List all systems subscribed to a configuration channel.

使用方法: configchannel_listsystems チャンネル

15. configchannel_removefiles

Remove configuration files.

usage: configchannel_removefile CHANNEL <FILE ...>

16. configchannel_sync

Sync configuration files between two configuration channels.

使用方法: configchannel_sync 同期元チャンネル 同期先チャンネル

17. configchannel_updatefile

Update a configuration file.

usage: configchannel_updatefile CHANNEL FILE

18. configchannel_verifyfile

Verify a configuration file.

使用方法: configchannel_verifyfile チャンネル ファイル <システム>

<SYSTEMS> may be substituted with any of the following targets: name ssm (see 'help ssm') search:QUERY (see 'help system_search') group:GROUP channel:CHANNEL