Get branch details for concourse
10K+
Tracks the set of branches that exist in a git repository.
Add the following resource_types entry to your pipeline:
---
resource_types:
- name: git-branches
type: docker-image
source: {repository: vito/git-branches-resource}
uri: Required. The location of the repository.
private_key: Optional. Private key to use when pulling/pushing.
Example:
private_key: |
-----BEGIN RSA PRIVATE KEY-----
MIIEowIBAAKCAQEAtCS10/f7W7lkQaSgD/mVeaSOvSF9ql4hf/zfMwfVGgHWjj+W
<Lots more text>
DWiJL+OFeg9kawcUL6hQ8JeXPhlImG6RTUffma9+iGQyyBMCGd1l
-----END RSA PRIVATE KEY-----
username: Optional. Username for HTTP(S) auth when pulling/pushing.
This is needed when only HTTP/HTTPS protocol for git is available (which does not support private key auth)
and auth is required.
password: Optional. Password for HTTP(S) auth when pulling/pushing.
skip_ssl_verification: Optional. Skips git ssl verification by exporting
GIT_SSL_NO_VERIFY=true.
git_config: Optional. If specified as (list of pairs name and value)
it will configure git global options, setting each name with each value.
This can be useful to set options like credential.helper or similar.
See the git-config(1) manual page
for more information and documentation of existing git options.
Resource configuration for a private repo:
resources:
- name: source-code
type: git-branches
source:
uri: [email protected]:concourse/git-resource.git
private_key: |
-----BEGIN RSA PRIVATE KEY-----
MIIEowIBAAKCAQEAtCS10/f7W7lkQaSgD/mVeaSOvSF9ql4hf/zfMwfVGgHWjj+W
<Lots more text>
DWiJL+OFeg9kawcUL6hQ8JeXPhlImG6RTUffma9+iGQyyBMCGd1l
-----END RSA PRIVATE KEY-----
check: Check for changes to the branch set.The repository is cloned (or pulled if already present), all remote branches are enumerated, and compared to the existing set of branches.
If any branches are new or removed, a new version is emitted including the delta.
in: Produce the version's info as files.Produces the following files based on the version being fetched:
branches: A file containing the list of current branches, one per line.added: A file containing the newly cretated branches, one per line.removed: A file containing the branches that have been removed, one per
line.out: No-op.Not implemented.
Content type
Image
Digest
Size
13 MB
Last updated
about 8 years ago
docker pull flexys/git-branches-resource