google-cloud-logging

Using YAML file to setup GCP Cloud Logging

元气小坏坏 提交于 2021-02-09 18:55:33
问题 I have the following YAML file setup for my logger in my project: --- version: 1 disable_existing_loggers: False formatters: simple: format: "%(asctime)s - %(name)s - %(levelname)s - %(message)s" colored: (): "colorlog.ColoredFormatter" datefmt: "%Y-%m-%d %H:%M:%S" format: "%(white)s%(asctime)s.%(msecs)03d%(reset)s - %(cyan)s[%(module)s.%(funcName)s]%(reset)s - %(log_color)s[%(levelname)s] :=>%(reset)s %(message)s" log_colors: DEBUG: purple INFO: blue WARNING: yellow ERROR: red CRITICAL: red

Using YAML file to setup GCP Cloud Logging

泪湿孤枕 提交于 2021-02-09 18:50:57
问题 I have the following YAML file setup for my logger in my project: --- version: 1 disable_existing_loggers: False formatters: simple: format: "%(asctime)s - %(name)s - %(levelname)s - %(message)s" colored: (): "colorlog.ColoredFormatter" datefmt: "%Y-%m-%d %H:%M:%S" format: "%(white)s%(asctime)s.%(msecs)03d%(reset)s - %(cyan)s[%(module)s.%(funcName)s]%(reset)s - %(log_color)s[%(levelname)s] :=>%(reset)s %(message)s" log_colors: DEBUG: purple INFO: blue WARNING: yellow ERROR: red CRITICAL: red

Using YAML file to setup GCP Cloud Logging

℡╲_俬逩灬. 提交于 2021-02-09 18:50:47
问题 I have the following YAML file setup for my logger in my project: --- version: 1 disable_existing_loggers: False formatters: simple: format: "%(asctime)s - %(name)s - %(levelname)s - %(message)s" colored: (): "colorlog.ColoredFormatter" datefmt: "%Y-%m-%d %H:%M:%S" format: "%(white)s%(asctime)s.%(msecs)03d%(reset)s - %(cyan)s[%(module)s.%(funcName)s]%(reset)s - %(log_color)s[%(levelname)s] :=>%(reset)s %(message)s" log_colors: DEBUG: purple INFO: blue WARNING: yellow ERROR: red CRITICAL: red

Using YAML file to setup GCP Cloud Logging

大兔子大兔子 提交于 2021-02-09 18:43:28
问题 I have the following YAML file setup for my logger in my project: --- version: 1 disable_existing_loggers: False formatters: simple: format: "%(asctime)s - %(name)s - %(levelname)s - %(message)s" colored: (): "colorlog.ColoredFormatter" datefmt: "%Y-%m-%d %H:%M:%S" format: "%(white)s%(asctime)s.%(msecs)03d%(reset)s - %(cyan)s[%(module)s.%(funcName)s]%(reset)s - %(log_color)s[%(levelname)s] :=>%(reset)s %(message)s" log_colors: DEBUG: purple INFO: blue WARNING: yellow ERROR: red CRITICAL: red

Using YAML file to setup GCP Cloud Logging

允我心安 提交于 2021-02-09 18:41:13
问题 I have the following YAML file setup for my logger in my project: --- version: 1 disable_existing_loggers: False formatters: simple: format: "%(asctime)s - %(name)s - %(levelname)s - %(message)s" colored: (): "colorlog.ColoredFormatter" datefmt: "%Y-%m-%d %H:%M:%S" format: "%(white)s%(asctime)s.%(msecs)03d%(reset)s - %(cyan)s[%(module)s.%(funcName)s]%(reset)s - %(log_color)s[%(levelname)s] :=>%(reset)s %(message)s" log_colors: DEBUG: purple INFO: blue WARNING: yellow ERROR: red CRITICAL: red

The Google Cloud Logging driver for Docker

蹲街弑〆低调 提交于 2021-02-07 07:17:07
问题 I'm not able to authenticate the google cloud driver gcplogs for Docker despite the fact that I've set the env var GOOGLE_APPLICATION_CREDENTIALS to the path/file where the JSON credentials of my service account is. The error message is the following: ERROR: for oncrm_oncrm_1 Cannot start service oncrm: failed to initialize logging driver: google.DefaultTokenSource: google: could not find default credentials. See https://developers.google.com/accounts/docs/application-default-credentials for

The Google Cloud Logging driver for Docker

痞子三分冷 提交于 2021-02-07 07:16:00
问题 I'm not able to authenticate the google cloud driver gcplogs for Docker despite the fact that I've set the env var GOOGLE_APPLICATION_CREDENTIALS to the path/file where the JSON credentials of my service account is. The error message is the following: ERROR: for oncrm_oncrm_1 Cannot start service oncrm: failed to initialize logging driver: google.DefaultTokenSource: google: could not find default credentials. See https://developers.google.com/accounts/docs/application-default-credentials for

No logs are created in Stackdriver logging

最后都变了- 提交于 2021-02-05 07:17:06
问题 In my google app script, I have: Logger.log("test"); and I even tried console.log("test"); But neither is printed to the stackdriver log, even after I've set the project id to a Google Cloud Project id. The screen shows: 回答1: To being able to see the logs on Stackdriver your project should have linked to a Google Cloud Standard project instad of the default project otherwise you only could see the "Stackdriver logs" on the executions pages in https://script.google.com From https://developers

Google Cloud Stackdriver and monolog Symfony

半城伤御伤魂 提交于 2021-01-28 09:16:43
问题 I'm working with Google Cloud (GKE) and I want to use their system for log and monitor (Stackdriver). My projet is under php Symfony3. I'm searching how to log to stackdriver some logs of my symfony project. I saw that there is an offical lib : https://github.com/GoogleCloudPlatform/google-cloud-php And a PSR-3 class : http://googlecloudplatform.github.io/google-cloud-php/#/docs/v0.20.1/logging/psrlogger My question is, how to integrate that in my config.yml with monolog ? 回答1: I did this by

GCP stackdriver logging logs format changed in bucket from folder per container to stdout\stderr

こ雲淡風輕ζ 提交于 2021-01-28 09:16:13
问题 i have a question, similar as describe here: GKE kubernetes container stdout logs format changed in old version of stackdriver i had 1 sink with filter like this: resource.type=container, resource.namespace_id=[NAMESPACE_NAME] resource.pod_id=[POD_NAME] and logs was stored in bucket pretty well, like this: logName=projects/[PROJECT-NAME]/logs/[CONTAINER-NAME] ...so i had folders whith logs for each container. But now i updated my stackdriver logging+monitoring to last version and now i have 2