{"id":18724575,"url":"https://github.com/digital-blueprint/gitlab-pipeline-trigger-action","last_synced_at":"2026-02-02T13:26:46.194Z","repository":{"id":143046674,"uuid":"613856928","full_name":"digital-blueprint/gitlab-pipeline-trigger-action","owner":"digital-blueprint","description":"This GitHub action triggers and waits for a GitLab pipeline to complete.","archived":false,"fork":false,"pushed_at":"2025-04-07T07:22:32.000Z","size":492,"stargazers_count":5,"open_issues_count":1,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-04-07T08:27:14.870Z","etag":null,"topics":["digital-blueprint","github-action","gitlab","gitlab-ci"],"latest_commit_sha":null,"homepage":"","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/digital-blueprint.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-03-14T12:11:07.000Z","updated_at":"2025-04-07T07:22:12.000Z","dependencies_parsed_at":"2023-09-25T12:22:19.542Z","dependency_job_id":"1362089d-c76b-43a2-99cc-7b60fa9938c5","html_url":"https://github.com/digital-blueprint/gitlab-pipeline-trigger-action","commit_stats":{"total_commits":126,"total_committers":6,"mean_commits":21.0,"dds":0.5793650793650793,"last_synced_commit":"953ebcb116fd602a786ec7b7fb688cf4faa8ee20"},"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digital-blueprint%2Fgitlab-pipeline-trigger-action","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digital-blueprint%2Fgitlab-pipeline-trigger-action/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digital-blueprint%2Fgitlab-pipeline-trigger-action/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digital-blueprint%2Fgitlab-pipeline-trigger-action/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/digital-blueprint","download_url":"https://codeload.github.com/digital-blueprint/gitlab-pipeline-trigger-action/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248589751,"owners_count":21129679,"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":["digital-blueprint","github-action","gitlab","gitlab-ci"],"created_at":"2024-11-07T14:07:10.770Z","updated_at":"2026-02-02T13:26:46.189Z","avatar_url":"https://github.com/digital-blueprint.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GitLab Pipeline trigger action\n\n[GitHub](https://github.com/digital-blueprint/gitlab-pipeline-trigger-action) |\n[GitHub Marketplace](https://github.com/marketplace/actions/gitlab-pipeline-trigger)\n\n[![Test action](https://github.com/digital-blueprint/gitlab-pipeline-trigger-action/actions/workflows/main.yml/badge.svg)](https://github.com/digital-blueprint/gitlab-pipeline-trigger-action/actions/workflows/main.yml)\n\nThis GitHub action triggers and waits for a [GitLab pipeline](https://docs.gitlab.com/ee/ci/pipelines/) to complete.\n\nYou can for example use this action in your GitHub workflow to trigger a deployment pipeline on a private\nGitLab server after a successful build pipeline and wait for the deployment (with possible End2End tests)\nto finish, so you would get a notification if the deployment failed.\n\n```mermaid\nsequenceDiagram\n    participant GITHUB as GitHub Actions\n    participant ACTION as Action\n    participant GITLAB as GitLab CI\n\n    GITHUB-\u003e\u003eACTION: Run action\n    ACTION-\u003e\u003eGITLAB: Trigger a new pipeline\n\nloop Every 15 seconds\n    ACTION-\u003e\u003eGITLAB: Poll pipeline status\n    GITLAB--\u003e\u003eACTION: Current pipeline status\nend\n\n    opt download_artifacts is enabled\n        ACTION-\u003e\u003eGITLAB: Poll for artifacts\n        GITLAB--\u003e\u003eACTION: Download artifacts\n        ACTION-\u003e\u003eGITHUB: Save artifacts locally\n    end\n\n    ACTION--\u003e\u003eGITHUB: Final pipeline status\n```\n\n## Inputs\n\n### `host`\n\nThe GitLab host to trigger the pipeline on. Default `gitlab.com`.\n\n### `id`\n\n**Required** The ID or path of the project owned by the authenticated user.\nYou will find the _Project ID_ in the _General Settings_ of your GitLab project.\n\n### `ref`\n\n**Required** The branch or tag to run the pipeline on.\n\n### `trigger_token`\n\n**Required** The [GitLab pipeline trigger token](https://docs.gitlab.com/ee/ci/triggers/index.html#create-a-trigger-token)\nto trigger the pipeline.\n\n### `access_token`\n\nThe [GitLab pipeline access token](https://docs.gitlab.com/ee/user/project/settings/project_access_tokens.html)\nto access the pipeline via the API. You need the `read_api` and `read_repository` scopes with `Reporter` role for this token.\n\nFor public projects you don't need to provide an access token.\n\n**Note:** Required when `download_artifacts` is enabled.\n\n### `variables`\n\nA map of key-valued strings containing the pipeline variables. For example: `{ VAR1: \"value1\", VAR2: \"value2\" }`. The value has to be valid JSON. If not set the default is `{}`.\n\n### `download_artifacts`\n\nWhether to download artifacts generated by the pipeline. Default `false`.\n\n**Note:** Requires `access_token` to be set.\n\n### `download_artifacts_on_failure`\n\nWhether to download artifacts even when the pipeline fails. Default `true`.\n\n**Note:** Requires both `access_token` and `download_artifacts` to be enabled.\n\n### `fail_if_no_artifacts`\n\nWhether to fail the action if no artifacts are found. Default `false`.\n\n**Note:** Requires `download_artifacts` to be enabled. Useful for ensuring pipelines generate expected artifacts.\n\n### `download_job_logs`\n\nWhether to download job console output. Default `false`.\n\n**Note:** Requires `access_token` to be set. Downloads console output from all pipeline jobs independently of artifacts.\n\n### `download_path`\n\nPath where to save downloaded artifacts and logs. Defaults to `./downloads`.\n\n### `verbose`\n\nWhether to enable verbose logging. When disabled, only generic messages are shown without\npotentially sensitive information like URLs, IDs, or names. Default `false`.\n\n## Outputs\n\n### `status`\n\nThe last status of the pipeline. See [GitLab project pipelines](https://docs.gitlab.com/ee/api/pipelines.html#list-project-pipelines)\nfor more information about which status values there are.\n\n### `web_url`\n\nThe URL of the pipeline, for example `https://gitlab.com/foo/bar/pipelines/47`.\n\n### `artifacts_downloaded`\n\nWhether artifacts were successfully downloaded. Only set when `download_artifacts` is enabled.\n\n## Example usage\n\n### Basic usage\n\n```yaml\nuses: digital-blueprint/gitlab-pipeline-trigger-action@v1\nwith:\n    host: 'gitlab.example.com'\n    trigger_token: ${{ secrets.DEPLOY_TRIGGER_TOKEN }}\n    access_token: ${{ secrets.DEPLOY_ACCESS_TOKEN }}\n    id: '123'\n    ref: 'main'\n    variables: '{\"VAR1\":\"value1\",\"VAR2\":\"value2\"}'\n```\n\n### With artifact downloading\n\n```yaml\nuses: digital-blueprint/gitlab-pipeline-trigger-action@v1\nwith:\n    host: 'gitlab.example.com'\n    trigger_token: ${{ secrets.DEPLOY_TRIGGER_TOKEN }}\n    access_token: ${{ secrets.DEPLOY_ACCESS_TOKEN }}\n    id: '123'\n    ref: 'main'\n    variables: '{\"VAR1\":\"value1\",\"VAR2\":\"value2\"}'\n    download_artifacts: 'true'\n    download_path: './build-artifacts'\n```\n\n### With job logs\n\n```yaml\nuses: digital-blueprint/gitlab-pipeline-trigger-action@v1\nwith:\n    host: 'gitlab.example.com'\n    trigger_token: ${{ secrets.DEPLOY_TRIGGER_TOKEN }}\n    access_token: ${{ secrets.DEPLOY_ACCESS_TOKEN }}\n    id: '123'\n    ref: 'main'\n    variables: '{\"VAR1\":\"value1\",\"VAR2\":\"value2\"}'\n    download_job_logs: 'true'\n    download_path: './pipeline-logs'\n```\n\n## Downloading artifacts and job logs\n\nWhen `download_artifacts` is enabled and `access_token` is provided, the action will download artifacts based on the pipeline status:\n\n- **Pipeline succeeds**: Artifacts are downloaded automatically.\n- **Pipeline fails**: The artifacts are downloaded if `download_artifacts_on_failure` is enabled. Default `true`.\n\n**Artifact Validation:**\n\n- If `fail_if_no_artifacts` is enabled, the action will fail if no artifacts are found.\n- This helps ensure pipelines generate expected outputs and catch configuration issues early.\n\n**Job Logs:**\n\n- If `download_job_logs` is enabled, console output from all jobs will be downloaded.\n- Logs are saved as `job.log` files in each job's directory.\n- This provides complete visibility into pipeline execution for debugging.\n- Job log downloading is independent of artifact downloading.\n\nThe action will:\n\n1. Fetch all jobs from the completed pipeline;\n2. Identify jobs that have artifacts;\n3. Download artifacts from each job if `download_artifacts` is enabled;\n4. Extract the artifacts to the specified `download_path`;\n5. Organize artifacts by job (each job gets its own subdirectory);\n6. Download job console logs if `download_job_logs` is enabled;\n7. Save logs as `job.log` files in each job's directory.\n\nThe artifacts and logs are organized as follows:\n\n```\ndownload_path/\n├── job_123_job_name_1/\n│   ├── artifacts/       # Artifacts subdirectory (if download_artifacts enabled)\n│   │   ├── artifact1.txt\n│   │   └── artifact2.txt\n│   └── job.log          # Console output (if download_job_logs enabled)\n├── job_124_job_name_2/\n│   ├── artifacts/       # Artifacts subdirectory (if download_artifacts enabled)\n│   │   ├── build/\n│   │   └── dist/\n│   └── job.log          # Console output (if download_job_logs enabled)\n└── ...\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdigital-blueprint%2Fgitlab-pipeline-trigger-action","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdigital-blueprint%2Fgitlab-pipeline-trigger-action","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdigital-blueprint%2Fgitlab-pipeline-trigger-action/lists"}