{"id":13498597,"url":"https://github.com/serverless-components/tencent-cos","last_synced_at":"2025-08-02T20:32:50.478Z","repository":{"id":52881119,"uuid":"215533888","full_name":"serverless-components/tencent-cos","owner":"serverless-components","description":"Instantly deploy \u0026 manage Tencent Cloud Object Storage buckets with Serverless Components.","archived":false,"fork":false,"pushed_at":"2021-10-22T11:25:48.000Z","size":997,"stargazers_count":23,"open_issues_count":0,"forks_count":3,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-04-04T15:40:03.049Z","etag":null,"topics":["serverless","serverless-component","tencent","tencent-cloud","tencent-cos"],"latest_commit_sha":null,"homepage":"https://intl.cloud.tencent.com/document/product/436","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/serverless-components.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-10-16T11:40:57.000Z","updated_at":"2024-02-21T04:03:16.000Z","dependencies_parsed_at":"2022-08-23T12:31:39.772Z","dependency_job_id":null,"html_url":"https://github.com/serverless-components/tencent-cos","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/serverless-components/tencent-cos","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/serverless-components%2Ftencent-cos","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/serverless-components%2Ftencent-cos/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/serverless-components%2Ftencent-cos/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/serverless-components%2Ftencent-cos/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/serverless-components","download_url":"https://codeload.github.com/serverless-components/tencent-cos/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/serverless-components%2Ftencent-cos/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":268448362,"owners_count":24252019,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-02T02:00:12.353Z","response_time":74,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["serverless","serverless-component","tencent","tencent-cloud","tencent-cos"],"created_at":"2024-07-31T21:00:37.629Z","updated_at":"2025-08-02T20:32:50.355Z","avatar_url":"https://github.com/serverless-components.png","language":"JavaScript","funding_links":[],"categories":["组件"],"sub_categories":[],"readme":"# 腾讯云对象存储 COS 组件\n\n## 简介\n\n通过对象存储 COS 组件，可以快速，方便的创建，配置和管理腾讯云的 COS 存储桶\n\n## 快速开始\n\n通过 COS 组件，对一个 COS 存储桶进行完整的创建，配置，部署和删除等操作。支持命令如下：\n\n1. [安装](#1-安装)\n2. [配置](#2-配置)\n3. [部署](#3-部署)\n4. [移除](#4-移除)\n\n### 1. 安装\n\n通过 npm 安装 serverless\n\n```console\n$ npm install -g serverless\n```\n\n### 2. 配置\n\n本地创建 `serverless.yml` 文件，在其中进行如下配置\n\n```console\n$ touch serverless.yml\n```\n\n```yml\n# serverless.yml\n\napp: appDemo\nstage: dev\n\ncomponent: cos\nname: cosDemo\n\ninputs:\n  bucket: bucket-demo\n  region: ap-guangzhou\n```\n\n- [点击此处查看配置文档](https://github.com/serverless-components/tencent-cos/tree/master/docs/configure.md)\n\n### 3. 部署\n\n如您的账号未[登陆](https://cloud.tencent.com/login)或[注册](https://cloud.tencent.com/register)腾讯云，您可以直接通过`微信`扫描命令行中的二维码进行授权登陆和注册。\n\n通过`sls`命令进行部署，并可以添加`--debug`参数查看部署过程中的信息\n\n```\n$ sls deploy\n```\n\n### 4. 移除\n\n**注意：**删除服务将导致用过的存储桶也被清空和删除。此操作无法撤消。\n\n通过以下命令移除部署的存储桶\n\n```\n$ sls remove\n```\n\n#### 账号配置（可选）\n\n当前默认支持 CLI 扫描二维码登录，如您希望配置持久的环境变量/秘钥信息，也可以本地创建 `.env` 文件\n\n```console\n$ touch .env # 腾讯云的配置信息\n```\n\n在 `.env` 文件中配置腾讯云的 SecretId 和 SecretKey 信息并保存。\n\n```\n# .env\nTENCENT_SECRET_ID=123\nTENCENT_SECRET_KEY=123\n```\n\n\u003e 如果没有腾讯云账号，请先 [注册新账号](https://cloud.tencent.com/register)。如果已有腾讯云账号，可以在 [API 密钥管理](https://console.cloud.tencent.com/cam/capi) 中获取 SecretId 和 SecretKey。\n\n### 使用文档\n\n[使用文档](./docs/README.md)\n\n## License\n\nMIT License\n\nCopyright (c) 2020 Tencent Cloud, Inc.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fserverless-components%2Ftencent-cos","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fserverless-components%2Ftencent-cos","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fserverless-components%2Ftencent-cos/lists"}