Skip to content

Commit 0911c8a

Browse files
committed
Initial commit
0 parents  commit 0911c8a

File tree

1,314 files changed

+397023
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,314 files changed

+397023
-0
lines changed

.github/workflows/release.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: goreleaser
2+
3+
on:
4+
push:
5+
tags:
6+
- '*'
7+
8+
jobs:
9+
goreleaser:
10+
runs-on: ubuntu-latest
11+
steps:
12+
-
13+
name: Checkout
14+
uses: actions/checkout@v2
15+
with:
16+
fetch-depth: 0
17+
-
18+
name: Set up Go
19+
uses: actions/setup-go@v2
20+
with:
21+
go-version: 1.15
22+
-
23+
name: Run GoReleaser
24+
uses: goreleaser/goreleaser-action@v2
25+
with:
26+
version: latest
27+
args: release --rm-dist
28+
env:
29+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.gitignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
/vault
2+
3+
.DS_store
4+
5+
op-connect
6+
7+
.idea/

.goreleaser.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
# TODO Enable go mod tidy once the Go Connect SDK is public
2+
# before:
3+
# hooks:
4+
# # this is just an example and not a requirement for provider building/publishing
5+
# - go mod tidy
6+
builds:
7+
- env:
8+
# goreleaser does not work with CGO, it could also complicate
9+
# usage by users in CI/CD systems like Terraform Cloud where
10+
# they are unable to install libraries.
11+
- CGO_ENABLED=0
12+
- GOPRIVATE="github.com/1Password"
13+
mod_timestamp: '{{ .CommitTimestamp }}'
14+
flags:
15+
- -trimpath
16+
ldflags:
17+
- '-s -w -X main.version={{.Version}} -X main.commit={{.Commit}}'
18+
goos:
19+
- freebsd
20+
- windows
21+
- linux
22+
- darwin
23+
goarch:
24+
- amd64
25+
- '386'
26+
- arm
27+
- arm64
28+
ignore:
29+
- goos: darwin
30+
goarch: '386'
31+
binary: '{{ .ProjectName }}_v{{ .Version }}'
32+
archives:
33+
- format: zip
34+
name_template: '{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}'
35+
checksum:
36+
name_template: '{{ .ProjectName }}_{{ .Version }}_SHA256SUMS'
37+
algorithm: sha256
38+
# TODO Enable checksum signing once a key is available
39+
# signs:
40+
# - artifacts: checksum
41+
# args:
42+
# # if you are using this is a GitHub action or some other automated pipeline, you
43+
# # need to pass the batch flag to indicate its not interactive.
44+
# - "--batch"
45+
# - "--local-user"
46+
# - "{{ .Env.GPG_FINGERPRINT }}" # set this environment variable for your signing key
47+
# - "--output"
48+
# - "${signature}"
49+
# - "--detach-sign"
50+
# - "${artifact}"
51+
release:
52+
# If you want to manually examine the release before its live, uncomment this line:
53+
draft: true
54+
changelog:
55+
skip: true

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2020 1Password
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

Makefile

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
GOARCH = amd64
2+
3+
UNAME = $(shell uname -s)
4+
5+
ifndef OS
6+
ifeq ($(UNAME), Linux)
7+
OS = linux
8+
else ifeq ($(UNAME), Darwin)
9+
OS = darwin
10+
endif
11+
endif
12+
13+
.DEFAULT_GOAL := all
14+
15+
all: fmt build start
16+
17+
build:
18+
GOOS=$(OS) GOARCH="$(GOARCH)" go build -o vault/plugins/op-connect .
19+
20+
start:
21+
vault server -dev -dev-root-token-id=root -dev-plugin-dir=./vault/plugins
22+
23+
enable:
24+
vault secrets enable op-connect
25+
26+
clean:
27+
rm -f ./vault/plugins/op-connect
28+
29+
fmt:
30+
go fmt $$(go list ./...)
31+
32+
.PHONY: build clean fmt start enable

0 commit comments

Comments
 (0)