Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
kube-bench
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
GitHub Mirror
aquasecurity
kube-bench
Commits
91dfeb75
Unverified
Commit
91dfeb75
authored
5 years ago
by
Roberto Rojas
Committed by
GitHub
5 years ago
Browse files
Options
Downloads
Patches
Plain Diff
passes KUBEBENCH_VERSION down to Dockerfile (#428)
parent
4416e469
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
Dockerfile
+2
-1
2 additions, 1 deletion
Dockerfile
makefile
+2
-1
2 additions, 1 deletion
makefile
with
4 additions
and
2 deletions
Dockerfile
+
2
−
1
View file @
91dfeb75
...
...
@@ -4,7 +4,8 @@ ADD go.mod go.sum ./
ADD
main.go .
ADD
check/ check/
ADD
cmd/ cmd/
RUN
GO111MODULE
=
on
CGO_ENABLED
=
0 go
install
-a
-ldflags
'-w'
ARG
KUBEBENCH_VERSION
RUN
GO111MODULE
=
on
CGO_ENABLED
=
0 go
install
-a
-ldflags
"-X github.com/aquasecurity/kube-bench/cmd.KubeBenchVersion=
${
KUBEBENCH_VERSION
}
-w"
FROM
alpine:3.10
AS
run
WORKDIR
/opt/kube-bench/
...
...
This diff is collapsed.
Click to expand it.
makefile
+
2
−
1
View file @
91dfeb75
...
...
@@ -4,7 +4,7 @@ DOCKER_REGISTRY ?= aquasec
VERSION
?=
$(
shell git rev-parse
--short
=
7 HEAD
)
KUBEBENCH_VERSION
?=
$(
shell git describe
--tags
--abbrev
=
0
)
IMAGE_NAME
?=
$(
DOCKER_REGISTRY
)
/
$(
BINARY
)
:
$(
VERSION
)
TARGET_OS
:
=
linux
TARGET_OS
?
=
linux
BUILD_OS
:=
linux
uname
:=
$(
shell
uname
-s
)
...
...
@@ -29,6 +29,7 @@ $(BINARY): $(SOURCES)
build-docker
:
docker build
--build-arg
BUILD_DATE
=
$(
shell
date
-u
+
"%Y-%m-%dT%H:%M:%SZ"
)
\
--build-arg
VCS_REF
=
$(
shell git rev-parse
--short
HEAD
)
\
--build-arg
KUBEBENCH_VERSION
=
$(
KUBEBENCH_VERSION
)
\
-t
$(
IMAGE_NAME
)
.
tests
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment