Skip to content

Commit

Permalink
CONTAINER_TAG={build version} (#340)
Browse files Browse the repository at this point in the history
* CONTAINER_TAG={build version}
* add makefile
* upd goreleaser.yaml
* CI run tests per package
  • Loading branch information
gertd committed Mar 22, 2024
1 parent 22728e0 commit ca47d1f
Show file tree
Hide file tree
Showing 12 changed files with 382 additions and 126 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,11 @@ jobs:
-
name: Test
run: |
gotestsum --format short-verbose -- -count=1 -parallel=1 -v -timeout=240s -coverprofile=cover.out -coverpkg=./... ./...
gotestsum --format short-verbose -- -count=1 -parallel=1 -v -timeout=120s -coverprofile=cover.out -coverpkg=./... github.com/aserto-dev/topaz/pkg/app/tests/authz/...
gotestsum --format short-verbose -- -count=1 -parallel=1 -v -timeout=120s -coverprofile=cover.out -coverpkg=./... github.com/aserto-dev/topaz/pkg/app/tests/builtin/...
gotestsum --format short-verbose -- -count=1 -parallel=1 -v -timeout=120s -coverprofile=cover.out -coverpkg=./... github.com/aserto-dev/topaz/pkg/app/tests/manifest/...
gotestsum --format short-verbose -- -count=1 -parallel=1 -v -timeout=120s -coverprofile=cover.out -coverpkg=./... github.com/aserto-dev/topaz/pkg/app/tests/policy/...
gotestsum --format short-verbose -- -count=1 -parallel=1 -v -timeout=120s -coverprofile=cover.out -coverpkg=./... github.com/aserto-dev/topaz/pkg/app/tests/query/...
-
name: Upload code coverage
uses: shogo82148/actions-goveralls@v1
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pr_checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ jobs:
check-commits:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: gitleaks-check
Expand Down
6 changes: 3 additions & 3 deletions Depfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ go:
version: "v1.3.13"
wire:
importPath: "github.com/google/wire/cmd/wire"
version: "v0.5.0"
version: "v0.6.0"
goreleaser:
importPath: github.com/goreleaser/goreleaser
version: "v1.24.0"
Expand All @@ -20,7 +20,7 @@ go:
version: "latest"
grpcui:
importPath: "github.com/fullstorydev/grpcui/cmd/grpcui"
version: "v1.3.1"
version: "v1.3.3"
grpcurl:
importPath: "github.com/fullstorydev/grpcurl/cmd/grpcurl"
version: "v1.8.8"
version: "v1.8.9"
51 changes: 24 additions & 27 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ Join the community [Slack channel](https://www.aserto.com/slack) for questions a

### Building from source

`topaz` is currently using go v1.17 or above. In order to build `topaz` from source you must:
`topaz` is currently using golang v1.22.* to compile, `go.mod` files are pinned to 1.21 or lower. In order to build `topaz` from source you must:

1. Install [mage](https://magefile.org/)
2. Clone the repo
Expand Down Expand Up @@ -208,39 +208,36 @@ To start an interactive session with the Topaz endpoints over gRPC, see the [gRP
## Command line options

```shell
$ topaz --help
Usage: topaz <command>
topaz --help
Usage: topaz <command> [flags]
Topaz CLI
Commands:
start start topaz in daemon mode
stop stop topaz instance
status status of topaz daemon process
run run topaz in console mode
manifest get get manifest
manifest set set manifest
manifest delete delete manifest
load load manifest from file
save save manifest to file
import import directory objects
export export directory objects
backup backup directory data
restore restore directory data
test exec execute assertions
test template output assertions template
templates list list template
templates install install template
install install topaz container
configure configure topaz service
update update topaz container version
uninstall uninstall topaz container
version version information
console opens the console in the browser
start start topaz in daemon mode
stop stop topaz instance
restart restart topaz instance
status status of topaz daemon process
run run topaz in console mode
manifest manifest commands
test test assertions commands
templates template commands
console open console in the browser
import import directory objects
export export directory objects
backup backup directory data
restore restore directory data
install install topaz container
configure configure topaz service
certs cert commands
update update topaz container version
uninstall uninstall topaz container
version version information
Flags:
-h, --help Show context-sensitive help.
--no-check disable local container status check ($TOPAZ_NO_CHECK)
-N, --no-check disable local container status check ($TOPAZ_NO_CHECK)
-L, --log log level
Run "topaz <command> --help" for more information on a command.
```
Expand Down
57 changes: 27 additions & 30 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,51 +1,49 @@
module github.com/aserto-dev/topaz

go 1.20
go 1.21

// replace github.com/aserto-dev/go-directory => ../go-directory

// replace github.com/aserto-dev/go-edge-ds => ../go-edge-ds

// replace github.com/aserto-dev/azm => ../azm

// replace github.com/aserto-dev/go-topaz-ui => ../go-topaz-ui
// replace github.com/aserto-dev/service-host => ../service-host
// replace github.com/aserto-dev/runtime => ../runtime

require (
github.com/alecthomas/kong v0.8.1
github.com/Masterminds/semver/v3 v3.2.1
github.com/alecthomas/kong v0.9.0
github.com/aserto-dev/aserto-grpc v0.2.2
github.com/aserto-dev/aserto-management v0.9.4
github.com/aserto-dev/azm v0.1.1
github.com/aserto-dev/azm v0.1.3
github.com/aserto-dev/certs v0.0.5
github.com/aserto-dev/clui v0.8.3
github.com/aserto-dev/errors v0.0.6
github.com/aserto-dev/go-aserto v0.31.1
github.com/aserto-dev/errors v0.0.7
github.com/aserto-dev/go-aserto v0.31.2
github.com/aserto-dev/go-authorizer v0.20.5
github.com/aserto-dev/go-directory v0.31.0
github.com/aserto-dev/go-directory v0.31.2
github.com/aserto-dev/go-directory-cli v0.31.0
github.com/aserto-dev/go-edge-ds v0.31.0
github.com/aserto-dev/go-grpc v0.8.63
github.com/aserto-dev/go-topaz-ui v0.1.4
github.com/aserto-dev/header v0.0.6
github.com/aserto-dev/header v0.0.7
github.com/aserto-dev/logger v0.0.4
github.com/aserto-dev/openapi-authorizer v0.20.4
github.com/aserto-dev/openapi-directory v0.31.0
github.com/aserto-dev/openapi-directory v0.31.1
github.com/aserto-dev/runtime v0.62.1
github.com/aserto-dev/self-decision-logger v0.0.5
github.com/aserto-dev/service-host v0.0.9
github.com/cli/browser v1.3.0
github.com/docker/docker v25.0.3+incompatible
github.com/docker/go-connections v0.4.0
github.com/docker/docker v25.0.4+incompatible
github.com/docker/go-connections v0.5.0
github.com/fatih/color v1.16.0
github.com/fullstorydev/grpcurl v1.8.9
github.com/google/uuid v1.6.0
github.com/google/wire v0.5.0
github.com/google/wire v0.6.0
github.com/grpc-ecosystem/go-grpc-middleware v1.4.0
github.com/grpc-ecosystem/grpc-gateway/v2 v2.19.1
github.com/lestrrat-go/jwx/v2 v2.0.20
github.com/lestrrat-go/jwx/v2 v2.0.21
github.com/magefile/mage v1.15.0
github.com/mennanov/fmutils v0.2.1
github.com/mennanov/fmutils v0.3.0
github.com/mitchellh/mapstructure v1.5.0
github.com/open-policy-agent/opa v0.62.1
github.com/opencontainers/image-spec v1.1.0-rc6
Expand All @@ -55,17 +53,17 @@ require (
github.com/samber/lo v1.39.0
github.com/spf13/cobra v1.8.0
github.com/spf13/viper v1.18.2
github.com/stretchr/testify v1.8.4
github.com/stretchr/testify v1.9.0
go.opencensus.io v0.24.0
golang.org/x/sync v0.6.0
google.golang.org/grpc v1.62.0
google.golang.org/protobuf v1.32.0
google.golang.org/grpc v1.62.1
google.golang.org/protobuf v1.33.0
gopkg.in/natefinch/lumberjack.v2 v2.2.1
sigs.k8s.io/controller-runtime v0.17.2
)

require (
buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.32.0-20231115204500-e097f827e652.1 // indirect
buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.33.0-20240221180331-f05a6f4403ce.1 // indirect
contrib.go.opencensus.io/exporter/prometheus v0.4.2 // indirect
github.com/AdaLogics/go-fuzz-headers v0.0.0-20230811130428-ced1acdcaa24 // indirect
github.com/Masterminds/semver v1.5.0 // indirect
Expand All @@ -78,7 +76,7 @@ require (
github.com/aserto-dev/go-http-metrics v0.10.1-20221024-1 // indirect
github.com/beorn7/perks v1.0.1 // indirect
github.com/bufbuild/protocompile v0.7.1 // indirect
github.com/bufbuild/protovalidate-go v0.5.0 // indirect
github.com/bufbuild/protovalidate-go v0.6.0 // indirect
github.com/bytecodealliance/wasmtime-go/v3 v3.0.2 // indirect
github.com/cespare/xxhash/v2 v2.2.0 // indirect
github.com/containerd/containerd v1.7.13 // indirect
Expand All @@ -102,14 +100,13 @@ require (
github.com/goccy/go-json v0.10.2 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/golang/protobuf v1.5.3 // indirect
github.com/google/cel-go v0.19.0 // indirect
github.com/golang/protobuf v1.5.4 // indirect
github.com/google/cel-go v0.20.1 // indirect
github.com/google/pprof v0.0.0-20231212022811-ec68065c825e // indirect
github.com/google/subcommands v1.2.0 // indirect
github.com/gorilla/mux v1.8.1 // indirect
github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.0.0 // indirect
github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.0.1 // indirect
github.com/grpc-ecosystem/grpc-gateway v1.16.0 // indirect
github.com/hashicorp/errwrap v1.1.0 // indirect
github.com/hashicorp/go-multierror v1.1.1 // indirect
github.com/hashicorp/hcl v1.0.0 // indirect
Expand All @@ -119,7 +116,7 @@ require (
github.com/kyokomi/emoji v2.2.4+incompatible // indirect
github.com/lestrrat-go/blackmagic v1.0.2 // indirect
github.com/lestrrat-go/httpcc v1.0.1 // indirect
github.com/lestrrat-go/httprc v1.0.4 // indirect
github.com/lestrrat-go/httprc v1.0.5 // indirect
github.com/lestrrat-go/iter v1.0.2 // indirect
github.com/lestrrat-go/option v1.0.1 // indirect
github.com/magiconair/properties v1.8.7 // indirect
Expand Down Expand Up @@ -172,17 +169,17 @@ require (
go.opentelemetry.io/otel/trace v1.21.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/crypto v0.21.0 // indirect
golang.org/x/exp v0.0.0-20240119083558-1b970713d09a // indirect
golang.org/x/mod v0.14.0 // indirect
golang.org/x/exp v0.0.0-20240222234643-814bf88cf225 // indirect
golang.org/x/mod v0.15.0 // indirect
golang.org/x/net v0.22.0 // indirect
golang.org/x/sys v0.18.0 // indirect
golang.org/x/term v0.18.0 // indirect
golang.org/x/text v0.14.0 // indirect
golang.org/x/time v0.5.0 // indirect
golang.org/x/tools v0.17.0 // indirect
golang.org/x/tools v0.18.0 // indirect
google.golang.org/genproto v0.0.0-20240125205218-1f4bbc51befe // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20240125205218-1f4bbc51befe // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240125205218-1f4bbc51befe // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20240311173647-c811ad7063a7 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240311173647-c811ad7063a7 // indirect
gopkg.in/ini.v1 v1.67.0 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
Expand Down
Loading

0 comments on commit ca47d1f

Please sign in to comment.