Skip to content

New Datasources: Pipeline/Projects #87

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
brunotorrente opened this issue Jul 21, 2022 · 3 comments
Closed

New Datasources: Pipeline/Projects #87

brunotorrente opened this issue Jul 21, 2022 · 3 comments
Labels
enhancement New feature or request

Comments

@brunotorrente
Copy link

The suggestion is to include two new datasources,

codefresh_pipeline (returns the complete data for a specific pipeline)

      data "codefresh_pipeline" "test" {
             name = "test"
       }

codefresh_pipelines (returns summaries of all pipelines)

      data "codefresh_pipelines" "list" {
             filter = { name : "^~ test" }
       }
@brunotorrente
Copy link
Author

brunotorrente commented Jul 21, 2022

codefresh_projects (returns list of all projects)

      data "codefresh_projects" "list" {
             filter = { name : "^~ test" }
       }

codefresh_project (returns the complete data for a specific project)

data "codefresh_project" "test" {
             name = "test"
       }

@brunotorrente brunotorrente changed the title New Datasources: Pipeline New Datasources: Pipeline/Projects Jul 21, 2022
@korenyoni korenyoni added the enhancement New feature or request label Sep 14, 2022
@korenyoni
Copy link
Contributor

Hi @brunotorrente,

Sorry for the delay.

I started working on this, starting with Pipelines. Pipelines are a bit challenging because it's the most complicated schema. But I think you will see this in 0.4.0.

korenyoni added a commit that referenced this issue Mar 12, 2023
## What

* Add `codefresh_pipeline` Data Source

## Why

* A way to retrieve and filter Pipelines is useful

## Notes

#87

## Checklist

* [x] _I have read
[CONTRIBUTING.md](https://github.com/codefresh-io/terraform-provider-codefresh/blob/master/README.md)._
* [x] _I have [allowed changes to my fork to be
made](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/allowing-changes-to-a-pull-request-branch-created-from-a-fork)._
* [x] _I have added tests, assuming new tests are warranted_.
* [x] _I understand that the `/test` comment will be ignored by the CI
trigger [unless it is made by a repo admin or
collaborator](https://codefresh.io/docs/docs/pipelines/triggers/git-triggers/#support-for-building-pull-requests-from-forks)._

---------

Co-authored-by: Yonatan Koren <[email protected]>
@ilia-medvedev-codefresh
Copy link
Contributor

codefresh_project was implemented in #117

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants