drone change the builds and install sections
Signed-off-by: pipelinebuilder_pel7x64builder0 <pipelinebuilder@powerel.org>master
parent
e3f2dc64df
commit
0b425283bb
|
@ -22,6 +22,13 @@ Group: Agent
|
|||
Agent for the Drone CI Server
|
||||
|
||||
|
||||
%package controller
|
||||
Summary: Controller for Drone Server
|
||||
Group: Controller
|
||||
%description controller
|
||||
Controller for the Drone CI Server
|
||||
|
||||
|
||||
%description
|
||||
Drone is a Continuous Delivery platform
|
||||
built on Docker, written in Go.
|
||||
|
@ -39,25 +46,32 @@ export GOPATH=`pwd`
|
|||
export GO111MODULE=on
|
||||
cd src/github.com/drone/drone
|
||||
git checkout v%{version}
|
||||
%ifarch ppc64
|
||||
export CGO_ENABLED=1
|
||||
%endif
|
||||
go build -tags "oss" -ldflags "-extldflags -s -w"-o drone-server github.com/drone/drone/cmd/drone-server
|
||||
export CGO_ENABLED=1
|
||||
go build -tags "oss" -ldflags "-extldflags -s -w" -o drone-agent github.com/drone/drone/cmd/drone-agent
|
||||
go build -tags "oss" -ldflags "-extldflags -s -w" -o drone-controller github.com/drone//drone/cmd/drone-controller
|
||||
export CGO_ENABLED=0
|
||||
go build -v -ldflags "-s -w -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \n') -buildid %{version}" -o drone-server github.com/drone/drone/cmd/drone-server
|
||||
go build -v -ldflags "-s -w -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \n') -buildid %{version}" -o drone-agent github.com/drone/drone/cmd/drone-agent
|
||||
go build -v -ldflags "-s -w -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \n') -buildid %{version}" -o drone-controller github.com/drone//drone/cmd/drone-controller
|
||||
|
||||
|
||||
%install
|
||||
mkdir -p %{buildroot}%{_bindir}
|
||||
cp -v src/github.com/drone/drone/drone-server %{buildroot}%{_bindir}
|
||||
cp -v src/github.com/drone/drone/drone-agent %{buildroot}%{_bindir}
|
||||
cp -v src/github.com/drone/drone/drone-controller %{buildroot}%{_bindir}
|
||||
|
||||
|
||||
%files
|
||||
|
||||
|
||||
%files server
|
||||
%{_bindir}/drone-server
|
||||
|
||||
|
||||
%files agent
|
||||
%{_bindir}/drone-agent
|
||||
|
||||
|
||||
%files controller
|
||||
%{_bindir}/drone-controller
|
||||
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue