...

Text file src/github.com/instrumenta/kubeval/BUILDING.md

Documentation: github.com/instrumenta/kubeval

     1# Developing Kubeval
     2
     3If you are interested in contributing to Kubeval then the following instructions should
     4be useful in getting started.
     5
     6## Pre-requisites
     7
     8For building Kubeval you'll need the following:
     9
    10* Make
    11* Go 1.12
    12
    13For releasing Kubeval you'll also need:
    14
    15* [Goreleaser](https://goreleaser.com/)
    16
    17The acceptance tests use [Bats](https://github.com/sstephenson/bats) and can be run
    18directly or via Docker.
    19
    20
    21## Building
    22
    23Building a binary for your platform can be done by running:
    24
    25```
    26make build
    27```
    28
    29This should create `bin/kubeval`.
    30
    31### Release Snapshot
    32
    33To build the release snapshots run:
    34
    35```
    36make snapshot
    37```
    38
    39This creates the directory `dist` with all available release artifacts and the final configuration for `goreleaser`.
    40
    41## Testing
    42
    43The unit tests, along with some basic static analysis, can be run with:
    44
    45```
    46make test
    47```
    48
    49The [Bats](https://github.com/sstephenson/bats) based acceptance tests
    50are run using the following target. Note that this runs the tests using Docker.
    51
    52```
    53make acceptance
    54```
    55
    56If you would prefer to run them directly you need to make sure you have Kubeval
    57on your PATH and then run:
    58
    59```
    60./acceptance.bats
    61```
    62

View as plain text