Skip to content

UpdateConfig

Synopsis

Update basic configuration.

Description

This action will modify, create, or delete configuration elements in Asterisk configuration files.

Syntax

    Action: UpdateConfig
    ActionID: <value>
    SrcFilename: <value>
    DstFilename: <value>
    Reload: <value>
    PreserveEffectiveContext: <value>
    Action-000000: <value>
    Cat-000000: <value>
    Var-000000: <value>
    Value-000000: <value>
    Match-000000: <value>
    Line-000000: <value>
    Options-000000: <value>
Arguments
  • ActionID - ActionID for this transaction. Will be returned.

  • SrcFilename - Configuration filename to read (e.g. foo.conf).

  • DstFilename - Configuration filename to write (e.g. foo.conf)

  • Reload - Whether or not a reload should take place (or name of specific module).

  • PreserveEffectiveContext - Whether the effective category contents should be preserved on template change. Default is true (pre 13.2 behavior).

  • Action-000000 - Action to take.
    0's represent 6 digit number beginning with 000000.

    • NewCat

    • RenameCat

    • DelCat

    • EmptyCat

    • Update

    • Delete

    • Append

    • Insert

  • Cat-000000 - Category to operate on.
    0's represent 6 digit number beginning with 000000.

  • Var-000000 - Variable to work on.
    0's represent 6 digit number beginning with 000000.

  • Value-000000 - Value to work on.
    0's represent 6 digit number beginning with 000000.

  • Match-000000 - Extra match required to match line.
    0's represent 6 digit number beginning with 000000.

  • Line-000000 - Line in category to operate on (used with delete and insert actions).
    0's represent 6 digit number beginning with 000000.

  • Options-000000 - A comma separated list of action-specific options.

    • NewCat - One or more of the following...

      • allowdups - Allow duplicate category names.

      • template - This category is a template.

      • inherit="template[,...]" - Templates from which to inherit.

        The following actions share the same options...

    • RenameCat

    • DelCat

    • EmptyCat

    • Update

    • Delete

    • Append

    • Insert -

      • catfilter="<expression>[,...]" -
        A comma separated list of name_regex=value_regex expressions which will cause only categories whose variables match all expressions to be considered. The special variable name 'TEMPLATES' can be used to control whether templates are included. Passing 'include' as the value will include templates along with normal categories. Passing 'restrict' as the value will restrict the operation to ONLY templates. Not specifying a 'TEMPLATES' expression results in the default behavior which is to not include templates.
        catfilter is most useful when a file contains multiple categories with the same name and you wish to operate on specific ones instead of all of them.
        0's represent 6 digit number beginning with 000000.

See Also

Generated Version

This documentation was generated from Asterisk branch 16 using version GIT