{"id":31934351,"url":"https://github.com/testomatio/migrate-testrail","last_synced_at":"2025-10-14T06:25:46.818Z","repository":{"id":242602138,"uuid":"801798169","full_name":"testomatio/migrate-testrail","owner":"testomatio","description":"Testrail ➡ Testomat.io migration script","archived":false,"fork":false,"pushed_at":"2025-08-07T11:59:09.000Z","size":73,"stargazers_count":0,"open_issues_count":2,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-07T13:37:40.002Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/testomatio.png","metadata":{"files":{"readme":"README-lambda.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,"zenodo":null}},"created_at":"2024-05-16T23:58:00.000Z","updated_at":"2025-08-07T11:59:12.000Z","dependencies_parsed_at":"2024-11-18T22:39:22.116Z","dependency_job_id":"038200bd-e15f-4c93-b8ab-2a3829518cdc","html_url":"https://github.com/testomatio/migrate-testrail","commit_stats":null,"previous_names":["testomatio/migrate-testrail"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/testomatio/migrate-testrail","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/testomatio%2Fmigrate-testrail","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/testomatio%2Fmigrate-testrail/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/testomatio%2Fmigrate-testrail/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/testomatio%2Fmigrate-testrail/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/testomatio","download_url":"https://codeload.github.com/testomatio/migrate-testrail/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/testomatio%2Fmigrate-testrail/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279018120,"owners_count":26086281,"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-10-14T02:00:06.444Z","response_time":60,"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":[],"created_at":"2025-10-14T06:25:44.639Z","updated_at":"2025-10-14T06:25:46.813Z","avatar_url":"https://github.com/testomatio.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Local run (via `sam` tool).\n\nevent.json file must exist contain valid values, like in .env  \n(see event.json.example)\n\n```\nsam local invoke MigrateFromTestrail -e event.json\n```\n\n---\n\n## Pre-configure before deploy to real lambda\n```\naws configure\naws iam create-role --role-name lambda-exec-role --assume-role-policy-document '{\"Version\": \"2012-10-17\",\"Statement\": [{ \"Effect\": \"Allow\", \"Principal\": {\"Service\": \"lambda.amazonaws.com\"}, \"Action\": \"sts:AssumeRole\"}]}'\naws iam attach-role-policy --role-name lambda-exec-role --policy-arn arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole\n```\n\n## First Build (very simplified)\n\n```\nnpm install\n```\n\n## Get account ID (for the next step)\n\n```\naws sts get-caller-identity\n```\n\n## First deploy\nWe need then to push an empty archive first, to not exceed the size limit.\n```\nzip -r function.zip README-lambda.md\n\naws lambda create-function --function-name migrate-testrail \\\n    --zip-file fileb://function.zip --handler lambda.handler --runtime nodejs18.x \\\n    --role arn:aws:iam::{ACCOUNT-ID}:role/lambda-exec-role\n```\n\n## Tune Lambda options for the first run\n\n```\naws lambda update-function-configuration \\\n    --function-name migrate-testrail \\\n    --handler lambda.handler\n\naws lambda update-function-configuration \\\n    --function-name migrate-testrail \\\n    --memory-size 256\n\n## 15m, maximum for AWS\naws lambda update-function-configuration \\\n    --function-name migrate-testrail \\\n    --timeout 900\n```\n\n## Add lambda event execution config (necessary for running from SDK)\n\n```\naws lambda put-function-event-invoke-config \\\n  --function-name migrate-testrail \\\n  --maximum-retry-attempts 2 \\\n  --maximum-event-age-in-seconds 3600 \\\n  --region {AWS_REGION}\n```\n\n## Further deploys\n\nHandled via Github Actions.  \nMust have these variables to configure.\n\nEnv variables (must be configured for \"production\" environment, if it's not present for your GitHub project - create it in Settions):\n- `LAMBDA_FUNCTION_NAME` (default is \"migrate-testrail\")\n\nSecrets:\n- `AWS_ACCESS_KEY_ID`\n- `AWS_SECRET_ACCESS_KEY`\n- `AWS_REGION`\n- `AWS_ACCOUNT_ID` (AWS numeric account id, like 464383111111, to mask it inside logs). Use `aws sts get-caller-identity` to get it.\n\n---\n\n## Run from CLI (event.json must exist and contain valid creds, see event.json.example)\n```\nopenssl base64 -in event.json -out event.json.base64\naws lambda invoke --function-name migrate-testrail --payload file://event.json.base64 response.json\n```\n\n## Run from Ruby SDK\n\nSee https://github.com/aws/aws-sdk-ruby\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftestomatio%2Fmigrate-testrail","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftestomatio%2Fmigrate-testrail","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftestomatio%2Fmigrate-testrail/lists"}