fix minor changes after code review
Signed-off-by: Slach <bloodjazman@gmail.com>
This commit is contained in:
Родитель
e3aad6af25
Коммит
6a5160f873
|
@ -3,8 +3,6 @@ FROM alpine:latest
|
|||
EXPOSE 3001
|
||||
ENV GOPATH=/tmp/go
|
||||
|
||||
# ADD ./ ${GOPATH}/src/github.com/github/orchestrator-agent/
|
||||
|
||||
RUN set -ex \
|
||||
&& apk add --update --no-cache bash \
|
||||
&& apk add --update --no-cache --virtual .build-deps \
|
||||
|
@ -14,8 +12,6 @@ RUN set -ex \
|
|||
build-base \
|
||||
&& cd /tmp \
|
||||
&& { go get -d github.com/github/orchestrator-agent ; : ; }
|
||||
# && cd $GOPATH/src/github.com/github/orchestrator-agent/ \
|
||||
# && go get ./go/... \
|
||||
&& find $GOPATH/src/ -name *.go \
|
||||
&& bash -x build.sh -b \
|
||||
&& rsync -av $(find /tmp/orchestrator-agent-release -type d -name orchestrator-agent -maxdepth 2)/ / \
|
||||
|
|
|
@ -349,7 +349,7 @@ func LogicalVolumes(volumeName string, filterPattern string) ([]LogicalVolume, e
|
|||
return nil, err
|
||||
}
|
||||
|
||||
var logicalVolumes []LogicalVolume
|
||||
logicalVolumes := []LogicalVolume{}
|
||||
for _, lineTokens := range tokens {
|
||||
logicalVolume := LogicalVolume{
|
||||
Name: lineTokens[1],
|
||||
|
@ -357,7 +357,7 @@ func LogicalVolumes(volumeName string, filterPattern string) ([]LogicalVolume, e
|
|||
Path: lineTokens[3],
|
||||
}
|
||||
logicalVolume.SnapshotPercent, err = strconv.ParseFloat(lineTokens[4], 32)
|
||||
logicalVolume.IsSnapshot = err == nil
|
||||
logicalVolume.IsSnapshot = (err == nil)
|
||||
if strings.Contains(logicalVolume.Name, filterPattern) {
|
||||
logicalVolumes = append(logicalVolumes, logicalVolume)
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#!/bin/bash
|
||||
|
||||
PACKAGECLOUD_USER="${PACKAGECLOUD_USER:-github}"
|
||||
PACKAGECLOUD_REPO="${PACKAGECLOUD_REPO:-orchestrator}"
|
||||
PACKAGECLOUD_REPO="${PACKAGECLOUD_REPO:-orchestrator-agent}"
|
||||
packagecloud_uri="https://${PACKAGECLOUD_TOKEN}:@packagecloud.io"
|
||||
latest_tag=$(git describe --abbrev=0 --tags | tr -d "v")
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# Pushes all deb and rpm files from ./repos to PackageCloud.
|
||||
|
||||
packagecloud_user = ENV["PACKAGECLOUD_USER"] || "github"
|
||||
packagecloud_repo = ENV["PACKAGECLOUD_REPO"] || "orchestrator"
|
||||
packagecloud_repo = ENV["PACKAGECLOUD_REPO"] || "orchestrator-agent"
|
||||
packagecloud_token = ENV["PACKAGECLOUD_TOKEN"] || begin
|
||||
puts "PACKAGECLOUD_TOKEN env required"
|
||||
exit 1
|
||||
|
|
Загрузка…
Ссылка в новой задаче