def _register_sensor_container_opts(ignore_errors=False): logging_opts = [ cfg.StrOpt('logging', default='conf/logging.sensorcontainer.conf', help='location of the logging.conf file') ] st2cfg.do_register_opts(logging_opts, group='sensorcontainer', ignore_errors=ignore_errors) # Partitioning options partition_opts = [ cfg.StrOpt('sensor_node_name', default='sensornode1', help='name of the sensor node.'), cfg.Opt('partition_provider', type=types.Dict(value_type=types.String()), default={'name': DEFAULT_PARTITION_LOADER}, help='Provider of sensor node partition config.') ] st2cfg.do_register_opts(partition_opts, group='sensorcontainer', ignore_errors=ignore_errors) # Other options other_opts = [ cfg.BoolOpt( 'single_sensor_mode', default=False, help= 'Run in a single sensor mode where parent process exits when a sensor crashes / ' 'dies. This is useful in environments where partitioning, sensor process life ' 'cycle and failover is handled by a 3rd party service such as kubernetes.' ) ] st2cfg.do_register_opts(other_opts, group='sensorcontainer', ignore_errors=ignore_errors) # CLI options cli_opts = [ cfg.StrOpt( 'sensor-ref', help= 'Only run sensor with the provided reference. Value is of the form ' '<pack>.<sensor-name> (e.g. linux.FileWatchSensor).'), cfg.BoolOpt( 'single-sensor-mode', default=False, help= 'Run in a single sensor mode where parent process exits when a sensor crashes / ' 'dies. This is useful in environments where partitioning, sensor process life ' 'cycle and failover is handled by a 3rd party service such as kubernetes.' ) ] st2cfg.do_register_cli_opts(cli_opts, ignore_errors=ignore_errors)
def _register_sensor_container_opts(ignore_errors=False): logging_opts = [ cfg.StrOpt('logging', default='conf/logging.sensorcontainer.conf', help='location of the logging.conf file') ] st2cfg.do_register_opts(logging_opts, group='sensorcontainer', ignore_errors=ignore_errors) sensor_test_opt = cfg.StrOpt('sensor-name', help='Only run sensor with the provided name.') st2cfg.do_register_cli_opts(sensor_test_opt, ignore_errors=ignore_errors) st2_webhook_opts = [ cfg.StrOpt('host', default='0.0.0.0', help='Host for the st2 webhook endpoint.'), cfg.IntOpt('port', default='6000', help='Port for the st2 webhook endpoint.'), cfg.StrOpt('url', default='/webhooks/st2/', help='URL of the st2 webhook endpoint.') ] st2cfg.do_register_opts(st2_webhook_opts, group='st2_webhook_sensor', ignore_errors=ignore_errors) generic_webhook_opts = [ cfg.StrOpt('host', default='0.0.0.0', help='Host for the generic webhook endpoint.'), cfg.IntOpt('port', default='6001', help='Port for the generic webhook endpoint.'), cfg.StrOpt('url', default='/webhooks/generic/', help='URL of the st2 webhook endpoint.') ] st2cfg.do_register_opts(generic_webhook_opts, group='generic_webhook_sensor', ignore_errors=ignore_errors)
def _register_sensor_container_opts(ignore_errors=False): logging_opts = [ cfg.StrOpt('logging', default='conf/logging.sensorcontainer.conf', help='location of the logging.conf file') ] st2cfg.do_register_opts(logging_opts, group='sensorcontainer', ignore_errors=ignore_errors) partition_opts = [ cfg.StrOpt('sensor_node_name', default='sensornode1', help='name of the sensor node.'), cfg.Opt('partition_provider', type=types.Dict(value_type=types.String()), default={'name': DEFAULT_PARTITION_LOADER}, help='Provider of sensor node partition config.') ] st2cfg.do_register_opts(partition_opts, group='sensorcontainer', ignore_errors=ignore_errors) sensor_test_opt = cfg.StrOpt( 'sensor-ref', help='Only run sensor with the provided reference. \ Value is of the form pack.sensor-name.') st2cfg.do_register_cli_opts(sensor_test_opt, ignore_errors=ignore_errors)
def _register_cli_opts(): cli_opts = [ cfg.StrOpt('timestamp', default=None, help='Will delete trigger instances older than ' + 'this UTC timestamp. ' + 'Example value: 2015-03-13T19:01:27.255542Z') ] do_register_cli_opts(cli_opts)
def _register_cli_opts(): cli_opts = [ cfg.StrOpt('schema-path', default=None, required=True, help='Path to the config schema to use for validation.'), cfg.StrOpt('config-path', default=None, required=True, help='Path to the config file to validate.'), ] do_register_cli_opts(cli_opts)
def _register_cli_opts(): cli_opts = [ cfg.StrOpt( "timestamp", default=None, help="Will delete trace instances older than " + "this UTC timestamp. " + "Example value: 2015-03-13T19:01:27.255542Z", ) ] do_register_cli_opts(cli_opts)
def _register_cli_opts(): cli_opts = [ cfg.StrOpt('rule', default=None, help='Path to the file containing rule definition.'), cfg.StrOpt('rule-ref', default=None, help='Ref of the rule.'), cfg.StrOpt('trigger-instance', default=None, help='Path to the file containing trigger instance definition'), cfg.StrOpt('trigger-instance-id', default=None, help='Id of the Trigger Instance to use for validation.') ] do_register_cli_opts(cli_opts)
def _register_cli_opts(): cli_opts = [ cfg.MultiStrOpt('pack', default=None, required=True, positional=True, help='Name of the pack to install (download).'), cfg.BoolOpt('verify-ssl', default=True, help=('Verify SSL certificate of the Git repo from which the pack is ' 'installed.')), cfg.BoolOpt('force', default=False, help='True to force pack download and ignore download ' 'lock file if it exists.'), ] do_register_cli_opts(cli_opts)
def _register_cli_opts(): cli_opts = [ cfg.MultiStrOpt('pack', default=None, required=True, positional=True, help='Name of the pack to install (download).'), cfg.BoolOpt('verify-ssl', default=True, help=('Verify SSL certificate of the Git repo from which the pack is ' 'installed.')), cfg.BoolOpt('force', default=False, help='True to force pack download and ignore download ' 'lock file if it exists.'), cfg.BoolOpt('use-python3', default=False, help='True to use Python3 binary.') ] do_register_cli_opts(cli_opts)
def _register_cli_opts(): cli_opts = [ cfg.MultiStrOpt('pack', default=None, required=True, positional=True, help='Name of the pack to setup the virtual environment for.'), cfg.BoolOpt('update', default=False, help=('Check this option if the virtual environment already exists and if you ' 'only want to perform an update and installation of new dependencies. If ' 'you don\'t check this option, the virtual environment will be destroyed ' 'then re-created. If you check this and the virtual environment doesn\'t ' 'exist, it will create it..')), cfg.BoolOpt('python3', default=False, help='Use Python 3 binary when creating a virtualenv for this pack.'), ] do_register_cli_opts(cli_opts)
def _register_cli_opts(): cli_opts = [ cfg.MultiStrOpt('pack', default=None, required=True, positional=True, help='Name of the pack to install.'), cfg.BoolOpt('verify-ssl', default=True, help=('Verify SSL certificate of the Git repo from which the pack is ' 'downloaded.')), cfg.BoolOpt('force', default=False, help='True to force pack installation and ignore install ' 'lock file if it exists.'), cfg.BoolOpt('use-python3', default=False, help='True to use Python3 binary when creating virtualenv ' 'for this pack.'), ] do_register_cli_opts(cli_opts)
def _register_sensor_container_opts(ignore_errors=False): logging_opts = [ cfg.StrOpt( 'logging', default='/etc/st2/logging.sensorcontainer.conf', help='location of the logging.conf file') ] st2cfg.do_register_opts(logging_opts, group='sensorcontainer', ignore_errors=ignore_errors) # Partitioning options partition_opts = [ cfg.StrOpt( 'sensor_node_name', default='sensornode1', help='name of the sensor node.'), cfg.Opt( 'partition_provider', type=types.Dict(value_type=types.String()), default={'name': DEFAULT_PARTITION_LOADER}, help='Provider of sensor node partition config.') ] st2cfg.do_register_opts(partition_opts, group='sensorcontainer', ignore_errors=ignore_errors) # Other options other_opts = [ cfg.BoolOpt( 'single_sensor_mode', default=False, help='Run in a single sensor mode where parent process exits when a sensor crashes / ' 'dies. This is useful in environments where partitioning, sensor process life ' 'cycle and failover is handled by a 3rd party service such as kubernetes.') ] st2cfg.do_register_opts(other_opts, group='sensorcontainer', ignore_errors=ignore_errors) # CLI options cli_opts = [ cfg.StrOpt( 'sensor-ref', help='Only run sensor with the provided reference. Value is of the form ' '<pack>.<sensor-name> (e.g. linux.FileWatchSensor).'), cfg.BoolOpt( 'single-sensor-mode', default=False, help='Run in a single sensor mode where parent process exits when a sensor crashes / ' 'dies. This is useful in environments where partitioning, sensor process life ' 'cycle and failover is handled by a 3rd party service such as kubernetes.') ] st2cfg.do_register_cli_opts(cli_opts, ignore_errors=ignore_errors)
def _register_cli_opts(): cli_opts = [ cfg.StrOpt( "timestamp", default=None, help="Will delete workflow task execution objects older than " + "this UTC timestamp. " + "Example value: 2015-03-13T19:01:27.255542Z.", ), cfg.BoolOpt( "purge-incomplete", default=False, help="Purge all models irrespective of their ``status``." + "By default, only workflow task executions in completed states such as " + '"succeeeded", "failed", "canceled" and "timed_out" are deleted.', ), ] do_register_cli_opts(cli_opts)
def _register_sensor_container_opts(ignore_errors=False): logging_opts = [ cfg.StrOpt('logging', default='conf/logging.sensorcontainer.conf', help='location of the logging.conf file') ] st2cfg.do_register_opts(logging_opts, group='sensorcontainer', ignore_errors=ignore_errors) partition_opts = [ cfg.StrOpt('sensor_node_name', default='sensornode1', help='name of the sensor node.'), cfg.Opt('partition_provider', type=types.Dict(value_type=types.String()), default={'name': DEFAULT_PARTITION_LOADER}, help='Provider of sensor node partition config.') ] st2cfg.do_register_opts(partition_opts, group='sensorcontainer', ignore_errors=ignore_errors) sensor_test_opt = cfg.StrOpt('sensor-ref', help='Only run sensor with the provided reference. \ Value is of the form pack.sensor-name.') st2cfg.do_register_cli_opts(sensor_test_opt, ignore_errors=ignore_errors)
def _register_cli_opts(): cli_opts = [ cfg.StrOpt( 'timestamp', default=None, help='Will delete execution and liveaction models older than ' + 'this UTC timestamp. ' + 'Example value: 2015-03-13T19:01:27.255542Z.'), cfg.StrOpt('action-ref', default='', help='action-ref to delete executions for.'), cfg.BoolOpt( 'purge-incomplete', default=False, help='Purge all models irrespective of their ``status``.' + 'By default, only executions in completed states such as "succeeeded" ' + ', "failed", "canceled" and "timed_out" are deleted.'), ] do_register_cli_opts(cli_opts)
def _register_cli_opts(): cli_opts = [ cfg.MultiStrOpt( 'pack', default=None, required=True, positional=True, help='Name of the pack to setup the virtual environment for.'), cfg.BoolOpt( 'update', default=False, help= ('Check this option if the virtual environment already exists and if you ' 'only want to perform an update and installation of new dependencies. If ' 'you don\'t check this option, the virtual environment will be destroyed ' 'then re-created. If you check this and the virtual environment doesn\'t ' 'exist, it will create it..')), ] do_register_cli_opts(cli_opts)
def _register_sensor_container_opts(ignore_errors=False): logging_opts = [ cfg.StrOpt('logging', default='conf/logging.sensorcontainer.conf', help='location of the logging.conf file') ] st2cfg.do_register_opts(logging_opts, group='sensorcontainer', ignore_errors=ignore_errors) sensor_test_opt = cfg.StrOpt( 'sensor-name', help='Only run sensor with the provided name.') st2cfg.do_register_cli_opts(sensor_test_opt, ignore_errors=ignore_errors) st2_webhook_opts = [ cfg.StrOpt('host', default='0.0.0.0', help='Host for the st2 webhook endpoint.'), cfg.IntOpt('port', default='6000', help='Port for the st2 webhook endpoint.'), cfg.StrOpt('url', default='/webhooks/st2/', help='URL of the st2 webhook endpoint.') ] st2cfg.do_register_opts(st2_webhook_opts, group='st2_webhook_sensor', ignore_errors=ignore_errors) generic_webhook_opts = [ cfg.StrOpt('host', default='0.0.0.0', help='Host for the generic webhook endpoint.'), cfg.IntOpt('port', default='6001', help='Port for the generic webhook endpoint.'), cfg.StrOpt('url', default='/webhooks/generic/', help='URL of the st2 webhook endpoint.') ] st2cfg.do_register_opts(generic_webhook_opts, group='generic_webhook_sensor', ignore_errors=ignore_errors)
def _register_cli_opts(): cli_opts = [ cfg.MultiStrOpt( "pack", default=None, required=True, positional=True, help="Name of the pack to setup the virtual environment for.", ), cfg.BoolOpt( "update", default=False, help= ("Check this option if the virtual environment already exists and if you " "only want to perform an update and installation of new dependencies. If " "you don't check this option, the virtual environment will be destroyed " "then re-created. If you check this and the virtual environment doesn't " "exist, it will create it.."), ), ] do_register_cli_opts(cli_opts)
def _register_cli_opts(): cli_opts = [ cfg.StrOpt( "timestamp", default=None, help="Will delete execution and liveaction models older than " + "this UTC timestamp. " + "Example value: 2015-03-13T19:01:27.255542Z.", ), cfg.StrOpt("action-ref", default="", help="action-ref to delete executions for."), cfg.BoolOpt( "purge-incomplete", default=False, help="Purge all models irrespective of their ``status``." + 'By default, only executions in completed states such as "succeeeded" ' + ', "failed", "canceled" and "timed_out" are deleted.', ), ] do_register_cli_opts(cli_opts)
def _register_cli_opts(): cli_opts = [ cfg.MultiStrOpt('pack', default=None, required=True, positional=True, help='Name of the pack to install.'), cfg.BoolOpt( 'verify-ssl', default=True, help=( 'Verify SSL certificate of the Git repo from which the pack is ' 'downloaded.')), cfg.BoolOpt('force', default=False, help='True to force pack installation and ignore install ' 'lock file if it exists.'), cfg.BoolOpt('use-python3', default=False, help='True to use Python3 binary when creating virtualenv ' 'for this pack.'), ] do_register_cli_opts(cli_opts)
def _register_cli_opts(): cli_opts = [ cfg.MultiStrOpt( "pack", default=None, required=True, positional=True, help="Name of the pack to install (download).", ), cfg.BoolOpt( "verify-ssl", default=True, help=( "Verify SSL certificate of the Git repo from which the pack is " "installed."), ), cfg.BoolOpt( "force", default=False, help="True to force pack download and ignore download " "lock file if it exists.", ), ] do_register_cli_opts(cli_opts)
def _register_app_opts(ignore_errors=False): available_backends = auth_backends.get_available_backends() auth_opts = [ cfg.StrOpt( "host", default="127.0.0.1", help="Host on which the service should listen on.", ), cfg.IntOpt("port", default=9100, help="Port on which the service should listen on."), cfg.BoolOpt("use_ssl", default=False, help="Specify to enable SSL / TLS mode"), cfg.StrOpt( "cert", default="/etc/apache2/ssl/mycert.crt", help= 'Path to the SSL certificate file. Only used when "use_ssl" is specified.', ), cfg.StrOpt( "key", default="/etc/apache2/ssl/mycert.key", help= 'Path to the SSL private key file. Only used when "use_ssl" is specified.', ), cfg.StrOpt( "logging", default="/etc/st2/logging.auth.conf", help="Path to the logging config.", ), cfg.BoolOpt("debug", default=False, help="Specify to enable debug mode."), cfg.StrOpt( "mode", default=DEFAULT_MODE, help="Authentication mode (%s)" % (",".join(VALID_MODES)), ), cfg.StrOpt( "backend", default=DEFAULT_BACKEND, help="Authentication backend to use in a standalone mode. Available " "backends: %s." % (", ".join(available_backends)), ), cfg.StrOpt( "backend_kwargs", default=None, help= "JSON serialized arguments which are passed to the authentication " "backend in a standalone mode.", ), cfg.BoolOpt("sso", default=False, help="Enable Single Sign On for GUI if true."), cfg.StrOpt( "sso_backend", default=DEFAULT_SSO_BACKEND, help="Single Sign On backend to use when SSO is enabled. Available " "backends: noop, saml2.", ), cfg.StrOpt( "sso_backend_kwargs", default=None, help= "JSON serialized arguments which are passed to the SSO backend.", ), ] st2cfg.do_register_cli_opts(auth_opts, group="auth", ignore_errors=ignore_errors)
def _register_sensor_container_opts(ignore_errors=False): logging_opts = [ cfg.StrOpt( "logging", default="/etc/st2/logging.sensorcontainer.conf", help="location of the logging.conf file", ) ] st2cfg.do_register_opts(logging_opts, group="sensorcontainer", ignore_errors=ignore_errors) # Partitioning options partition_opts = [ cfg.StrOpt("sensor_node_name", default="sensornode1", help="name of the sensor node."), cfg.Opt( "partition_provider", type=types.Dict(value_type=types.String()), default={"name": DEFAULT_PARTITION_LOADER}, help="Provider of sensor node partition config.", ), ] st2cfg.do_register_opts(partition_opts, group="sensorcontainer", ignore_errors=ignore_errors) # Other options other_opts = [ cfg.BoolOpt( "single_sensor_mode", default=False, help= "Run in a single sensor mode where parent process exits when a sensor crashes / " "dies. This is useful in environments where partitioning, sensor process life " "cycle and failover is handled by a 3rd party service such as kubernetes.", ) ] st2cfg.do_register_opts(other_opts, group="sensorcontainer", ignore_errors=ignore_errors) # CLI options cli_opts = [ cfg.StrOpt( "sensor-ref", help= "Only run sensor with the provided reference. Value is of the form " "<pack>.<sensor-name> (e.g. linux.FileWatchSensor).", ), cfg.BoolOpt( "single-sensor-mode", default=False, help= "Run in a single sensor mode where parent process exits when a sensor crashes / " "dies. This is useful in environments where partitioning, sensor process life " "cycle and failover is handled by a 3rd party service such as kubernetes.", ), ] st2cfg.do_register_cli_opts(cli_opts, ignore_errors=ignore_errors)