Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Stream Server Project
Stream Server
Commits
0adba982
Commit
0adba982
authored
Aug 22, 2019
by
Simon Kirsten
Browse files
Improved CI pipeline and added version information
parent
416e72a1
Pipeline
#22298
passed with stages
in 1 minute and 29 seconds
Changes
2
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
.gitlab-ci-docs.yml
View file @
0adba982
# This is the CI file for GitLab Pages
pages
:
stage
:
deploy
image
:
python:3.7-alpine
before_script
:
# TODO: we should consider also version locking these packages:
# + everything will work in the future
# - we wont see any future improvements by mkdocs or mkdocs-material
-
pip install mkdocs
-
pip install mkdocs-material
script
:
-
mkdocs build
-
mv site public
-
mv binaries public/
-
mv site public
# move mkdocs output to public
-
mv binaries public/
# move binaries from the build stage to public
artifacts
:
paths
:
-
public
.gitlab-ci-server.yml
View file @
0adba982
# This is the CI file for the stream-tv-server
server
:
stage
:
build
image
:
golang:1.12
variables
:
LDFLAGS
:
-s -X code.fbi.h-da.de/simons-nzse-2/stream-tv/pkg/twitch.ClientID=${TWITCH_CLIENT_ID}
# TWITCH_CLIENT_ID is supplied via the GitLab CI/CD environment variables. This way only project owners can see the private key.
before_script
:
-
VERSION=$(git describe --always --long --dirty)
-
export LDFLAGS="-s -X stream-tv/pkg/twitch.ClientID=$TWITCH_CLIENT_ID -X stream-tv/cmd/stream-tv-server/main.version=$VERSION"
-
go mod download
-
echo "building $VERSION"
script
:
-
env GOOS=darwin GOARCH=386 go build -ldflags "$
{
LDFLAGS
}
" -o binaries/darwin-x86/stream-tv-server ./cmd/stream-tv-server
-
env GOOS=darwin GOARCH=amd64 go build -ldflags "$
{
LDFLAGS
}
" -o binaries/darwin-x86_64/stream-tv-server ./cmd/stream-tv-server
-
env GOOS=darwin GOARCH=386 go build -ldflags "$LDFLAGS" -o binaries/darwin-x86/stream-tv-server ./cmd/stream-tv-server
-
env GOOS=darwin GOARCH=amd64 go build -ldflags "$LDFLAGS" -o binaries/darwin-x86_64/stream-tv-server ./cmd/stream-tv-server
-
env GOOS=linux GOARCH=386 go build -ldflags "$
{
LDFLAGS
}
" -o binaries/linux-x86/stream-tv-server ./cmd/stream-tv-server
-
env GOOS=linux GOARCH=amd64 go build -ldflags "$
{
LDFLAGS
}
" -o binaries/linux-x86_64/stream-tv-server ./cmd/stream-tv-server
-
env GOOS=linux GOARCH=arm go build -ldflags "$
{
LDFLAGS
}
" -o binaries/linux-arm/stream-tv-server ./cmd/stream-tv-server
-
env GOOS=linux GOARCH=arm64 go build -ldflags "$
{
LDFLAGS
}
" -o binaries/linux-arm64/stream-tv-server ./cmd/stream-tv-server
-
env GOOS=linux GOARCH=386 go build -ldflags "$LDFLAGS" -o binaries/linux-x86/stream-tv-server ./cmd/stream-tv-server
-
env GOOS=linux GOARCH=amd64 go build -ldflags "$LDFLAGS" -o binaries/linux-x86_64/stream-tv-server ./cmd/stream-tv-server
-
env GOOS=linux GOARCH=arm go build -ldflags "$LDFLAGS" -o binaries/linux-arm/stream-tv-server ./cmd/stream-tv-server
-
env GOOS=linux GOARCH=arm64 go build -ldflags "$LDFLAGS" -o binaries/linux-arm64/stream-tv-server ./cmd/stream-tv-server
-
env GOOS=windows GOARCH=386 go build -ldflags "$
{
LDFLAGS
}
" -o binaries/windows-x86/stream-tv-server.exe ./cmd/stream-tv-server
-
env GOOS=windows GOARCH=amd64 go build -ldflags "$
{
LDFLAGS
}
" -o binaries/windows-x86_64/stream-tv-server.exe ./cmd/stream-tv-server
-
env GOOS=windows GOARCH=386 go build -ldflags "$LDFLAGS" -o binaries/windows-x86/stream-tv-server.exe ./cmd/stream-tv-server
-
env GOOS=windows GOARCH=amd64 go build -ldflags "$LDFLAGS" -o binaries/windows-x86_64/stream-tv-server.exe ./cmd/stream-tv-server
artifacts
:
paths
:
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment