Commit 1fee2692 by bergquist

Merge branch 'new_deploy'

parents 46e4a54a 4b6aaec8
......@@ -90,7 +90,7 @@ func main() {
case "package":
grunt(gruntBuildArg("release")...)
createLinuxPackages()
sha1FilesInDist()
//sha1FilesInDist()
case "pkg-rpm":
grunt(gruntBuildArg("release")...)
......@@ -107,7 +107,7 @@ func main() {
case "latest":
makeLatestDistCopies()
sha1FilesInDist()
//sha1FilesInDist()
case "clean":
clean()
......@@ -516,8 +516,15 @@ func md5File(file string) error {
func sha1FilesInDist() {
filepath.Walk("./dist", func(path string, f os.FileInfo, err error) error {
if strings.Contains(path, ".sha1") == false {
sha1File(path)
if path == "./dist" {
return nil
}
if strings.Contains(path, ".sha1") == false {
err := sha1File(path)
if err != nil {
log.Printf("Failed to create sha file. error: %v\n", err)
}
}
return nil
})
......
......@@ -11,7 +11,8 @@ machine:
REPO_PATH: "${ORG_PATH}/grafana"
GODIST: "go1.7.4.linux-amd64.tar.gz"
post:
- mkdir -p download
- mkdir -p ~/download
- mkdir -p ~/docker
- test -e download/$GODIST || curl -o download/$GODIST https://storage.googleapis.com/golang/$GODIST
- sudo rm -rf /usr/local/go
- sudo tar -C /usr/local -xzf download/$GODIST
......@@ -32,23 +33,24 @@ test:
deployment:
gh_branch:
branch: new_deploy
owner: grafana
commands:
- pip install awscli
- sudo apt-get update; sudo apt-get install rpm; sudo apt-get install expect
- ./scripts/build/build_container.sh
- ./scripts/build/deploy.sh
- aws s3 sync ./dist s3://$NIGHTLY_BUCKET_NAME
#- ./scripts/build/sign_packages.sh
- ./scripts/build/sign_packages.sh
- go run build.go sha1-dist
- aws s3 sync ./dist s3://$BUCKET_NAME/master
#- ./scripts/trigger_grafana_docker_build.sh ${TRIGGER_GRAFANA_DOCKER_CIRCLECI_TOKEN}
gh_tag:
tag: /^v[0-9]+(\.[0-9]+){2}(-.+|[^-.]*)$/
owner: grafana
commands:
- echo lets release stuff!
- pip install awscli
- sudo apt-get update; sudo apt-get install rpm; sudo apt-get install expect
- ./scripts/build/build_container.sh
- ./scripts/build/deploy.sh
#- ./scripts/build/sign_packages.sh
#- aws s3 sync ./dist s3://$BUCKET_NAME
- ./scripts/build/sign_packages.sh
- go run build.go sha1-dist
- aws s3 sync ./dist s3://$BUCKET_NAME/release
#- ./scripts/trigger_grafana_docker_build.sh ${TRIGGER_GRAFANA_DOCKER_CIRCLECI_TOKEN}
......@@ -16,7 +16,7 @@ if [ -n "${CIRCLE_TAG}" ]; then
cd $REPO_PATH
else
echo "Building from branch ${CIRCLE_BRANCH}"
git clone --depth 1 https://github.com/grafana/grafana.git
git clone https://github.com/grafana/grafana.git
cd $REPO_PATH
git checkout $CIRCLE_TAG
fi
......
%_signature gpg
%_gpg_path /home/ubuntu/.gnupg
%_gpg_name Grafana
%_gpgbin /usr/bin/gpg
......@@ -4,6 +4,6 @@ git clone git@github.com:torkelo/private.git ~/private-repo
gpg --allow-secret-key-import --import ~/private-repo/signing/private.key
cp rpmmacros ~/.rpmmacros
cp ./scripts/build/rpmmacros ~/.rpmmacros
./sign_expect $GPG_KEY_PASSWORD dist/*.rpm
./scripts/build/sign_expect $GPG_KEY_PASSWORD dist/*.rpm
......@@ -18,7 +18,7 @@ yarn install --pure-lockfile
exit_if_fail npm test
exit_if_fail test -z "$(gofmt -s -l ./pkg/... | tee /dev/stderr)"
exit_if_fail test -z "$(gofmt -s -l ./pkg | tee /dev/stderr)"
exit_if_fail go run build.go build
exit_if_fail go vet ./pkg/...
exit_if_fail go test -v ./pkg/...
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment