http-var

Usage: oredge http-var ACTION [OPTIONS]

ACTION:
    create
    list
    show
    modify
    delete

GLOBAL OPTIONS:
    --help
    --show-api                         print restful api request.
    --json                             print json format.
    --config                           specify config file, default is ~/.oredge/config.

Create user variable of HTTP application

Usage: oredge http-var create [http] [OPTIONS]

OPTIONS:
    --http integer                     http id.
    --name string                      name.
    --default bool                     default.
    --type string                      string, enum, num, int, bool.
    --value string                     enum value, can add multiple times.
    --gid integer                      user group id.

GLOBAL OPTIONS:
    --help
    --show-api                         print restful api request.
    --json                             print json format.
    --config                           specify config file, default is ~/.oredge/config.

Example

# oredge http-var create 892 --name a --type string
ID: 892-65

List user variables list

Usage: oredge http-var list [http] [OPTIONS]

OPTIONS:
    --page integer                     page, 1(default).
    --page-size integer                page size, 20(default).
    --http integer                     http id.

GLOBAL OPTIONS:
    --help
    --show-api                         print restful api request.
    --json                             print json format.
    --config                           specify config file, default is ~/.oredge/config.

Example

# oredge http-var list 892
ID        NAME    VALUE    DEFAULT    CREATE TIME            MODIFY TIME
892-64    test             test       2021-07-15 02:45:29    2021-07-15 02:45:29
892-65    a                           2021-07-15 06:12:28    2021-07-15 06:12:28
892-67    b                b          2021-07-15 06:12:54    2021-07-15 06:12:54

Get user variable’s details

Usage: oredge http-var show [id] [OPTIONS]

OPTIONS:
    --id integer                       page, 1(default).

GLOBAL OPTIONS:
    --help
    --show-api                         print restful api request.
    --json                             print json format.
    --config                           specify config file, default is ~/.oredge/config.

Example

# oredge http-var show 892-64
ID         : 64
NAME       : test-a
DEFAULT    : test
CREATE TIME: 2021-07-15 02:45:29
MODIFY TIME: 2021-07-15 06:19:23

Modify user variable

Usage: oredge http-var modify [id] [OPTIONS]

OPTIONS:
    --name string                      name.
    --default bool                     default.
    --type string                      string, enum, num, int, bool.
    --value string                     enum value, can add multiple times.
    --gid integer                      user group id.
    --id integer                       id.

GLOBAL OPTIONS:
    --help
    --show-api                         print restful api request.
    --json                             print json format.
    --config                           specify config file, default is ~/.oredge/config.

Example

# oredge http-var modify 892-64 --name test-a
OK

Delete user variable

# oredge http-var delete --help
Usage: oredge http-var delete [id] [OPTIONS]

OPTIONS:
    --id integer                       id.

GLOBAL OPTIONS:
    --help
    --show-api                         print restful api request.
    --json                             print json format.
    --config                           specify config file, default is ~/.oredge/config.

Example

# oredge http-var delete 892-64
OK