The following plugin provides functionality available through
Pipeline-compatible steps. Read more about how to integrate steps into your
Pipeline in the
Steps
section of the
Pipeline Syntax
page.
For a list of other such plugins, see the
Pipeline Steps Reference
page.
Pipeline: GCP Steps
computeFirewallRulesCreate
: Create a firewall rule
Step to create a firewall rule
name : String
Name of the firewall rule to create.
action : String
(optional)
The action for the firewall rule: whether to allow or deny matching traffic.
If specified, the flag --rules must also be specified. Must be one of: ALLOW, DENY
allow : String
(optional)
A list of protocols and ports whose traffic will be allowed.
For example tcp:80,icmp will allow TCP traffic on port 80 and ICMP traffic.
description : String
(optional)
A textual description for the firewall rule.
destinationRanges : String
(optional)
The firewall rule will apply to traffic that has destination IP address in these IP address block list.
direction : String
(optional)
If direction is NOT specified, then default is to apply on incoming traffic. For outbound traffic, it is NOT supported to specify source-tags.
Must be one of: INGRESS, EGRESS, IN, OUT.
disabled : boolean
(optional)
Disable a firewall rule and stop it from being enforced in the network.
enableLogging : boolean
(optional)
Enable logging for the firewall rule. Logs will be exported to StackDriver. Firewall logging is disabled by default.
loggingMetadata : String
(optional)
Adds or removes metadata fields to or from the reported firewall logs.
Must be one of: exclude-all, include-all
network : String
(optional)
The network to which this rule is attached. If omitted, the rule is attached to the default network.
priority : int
(optional)
This is an integer between 0 and 65535, both inclusive. When NOT specified, the value assumed is 1000.
rules : String
(optional)
A list of protocols and ports to which the firewall rule will apply.
If specified, the flag --action must also be specified.
For example tcp:80,icmp will allow TCP traffic on port 80 and ICMP traffic.
sourceRanges : String
(optional)
A list of IP address blocks that are allowed to make inbound connections that match the firewall rule to the instances on the network.
The IP address blocks must be specified in CIDR format, e.g. 0.0.0.0/0
sourceServiceAccounts : String
(optional)
The email of a service account indicating the set of instances on the network which match a traffic source in the firewall rule.
sourceTags : String
(optional)
A list of instance tags indicating the set of instances on the network to which the rule applies if all other fields match.
targetServiceAccounts : String
(optional)
The email of a service account indicating the set of instances to which firewall rules apply.
targetTags : String
(optional)
List of instance tags indicating the set of instances on the network which may accept connections that match the firewall rule.
computeFirewallRulesDelete
: Delete a firewall rule
Step to delete a firewall rule
name : String
Names of the firewall rules to delete, separated by whitespace
withGCP
: Set GCP credentials for nested block
The id of credentials, presumably stored as Secret file
Was this page helpful?
Please submit your feedback about this page through this
quick form.
Alternatively, if you don't wish to complete the quick form, you can simply
indicate if you found this page helpful?
See existing feedback here.