# Default configuration structure for sneakernet # This file is loaded by the sneakernet script to provide default configuration values # Variables from $programDefinition hashref (scriptDirectory, scriptFullPath) will be interpolated at runtime { 'dryrun' => 0, # if set to 1, will not perform any changes, just log what would be done 'verbosity' => 1, # verbosity level for logging 'debug' => 0, # set to number greater than 0 for debugging program 'statusFile' => "/sneakernet_target.status", # file created on source server to track last copied dataset 'logFile' => ".log", 'displayLogsOnTTY' => '', # if set to path of a tty, log messages will be sent there also. Example: /dev/ttyv1 'displayLogsOnConsole' => 1, # If set to non-zero, will send log messages to screen in addition to log file 'source' => { # information about source server 'hostname' => '', # used to see if we are on source 'poolname' => 'pool', # name of the ZFS default parent pool to export 'cleanUpScriptsDir' => '/cleanupScripts', # location on disk where scripts to be sent to target are located 'report' => { # if set, will generate a report via email or by storing on a drive 'email' => '', # if set, will email the report to this address 'subject' => '', # subject of the report email (will be auto-generated if empty) 'targetDrive' => { # if set, will store the report on this drive 'label' => '', # the GPT or msdos label of the report drive, REQUIRED 'fstype' => '', # filesystem type of the report drive, default is msdos 'checkInterval' => 15, # how often to check for the disk (seconds), message displayed every interval 'waitTimeout' => 300, # time to wait for the disk to appear in seconds 'mountPoint' => '', # where to mount the report drive, default is /mnt/label } } }, 'target' => { # information about target server 'hostname' => '', # used to see if we are on target 'poolname' => '', # name of the ZFS pool to import 'stateFile' => "/states/targetState", # A list of snapshots will be placed here before any changes 'cleanUpScriptsDir' => 'cleanUpScripts', # relative path on transport drive containing encrypted Perl scripts to run after target update (e.g., 'cleanup_scripts') 'shutdownAfterReplication' => 0, # if set to 1, will shutdown the server after replication 'geli' => { # if this is set, the dataset uses GELI. Not required if zpool is already imported 'secureKey ' => { # where to load part of the GELI key from 'label' => '', # the GPT label of the key disk 'fstype' => '', # filesystem type of the key disk (msdos or ufs) 'checkInterval' => 15, # how often to check for the disk (seconds), message displayed every interval 'waitTimeout' => 300, # time to wait for the disk to appear in seconds 'keyfile' => 'geli.key', # the name of the key file on the secureKey disk }, 'localKey' => '', # hex representation of the local key part 'target' => '', # location to create the combined keyfile 'poolname' => '', # name of the ZFS pool to import, probably same as target.poolname 'diskList' => [ # list of disks to try to mount the dataset from. default is to check for all unmounted and unpartitioned disks #'da0', #'da1' ], }, 'report' => { # if enabled, will send a report after replication 'email' => '', # if set, will email the report to this address 'subject' => '', # subject of the report email (will be auto-generated if empty) 'targetDrive' => { # if set, will store the report on this drive 'fstype' => 'msdos', # filesystem type of the report drive 'label' => '', # the GPT or msdos label of the report drive 'mountPoint' => '', # where to mount the report drive, default is /mnt/label } } }, 'transport' => { # configuration for the transport disk 'label' => 'sneakernet', # this is the GPT label of the sneakernet disk, REQUIRED 'fstype' => 'ufs', # this is the file system type. default is ufs 'mountPoint' => '/mnt/sneakernet', # where we want to mount it, default is /mnt/label 'datasetDir' => 'datasets', # subdirectory on transport disk for storing dataset files 'serialFile' => 'serial.txt', # name of the serial file on transport disk to track processing status 'timeout' => 600, # amount of time to wait for the disk to appear, in seconds. Default 600 seconds (10 minutes) 'checkInterval' => 15, # How often to check for the disk (seconds), message displayed every interval, default 15 seconds 'encryptionKey' => '', # if set, all files will be encrypted with this key during transport. Generate with: openssl rand 32 | xxd -p | tr -d '\n' }, 'datasets' => { # datasets to replicate 'dataset1' => { 'source' => 'pool', # the parent of the dataset on the source 'target' => 'backup', # the parent of the dataset on the target 'dataset' => 'dataset1', # the dataset name }, #'files_share' => { # 'source' => 'pool', # 'target' => 'backup', # 'dataset' => 'files_share', #}, }, }