Browse Source

drone update to add drone-cli

Signed-off-by: pipelinebuilder_pel7x64builder0 <pipelinebuilder@powerel.org>
master
pipelinebuilder_pel7x64builder0 3 years ago
parent
commit
56cac09a18
  1. 29
      SPECS/drone.spec

29
SPECS/drone.spec

@ -8,6 +8,11 @@ BuildRequires: golang
#Requires: #Requires:




%description
Drone is a Continuous Delivery platform
built on Docker, written in Go.


%package server %package server
Summary: Documentation files for %{name} Summary: Documentation files for %{name}
Group: Documentation Group: Documentation
@ -29,9 +34,10 @@ Group: Controller
Controller for the Drone CI Server Controller for the Drone CI Server




%description %package cli
Drone is a Continuous Delivery platform Summary: CLI for Drone Server
built on Docker, written in Go. %description cli
CLI For Drone CI Server




%prep %prep
@ -39,17 +45,22 @@ built on Docker, written in Go.
mkdir -p src/github.com/drone mkdir -p src/github.com/drone
cd src/github.com/drone cd src/github.com/drone
git clone https://github.com/drone/drone git clone https://github.com/drone/drone
git clone https://github.com/drone/drone-cli




%build %build
export GOPATH=`pwd` export GOPATH=`pwd`
export GO111MODULE=on export GO111MODULE=on
cd src/github.com/drone/drone pushd src/github.com/drone/drone
git checkout v%{version} git checkout v%{version}
export CGO_ENABLED=0 export CGO_ENABLED=0
go build -v -tags 'oss nolimit' -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 -tags "oss nolimit" -trimpath -ldflags "-X main.version=%{version} -s -w -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \n')" -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 -trimpath -ldflags "-X main.version=%{version} -s -w -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \n')" -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 go build -v -trimpath -ldflags "-X main.version=%{version} -s -w -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \n')" -o drone-controller github.com/drone//drone/cmd/drone-controller
popd
pushd src/github.com/drone/drone-cli
go build -v -trimpath -ldflags "-X main.version=%{version} -s -w -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \n')" -o drone-cli github.com/drone/drone-cli/drone
popd




%install %install
@ -57,6 +68,7 @@ mkdir -p %{buildroot}%{_bindir}
cp -v src/github.com/drone/drone/drone-server %{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-agent %{buildroot}%{_bindir}
cp -v src/github.com/drone/drone/drone-controller %{buildroot}%{_bindir} cp -v src/github.com/drone/drone/drone-controller %{buildroot}%{_bindir}
cp -v src/github.com/drone/drone-cli/drone-cli %{buildroot}%{_bindir}




%files %files
@ -74,5 +86,8 @@ cp -v src/github.com/drone/drone/drone-controller %{buildroot}%{_bindir}
%{_bindir}/drone-controller %{_bindir}/drone-controller




%files cli
%{_bindir}/drone-cli



%changelog %changelog

Loading…
Cancel
Save