- NAME
-
- gcloud beta compute network-firewall-policies associations create - create a new association between a firewall policy and a network
- SYNOPSIS
-
-
gcloud beta compute network-firewall-policies associations create
--firewall-policy
=FIREWALL_POLICY
--network
=NETWORK
[--name
=NAME
] [--replace-association-on-target
] [--firewall-policy-region
=FIREWALL_POLICY_REGION
|--global-firewall-policy
] [GCLOUD_WIDE_FLAG …
]
-
- DESCRIPTION
-
(BETA)
gcloud beta compute network-firewall-policies associations create
is used to create network firewall policy associations. A network firewall policy is a set of rules that controls access to various resources. - EXAMPLES
-
To associate a global network firewall policy with name
to networkmy-policy
with an association namedmy-network
, run:my-association
gcloud beta compute network-firewall-policies associations create --firewall-policy=my-policy --network=my-network --name=my-association --global-firewall-policy
To associate a network firewall policy with name
in regionmy-region-policy
to networkregion-a
with an association namedmy-network
, run:my-association
gcloud beta compute network-firewall-policies associations create --firewall-policy=my-policy --network=my-network --name=my-association --firewall-policy-region=region-a
- REQUIRED FLAGS
-
--firewall-policy
=FIREWALL_POLICY
- Firewall policy ID with which to create association.
--network
=NETWORK
- Name of the network with which the association is created.
- OPTIONAL FLAGS
-
--name
=NAME
- Name of the association.
--replace-association-on-target
- By default, if you attempt to insert an association to a network that is already associated with a firewall policy the method will fail. If this is set, the existing association will be deleted at the same time that the new association is created.
-
At most one of these can be specified:
--firewall-policy-region
=FIREWALL_POLICY_REGION
-
Region of the firewall policy to create. Overrides the default
compute/region
property value for this command invocation. --global-firewall-policy
- If set, the firewall policy is global.
- GCLOUD WIDE FLAGS
-
These flags are available to all commands:
--access-token-file
,--account
,--billing-project
,--configuration
,--flags-file
,--flatten
,--format
,--help
,--impersonate-service-account
,--log-http
,--project
,--quiet
,--trace-token
,--user-output-enabled
,--verbosity
.Run
$ gcloud help
for details. - NOTES
-
This command is currently in beta and might change without notice. These
variants are also available:
gcloud compute network-firewall-policies associations create
gcloud alpha compute network-firewall-policies associations create
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-04-23 UTC.