Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
keycloak-proxy
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Janne Mareike Koschinski
keycloak-proxy
Commits
4205e4bb
Commit
4205e4bb
authored
5 years ago
by
Bruno Oliveira da Silva
Committed by
Stian Thorgersen
5 years ago
Browse files
Options
Downloads
Patches
Plain Diff
[KEYCLOAK-11249] Release script for Gatekeeper is broken
parent
5a634a66
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
Makefile
+0
-7
0 additions, 7 deletions
Makefile
release.sh
+35
-3
35 additions, 3 deletions
release.sh
with
35 additions
and
10 deletions
Makefile
+
0
−
7
View file @
4205e4bb
...
...
@@ -27,13 +27,6 @@ build: golang
@
mkdir
-p
bin
go build
-ldflags
"
${
LFLAGS
}
"
-o
bin/
${
NAME
}
release
:
clean golang
mkdir
-p
release
$(
foreach GOOS,
$(
PLATFORMS
)
,
\
$(
foreach GOARCH,
$(
ARCHITECTURES
)
,
$(
shell
[
$(
GOOS
)
=
"windows"
]
&&
EXT
=
".exe"
;
env
GOOS
=
$(
GOOS
)
GOARCH
=
$(
GOARCH
)
CGO_ENABLED
=
0 go build
-a
-tags
netgo
-ldflags
"-w
${
LFLAGS
}
"
-o
bin/
${
NAME
}
$$
EXT
;
\
tar
-czvf
release/
${
NAME
}
-
$(
GOOS
)
-
$(
GOARCH
)
.tar.gz
-C
bin/
${
NAME
}
$$
EXT
>
/dev/null
;
\
sha1sum
release/
${
NAME
}
-
$(
GOOS
)
-
$(
GOARCH
)
.tar.gz |
cut
-d
" "
-f1
>
release/
${
NAME
}
-
$(
GOOS
)
-
$(
GOARCH
)
.tar.gz.sha1
)))
static
:
golang
@
echo
"--> Compiling the static binary"
@
mkdir
-p
bin
...
...
This diff is collapsed.
Click to expand it.
release.sh
+
35
−
3
View file @
4205e4bb
#!/bin/bash -e
NAME
=
"keycloak-gatekeeper"
PLATFORMS
=
"darwin linux windows"
ARCHITECTURES
=
"amd64"
GIT_SHA
=
$(
git
--no-pager
describe
--always
--dirty
)
BUILD_TIME
=
$(
date
'+%s'
)
LFLAGS
=
"-X main.gitsha=
$GIT_SHA
-X main.compiled=
$BUILD_TIME
"
DIR
=
"
$PWD
"
VERSION
=
`
./get-version.sh
`
...
...
@@ -6,12 +12,38 @@ echo "Version: $VERSION"
TMP
=
`
mktemp
-d
`
# Perform some clean up before building it
clean
()
{
rm
-rf
./bin/
*
2>/dev/null
rm
-rf
./release/
*
2>/dev/null
}
release
()
{
mkdir
-p
release
for
PLATFORM
in
$PLATFORMS
;
do
EXT
=
""
if
[
"
$PLATFORM
"
==
"windows"
]
;
then
EXT
=
".exe"
fi
for
ARCH
in
$ARCHITECTURES
;
do
env
GOOS
=
$PLATFORM
GOARCH
=
$ARCH
CGO_ENABLED
=
0 go build
-a
-tags
netgo
-ldflags
" -w
$LFLAGS
"
-o
bin/
$NAME$EXT
tar
-czvf
release/
"
$NAME
-
$PLATFORM
-
$ARCH
"
.tar.gz
-C
bin/
$NAME$EXT
>
/dev/null
sha1sum
release/
"
$NAME
-
$PLATFORM
-
$ARCH
"
.tar.gz |
cut
-d
" "
-f1
>
release/
"
$NAME
-
$GOOS
-
$GOARCH
"
.tar.gz.sha1
# Test if tar file is not corrupted
if
!
tar
-tf
release/
"
$NAME
-
$PLATFORM
-
$ARCH
"
.tar.gz &>/dev/null
;
then
echo
"Corrupted tar file"
exit
1
fi
done
done
}
echo
"------------------------------------------------------------------------------------------------------------"
echo
"Building:"
echo
"Building:
$NAME
-
$VERSION
"
echo
""
make re
lea
se
c
lea
n
release
echo
"------------------------------------------------------------------------------------------------------------"
echo
"Upload to jboss.org:"
...
...
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