Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rettetdemdativ/jenkinsrole
Go package that wraps the Jenkins Role Strategy API https://wiki.jenkins.io/display/JENKINS/Role+Strategy+Plugin
https://github.com/rettetdemdativ/jenkinsrole
go-module golang http jenkins package role-api roles
Last synced: about 1 month ago
JSON representation
Go package that wraps the Jenkins Role Strategy API https://wiki.jenkins.io/display/JENKINS/Role+Strategy+Plugin
- Host: GitHub
- URL: https://github.com/rettetdemdativ/jenkinsrole
- Owner: rettetdemdativ
- License: mit
- Created: 2019-10-15T15:52:40.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2019-11-08T18:55:28.000Z (about 5 years ago)
- Last Synced: 2023-07-13T22:37:49.386Z (over 1 year ago)
- Topics: go-module, golang, http, jenkins, package, role-api, roles
- Language: Go
- Size: 30.3 KB
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# jenkinsrole
[![Build Status](https://travis-ci.org/calmandniceperson/jenkinsrole.svg?branch=master)](https://travis-ci.org/calmandniceperson/jenkinsrole) [![Go Report Card](https://goreportcard.com/badge/github.com/calmandniceperson/jenkinsrole)](https://goreportcard.com/report/github.com/calmandniceperson/jenkinsrole) [![GoDoc](https://godoc.org/github.com/calmandniceperson/jenkinsrole?status.svg)](https://godoc.org/github.com/calmandniceperson/jenkinsrole)
jenkinsrole is a Go package that wraps the API of the Role Strategy plugin for Jenkins. For additional info regarding the plugin itself, see [the plugin page](https://wiki.jenkins.io/display/JENKINS/Role+Strategy+Plugin).
## Using the package
### Installation / import
In order to use the package, run
```go get github.com/calmandniceperson/jenkinsrole``` and import the package with ```import github.com/calmandniceperson/jenkinsrole```.### Creating a token
In order to use this package, you need to provide a user token to the Client struct. This token can be acquired by entering the respective user's settings in the top right of the Jenkins UI, selecting `Configure` in the menu on the left side and generating a token in the `API Token` section.
### Creating a client
```go
c := &Client {
HostName: "http://localhost:8080",
User: "admin",
Token: "token123",
}
```# License
This package is shared under the [MIT License](https://choosealicense.com/licenses/mit/).