This repository has been archived by the owner on Mar 12, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from adfinis-sygroup/feature/travisci
Added Travis CI integration
- Loading branch information
Showing
3 changed files
with
49 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
language: go | ||
|
||
go: 1.7.4 | ||
|
||
sudo: required | ||
|
||
before_install: | ||
- export VAULT_VERSION=0.6.2 | ||
- cp sample/vaultrc ~/.vaultrc | ||
- sudo apt-get update -qqy && sudo apt-get install -qqy unzip | ||
- wget -O - https://keybase.io/hashicorp/pgp_keys.asc | gpg --import | ||
- wget https://releases.hashicorp.com/vault/${VAULT_VERSION}/vault_${VAULT_VERSION}_SHA256SUMS.sig | ||
- wget https://releases.hashicorp.com/vault/${VAULT_VERSION}/vault_${VAULT_VERSION}_linux_amd64.zip | ||
- wget https://releases.hashicorp.com/vault/${VAULT_VERSION}/vault_${VAULT_VERSION}_SHA256SUMS | ||
- gpg --verify vault_${VAULT_VERSION}_SHA256SUMS.sig vault_${VAULT_VERSION}_SHA256SUMS | ||
- bash -c "[[ \"$(sha256sum vault_${VAULT_VERSION}_linux_amd64.zip)\" == \"$(grep | ||
vault_${VAULT_VERSION}_linux_amd64 vault_${VAULT_VERSION}_SHA256SUMS)\" ]] || exit | ||
1" | ||
- sudo unzip vault_${VAULT_VERSION}_linux_amd64.zip -d /usr/local/bin | ||
|
||
install: | ||
- make install | ||
|
||
before_script: | ||
- vault server -dev -dev-root-token-id="password" & | ||
|
||
script: | ||
- make test | ||
- make build | ||
|
||
deploy: | ||
provider: releases | ||
api_key: | ||
secure: H514x+zUvUtT2xeJmqIanrMXtsvGroA/Bk5eAwNkVbz+2bL9Aj9tUSSpTvMka34lo+IdBDK0lpITDNooEmdlyCPRtJx/wAavSjKTquq+K0isXXCv4m/w7L3Gxhd5Xwq1ZEg4gB3cyQOoRTSLeopWqtx1EJ0gnF7MZL4IQ93zJL44YYBDVCp0mPoBOKmk6k6+vWhvmkHyepIGNriXM4kwm69mByrRdUb+YTyYl0wBKV7jW6zuoiWX2srFkArP1tyB4kc0Gc8+SIzoB1DykFw99cmN2H3DS5acG6omindaWE1izFodsv/Ar5B66mKCxd8AVPNGNe548PJl9FEW2pMF2P++4oQthu5vBDFx85h7ecvj/xBpObnPldxty4gn371ee0BwCDwTMoXKBupwJmbOwD5UE5ibxGNVj3n0YnrwCJ+56eUzibuCsLTI2/TvfJLp/nKKZtFFS5xmhvIGJR5+xT6+th8dG5DgpGGYJ36sTEwBcGBplSvqsF3iSb1dE8hpNN8/rTi43z5kPm4B90+17nS7LzvfLQozMChLru5xRD2WocwzkNUa9qST2qaJbkSvq9UMZepkKsuvC7qtoQhMesbwzFgTNEBsqHp61q6RIJYOh9enHjf6ejyE2YAksQLTOBK/hOp/RL1vk6f7lhpL/UX5lHVnE+qUZrQ8e+KQcfM= | ||
file: vc | ||
on: | ||
tags: true | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
.PHONY: help test-all dependencies | ||
.PHONY: help test-all dependencies build install | ||
|
||
help: | ||
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' | ||
|
||
test-all: ## Runs all tests | ||
test: ## Runs all tests | ||
go test src/*.go | ||
|
||
build: ## Compiles the program | ||
go build -o vc src/*.go | ||
|
||
dependencies: ## install go dependencies | ||
install: ## Installs go dependencies | ||
for dep in gopkg.in/yaml.v2 github.com/hashicorp/vault/api github.com/mitchellh/cli; do \ | ||
go get $$dep; \ | ||
done | ||
|
||
build: ## Compiles the program | ||
go build -o vc src/*.go |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
host: 127.0.0.1 | ||
port: 8200 | ||
token: password | ||
tls: false | ||
verify_tls: false |