Skip to content

Commit

Permalink
Merge pull request #4 from cloudboss/readmes
Browse files Browse the repository at this point in the history
Readmes
  • Loading branch information
rjosephwright authored Feb 7, 2019
2 parents b6be491 + 57c0621 commit c17faa5
Show file tree
Hide file tree
Showing 2 changed files with 95 additions and 1 deletion.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,10 @@ First read the [official documentation](https://concourse-ci.org/implementing-re

Download and unzip the latest `ofcourse` release from [GitHub](https://github.com/cloudboss/ofcourse/releases).

Example for Linux:

```
> curl -O https://github.com/cloudboss/ofcourse/releases/download/v0.1.0/ofcourse_linux_amd64.zip
> curl -L -O https://github.com/cloudboss/ofcourse/releases/download/v0.2.1/ofcourse_linux_amd64.zip
> unzip ofcourse_linux_amd64.zip
```

Expand Down
92 changes: 92 additions & 0 deletions templates/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
# {{ .Resource }}

Write a description of the resource here.

## Source Configuration

* `a`: *Required.* This is a required setting.

* `b`: *Optional.* This is an optional setting.

* `c`: *Optional. Default `true`* This is an optional setting with a default value.

### Example

```yaml
resource_types:
- name: {{ .Resource }}
type: docker-image
source:
repository: {{ .DockerRegistry }}

resources:
- name: {{ .Resource }}
type: {{ .Resource }}
check_every: 5m
source:
log_level: debug

jobs:
- name: do-it
plan:
- get: {{ .Resource }}
trigger: true
- put: {{ .Resource }}
params:
version_path: {{ .Resource }}/version
```
## Behavior
### `check`: Check for something

Write a description of what is checked here.

### `in`: Fetch something

Write a description of what is fetched here.

#### Parameters

* `a`: *Required.* This is a required parameter.

* `b`: *Optional.* This is an optional parameter.

### `out`: Put something somewhere

Write a description of what is being put somewhere.

#### Parameters

* `a`: *Required.* This is a required parameter.

* `b`: *Optional. Default `true`* This is an optional parameter with a default value.

## Development

### Prerequisites

* golang is *required* - version 1.11.x or higher is required.
* docker is *required* - version 17.05.x or higher is required.
* make is *required* - version 4.1 of GNU make is tested.

### Running the tests

The Makefile includes a `test` target, and tests are also run inside the Docker build.

Run the tests with the following command:

```sh
make test
```

### Building and publishing the image

The Makefile includes targets for building and publishing the docker image. Each of these
takes an optional `VERSION` argument, which will tag and/or push the docker image with
the given version.

```sh
make VERSION=1.2.3
make publish VERSION=1.2.3
```

0 comments on commit c17faa5

Please sign in to comment.