Using Console
Using CLI
<resource-type>
with the type of resource (e.g. gce_instance
, cloud_function
) and <resource-name>
with the name of the resource.
Using Python
google-cloud-logging
library to enable logging using the following Python code:project_id
with the ID of the GCP project for which you want to enable logging.