Search

vcli vclgroup

Handle VCLGroup

Synopsis

Handle VCLGroup such as listing, add, delete or update.

Examples:

# List VCL Files
vcli vclgroups list
# List with Filter
vcli vclgroups list -f name="*MyVCL*"
# Raw API output for a VCLGroup
vcli vclgroups inspect 1
# Create VCLGroups with tags and as root deployed
vcli vclgroups add MyVCLGroupName --tags id=1,2 --root
# Create with multiple tag groups
vcli vclgroups add MyVCLGroupName --tags name=prod,eu --tags name=prod,us
# Update VCLGroups
vcli vclgroups update 1 --name newName --root=false
# Update to use a specific routing-rule
vcli vclgroups update 1 --rr 1
# Clear routing-rule from an existing VCLGroup
vcli vclgroups update 1 --clear-rr
# Deploy VCLGroup using Git
vg add test --tags id=1 --domains 1 --git-branch master --git-repo 1 --git-main main.vcl
# Clear Git configuration from a VCLGroup
vcli vg u 1 --clear-git
# Delete VCLGroups
vcli vclgroups delete 1
# Validate a VCLGroup placement with agents to make sure it doesn't
# collide with other domains/VCLGroups that are deployed.
vcli vg validate 1  --vcl 1:2 --root=true
# Test compile a set of given files for a VCLGroup
vcli vg compile 1 --vcl 1:latest --includes 2:latest
# Deploy VCLGroups with main VCL and include files
vcli vclgroups deploy 1 --vcl 1:latest --includes 1:2
# Deploy VCLGroup with last deployed files and wait max 60s
vcli vclgroups deploy 1 -w 60s
# Deploy VCLGroup with last deployed files and wait max 60s and to at least 50% deployed.
vcli vclgroups deploy 1 -w 60s -p 50
# Deploy the latest version of the main VCL to a VCLGroup without specifying all files.
vcli vclgroups deploy-files 1 --vcl 1:latest
# Deploy specific file version to a VCLGroup without specifying all files and main VCL.
vcli vclgroups deploy-files 1 --includes 1:2
# Remove a file from a VCLGroup and deploy.
vcli vclgroups deploy-files 1 --remove-includes 1
# Rollback a VCLGroup to last deployed files
vcli vclgroups rollback 1
# Rollback a VCLGroup to files in deploylog with ID 10
vcli vclgroups rollback 1 -l 10
# List deploylogs
vcli vclgroups deploylogs 1
# Delete deploylogs
vcli vclgroups deploylogs 1 -d 1,2
# See statistics for VCLGroups
vcli vclgroups stats -v
# Validate a routing-rule with a VCLGroup
vcli vclgroups rr-validate 1 --r 1
# Show current deploy state for a VCLGroup on all agents
vcli vclgroups state 1
# See current compile status for a deployment (or last deployment)
vcli deploy-status 1
# Create a rolling upgrade for specific agents with 30 second interval
vcli vg rolling-upgrade create 1 --vcl 1:2 --includes 3:4,5:6 --agents 10,11,12 --interval 30s
# Create a rolling upgrade for all agents with 1 minute interval (agents defaults to all)
vcli vg rolling-upgrade create 1 --vcl 1:2 --includes 3:4,5:6 --interval 1m
# Create a rolling upgrade with immediate deployment (no interval)
vcli vg rolling-upgrade create 1 --vcl 1:2 --includes 3:4,5:6 --agents 10,11,12
# Check rolling upgrade status
vcli vg rolling-upgrade status 1
# Apply rolling upgrade to all remaining agents
vcli vg rolling-upgrade apply 1
# Abort a rolling upgrade
vcli vg rolling-upgrade abort 1

Options

  -h, --help   help for vclgroup

Options inherited from parent commands

  -c, --config string   configuration file for the CLI (default ~/.vcli.yml)
                        Could also be set via VARNISH_CONTROLLER_CLI_CONFIG=/path/to/config.yml
      --csv             Output the response table as CSV format.
  -j, --json            Output the response table as JSON format.

SEE ALSO


®Varnish Software, Wallingatan 12, 111 60 Stockholm, Organization nr. 556805-6203