docker - 无法初始化日志记录驱动程序:无法连接或使用 Google Cloud Logging 进行身份验证
问题描述
要做的事: 从 docker 容器将日志发送到 Google Logs Viewer。
面对错误
我关注了这篇文章:https ://docs.docker.com/config/containers/logging/gcplogs/
并执行docker run --log-driver=gcplogs nginx
docker: Error response from daemon: failed to initialize logging driver: unable to connect or authenticate with Google Cloud Logging: rpc error: code = PermissionDenied desc = The caller does not have permission.
操作系统:容器优化操作系统 cos-81-12871-1196-0
我也试过这个The Google Cloud Logging driver for Docker with service account with log.admin
and log.writer
role
如何将日志发送到 Stackdriver/Google Cloud Logging
解决方案
推荐阅读
- python - 在 2 个数据帧 python pandas 中查找并匹配一个字符串
- quickfixj - 使用 SSL 和代理时 QuickFIX/J 会话挂起
- javascript - 在 map() 函数中标记不会加载
- apache-spark - 使用 Kafka 使用 Synapse Spark 将数据帧写入 Azure EventHub
- docker - 使用卷副本将映像推送到另一个注册表
- python - ProgrammingError: (pyodbc.ProgrammingError) ('42000', '[42000] 使用 sqlalchemy 将 Dataframe/csv 文件导出到 sql server table 2018 的 Python 代码
- javascript - 如果函数通过属性添加到对象,则 function.name 返回空字符串
- python - 如何在 Django 请求处理程序线程中的 SIGTERM 上执行代码
- multiprocessing - 用于管理分布式 SpGEMM 的 Julia 包
- javascript - 我想制作一个范围滑块程序来获取用户的详细信息,然后向用户提供估计值,但我无法将值存储在变量中以供使用