4.4.2 Working with Kickstart Profiles Using spacecmd

To list all Kickstart profiles, use the kickstart_list command.

spacecmd {SSM:0}> kickstart_list
ol6u6-x86_64-minimal

To display the details of a Kickstart profile, use the kickstart_details command.

spacecmd {SSM:0}> kickstart_details ol6u6-x86_64-minimal
Name:        ol6u6-x86_64-minimal
Label:       ol6u6-x86_64-minimal
Tree:        ol6-x86_64-server
Active:      True
Advanced:    False
Org Default: False

Configuration Management: False
Remote Commands:          False

Software Channels
-----------------
ol6u6-x86_64

Advanced Options
----------------
auth --enableshadow --passalgo=sha256
bootloader --location mbr
clearpart --all
firewall --disabled
keyboard us
lang en_US
network --bootproto dhcp
rootpw $5$ZdYXHxbNqu76Q5dG$.KWiOPyrGk8V5q/FEqYbWpCZdD5St387sn7jOyPH400
selinux --permissive
timezone America/New_York
url --url /var/distro-trees/ol6-x86_64-server

Software
--------
@ Base

Crypto Keys
-----------
RHN-ORG-TRUSTED-SSL-CERT

Variables
---------
org = 1

To display the contents of the Kickstart file that a profile generates, use the kickstart_getcontents command.

spacecmd {SSM:0}> kickstart_getcontents ol6u6-x86_64-minimal
# Kickstart config file generated by Spacewalk Config Management
# Profile Label : ol6u6-x86_64-minimal
# Date Created  : 2015-06-11 11:34:15.157666

install
text
network --bootproto dhcp
url --url http://swksvr.mydom.com/ks/dist/ol6-x86_64-server
lang en_US
keyboard us
zerombr
clearpart --all
bootloader --location mbr
timezone America/New_York
auth --enableshadow --passalgo=sha256
rootpw --iscrypted $5$ZdYXHxbNqu76Q5dG$.KWiOPyrGk8V5q/FEqYbWpCZdD5St387sn7jOyPH400
selinux --permissive
reboot
firewall --disabled
skipx
autopart
...

spacecmd provides a large number of commands for managing Kickstart profiles. Use the help command to find out more information, for example:

spacecmd {SSM:0}> help

Documented commands (type help <topic>):
========================================
...              
kickstart_addactivationkeys
kickstart_addchildchannels
kickstart_addcryptokeys
kickstart_addfilepreservations
kickstart_addoption
kickstart_addpackages
kickstart_addscript
kickstart_addvariable
kickstart_clone
kickstart_create
kickstart_delete
kickstart_details
kickstart_diff
kickstart_disableconfigmanagement
kickstart_disableremotecommands
kickstart_enableconfigmanagement
kickstart_enablelogging
kickstart_enableremotecommands
kickstart_export
kickstart_getcontents
kickstart_getupdatetype
kickstart_import
kickstart_import_raw
kickstart_importjson
kickstart_list
kickstart_listactivationkeys
kickstart_listchildchannels
kickstart_listcryptokeys
kickstart_listcustomoptions
kickstart_listoptions
kickstart_listpackages
kickstart_listscripts
kickstart_listvariables
kickstart_removeactivationkeys
kickstart_removechildchannels
kickstart_removecryptokeys
kickstart_removefilepreservations
kickstart_removeoptions
kickstart_removepackages
kickstart_removescript
kickstart_removevariables
kickstart_rename
kickstart_setcustomoptions
kickstart_setdistribution
kickstart_setlocale
kickstart_setpartitions
kickstart_setselinux
kickstart_setupdatetype
kickstart_updatevariable
...
spacecmd {SSM:0}> help kickstart_create
kickstart_create: Create a Kickstart profile
usage: kickstart_create [options]

options:
  -n NAME
  -d DISTRIBUTION
  -p ROOT_PASSWORD
  -v VIRT_TYPE ['none', 'para_host', 'qemu', 'xenfv', 'xenpv']