{"id":13756262,"url":"https://github.com/Goodsmileduck/yandex-serverless-action","last_synced_at":"2025-05-10T03:31:29.104Z","repository":{"id":36366234,"uuid":"212220481","full_name":"Goodsmileduck/yandex-serverless-action","owner":"Goodsmileduck","description":"Github Action for deploying code to existed Serverless function in Yandex cloud","archived":false,"fork":false,"pushed_at":"2023-10-04T07:44:19.000Z","size":25987,"stargazers_count":45,"open_issues_count":6,"forks_count":6,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-28T19:41:07.233Z","etag":null,"topics":["github","github-action","serverless","yandex-function"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Goodsmileduck.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-10-01T23:47:27.000Z","updated_at":"2025-01-22T10:16:35.000Z","dependencies_parsed_at":"2024-08-03T11:02:03.706Z","dependency_job_id":"085ee44a-6f6f-4632-bf64-98e572693b83","html_url":"https://github.com/Goodsmileduck/yandex-serverless-action","commit_stats":{"total_commits":173,"total_committers":6,"mean_commits":"28.833333333333332","dds":"0.35260115606936415","last_synced_commit":"c2e212231955b2becf154255a73f573e6c63d6f7"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Goodsmileduck%2Fyandex-serverless-action","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Goodsmileduck%2Fyandex-serverless-action/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Goodsmileduck%2Fyandex-serverless-action/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Goodsmileduck%2Fyandex-serverless-action/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Goodsmileduck","download_url":"https://codeload.github.com/Goodsmileduck/yandex-serverless-action/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253358069,"owners_count":21895967,"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","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":["github","github-action","serverless","yandex-function"],"created_at":"2024-08-03T11:00:40.189Z","updated_at":"2025-05-10T03:31:24.624Z","avatar_url":"https://github.com/Goodsmileduck.png","language":"TypeScript","funding_links":[],"categories":["GitHub Actions"],"sub_categories":[],"readme":"# Yandex serverless action\n\n\u003cp align=\"left\"\u003e\n  \u003ca href=\"https://github.com/Goodsmileduck/yandex-serverless-action/actions?query=workflow%3Ayandex-serverless-action\"\u003e\u003cimg alt=\"yandex-serverless-action\" src=\"https://github.com/Goodsmileduck/yandex-serverless-action/workflows/yandex-serverless-action/badge.svg\"\u003e\u003c/a\u003e \n\u003c/p\u003e\n\nThis action uploads code to object storage and update Serverless function in Yandex cloud.\n\n\n\n## Usage\n\n1. Create serverless function in Yandex Cloud and copy function id\n2. Create s3 bucket (optional, if you want to upload code to bucket or if it's bigger than 5Mb)\n3. Add workflow to your repo\n\n## `workflow.yml` Example\n\nPlace in a `.yml|.yaml`  file such as this one in your `.github/workflows` folder. [Refer to the documentation on workflow YAML syntax here.](https://help.github.com/en/articles/workflow-syntax-for-github-actions)\n\n```yaml\nname: Push and Deploy Serverless function\non: push\n\njobs:\n  deploy:\n    runs-on: ubuntu-latest\n    steps:\n    - uses: actions/checkout@master\n    - uses: goodsmileduck/yandex-serverless-action@v2\n      with:\n        token: ${{ secrets.TOKEN }}\n        bucket: ${{ secrets.BUCKET }}\n        accessKeyId: ${{ secrets.ACCESS_KEY_ID }}\n        secretAccessKey: ${{ secrets.SECRET_ACCESS_KEY }}\n        function_id: '234awefq12345g24f'\n        runtime: 'python37'\n        memory: '256'\n        entrypoint: 'main.handler'\n        environment: DEBUG=True,COUNT=1\n        source: '.'\n        exclude: 'src/'\n```\n\n## Configuration\n\nThe following settings must be passed as variables as shown in the example. Sensitive information, especially `token`  should be [set as encrypted secrets](https://help.github.com/en/articles/virtual-environments-for-github-actions#creating-and-using-secrets-encrypted-variables) — otherwise, they'll be public to anyone browsing your repository.\n\n| Key | Value | Suggested Type | Required |\n| ------------- | ------------- | ------------- | ------------- |\n| `token` | Token for access to yc cli. To get token visit [link](https://oauth.yandex.ru/authorize?response_type=token\u0026client_id=1a6990aa636648e9b2ef855fa7bec2fb) | `secret` | **Yes** |\n| `function_id` | The ID of function in Yandex Cloud | `env` | **Yes** |\n| `runtime` | Runtime for function in Yandex Cloud. To get the list of allowed args visit [link](https://cloud.yandex.com/en-ru/docs/functions/concepts/runtime/#runtimes) | `env` | **Yes** |\n| `entrypoint` | Entry point of function | `env` | **Yes** |\n| `description` | Description for version of function | `env` | No |\n| `environment` | Comma-separated list with env variables | `env` | No |\n| `memory` | Memory limit in `megabytes` for function in Yandex Cloud Default value is `128`| `env` | No |\n| `execution_timeout` | Execution timeout in seconds for function in Yandex Cloud. Default value is `5` | `env` | No |\n| `service_account` | Service account id. | `secret` | No |\n| `bucket` | The name of the bucket you're syncing to. For example, `bucket`. If wasn't set action will try to upload code directly. Required if code bigger than 5Mb| `secret` | No |\n| `accessKeyId` | Yandex AWS Access Key Id when s3 bucket used. Required if code bigger than 5Mb| `secret` | No |\n| `secretAccessKey` | Yandex AWS Access Key Id when s3 bucket used. Required if code bigger than 5Mb| `secret` | No |\n| `source` | The local directory you wish to upload. For example, `./public`. Defaults to the root of your repository (`.`) if not provided. | `env` | No |\n| `exclude` | Explicitly exclude the specified files. Defaults empty if not provided. | `env` | No |\n\n# Scenarios\n\n  - [Zip and and deploy folder](#zip-and-and-deploy-folder)\n  - [Zip and upload to bucket and deploy](#zip-and-upload-to-bucket-and-deploy)\n  - [Exclude pattern from archive](#Exclude-pattern-from-archive)\n  - [Set service account id](#Set-service-account-id)\n\n## Zip and and deploy folder\n\n```yaml\n- uses: goodsmileduck/yandex-serverless-action@v1\n  with:\n    token: ${{ secrets.TOKEN }}\n    function_id: 'my_function_id'\n    runtime: 'python37'\n    memory: '256'\n    entrypoint: 'main.handler'\n    environment: DEBUG=True,COUNT=1\n    source: '.'\n```\n\n## Zip and upload to bucket and deploy\n\n```yaml\n- uses: goodsmileduck/yandex-serverless-action@v1\n  with:\n    description: \"Function without bucket\"\n    token: ${{ secrets.TOKEN }}\n    bucket: ${{ secrets.BUCKET }}\n    accessKeyId: ${{ secrets.ACCESS_KEY_ID }}\n    secretAccessKey: ${{ secrets.SECRET_ACCESS_KEY }}\n    function_id: 'my_function_id'\n    runtime: 'python37'\n    memory: '256'\n    entrypoint: 'main.handler'\n    environment: DEBUG=True,COUNT=1\n    source: './src'\n    description: \"Version: v0.1.1\"\n```\n\n## Exclude pattern from archive\n\n```yaml\n- uses: goodsmileduck/yandex-serverless-action@v1\n  with:\n    token: ${{ secrets.TOKEN }}\n    function_id: 'my_function_id'\n    runtime: 'python37'\n    memory: '256'\n    entrypoint: 'main.handler'\n    environment: DEBUG=True,COUNT=2\n    source: './public'\n    exclude: '*.txt'\n```\n\n## Set service account id\n\n```yaml\n- uses: goodsmileduck/yandex-serverless-action@v1\n  with:\n    token: ${{ secrets.TOKEN }}\n    function_id: 'my_function_id'\n    runtime: 'python37'\n    memory: '256'\n    entrypoint: 'main.handler'\n    environment: DEBUG=True,COUNT=2\n    source: './public'\n    service_account: ${{ secrets.SERVICE_ACCOUNT }}\n```\n## License\n\nThis project is distributed under the [MIT license](LICENSE.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FGoodsmileduck%2Fyandex-serverless-action","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FGoodsmileduck%2Fyandex-serverless-action","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FGoodsmileduck%2Fyandex-serverless-action/lists"}