build.sh 587 B

12345678910111213141516171819202122232425262728293031323334
  1. #!/bin/bash
  2. #
  3. # This script is executed from within the container.
  4. #
  5. GOPATH=/go
  6. REPO_PATH=$GOPATH/src/github.com/grafana/grafana
  7. mkdir -p /go/src/github.com/grafana
  8. cd /go/src/github.com/grafana
  9. echo "Grafana branch!!"
  10. echo $GRAFANA_BRANCH
  11. echo "GRAFANA BRANCH: ${GRAFANA_BRANCH}"
  12. git clone --depth 1 https://github.com/grafana/grafana.git -b $GRAFANA_BRANCH
  13. cd $REPO_PATH
  14. go run build.go build
  15. npm install -g yarn
  16. yarn install --pure-lockfile
  17. source /etc/profile.d/rvm.sh
  18. rvm use 2.1.9 --default
  19. gem install fpm -v 1.4
  20. go run build.go package latest
  21. cp dist/* /tmp/dist/