Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: upload binaries to github as releases #2606

Open
wants to merge 10 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 32 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,11 @@ commands:
- run:
name: Deploy Release Packages
command: |
GHR_VERSION=v0.14.0
wget https://github.com/tcnksm/ghr/releases/download/${GHR_VERSION}/ghr_${GHR_VERSION}_linux_amd64.tar.gz
tar -xzf ghr_${GHR_VERSION}_linux_amd64.tar.gz
./build.sh --debug --clean --generate --package --package-udfs --upload --bucket=dl.influxdata.com/kapacitor/releases --platform=all --arch=all --release
./ghr_${GHR_VERSION}_linux_amd64/ghr -t ${GITHUB_TOKEN} -u ${CIRCLE_PROJECT_USERNAME} -r ${CIRCLE_PROJECT_REPONAME} -c ${CIRCLE_SHA1} -delete -replace ${CIRCLE_TAG} ./build/

run_tests:
description: >
Expand All @@ -19,6 +23,7 @@ commands:
name: Running Kapacitor Tests
no_output_timeout: 30m
command: |
mkdir -p /go
./circle-test.sh
deploy_nightly:
description: >
Expand All @@ -34,32 +39,58 @@ jobs:
docker:
- image: nathanielc/docker-client
parallelism: 2
resource_class: large
working_directory: ~/kapacitor
steps:
- checkout
- restore_cache: # restores saved cache if no changes are detected since last run
keys:
- v0-go-mod-{{ checksum "go.sum" }}
- v0-go-mod-
- setup_remote_docker:
docker_layer_caching: true
- run_tests
- save_cache:
key: v0-go-mod-{{ checksum "go.sum" }}
paths:
- "/go/pkg/mod"

release:
docker:
- image: nathanielc/docker-client
working_directory: ~/kapacitor
resource_class: large
steps:
- checkout
- restore_cache: # restores saved cache if no changes are detected since last run
keys:
- v0-go-mod-{{ checksum "go.sum" }}
- v0-go-mod-
- setup_remote_docker:
docker_layer_caching: true
- deploy_release_packages
- save_cache:
key: v0-go-mod-{{ checksum "go.sum" }}
paths:
- "/go/pkg/mod"

nightly-build:
docker:
- image: nathanielc/docker-client
working_directory: ~/kapacitor
steps:
- checkout
- restore_cache: # restores saved cache if no changes are detected since last run
keys:
- v0-go-mod-{{ checksum "go.sum" }}
- v0-go-mod-
- setup_remote_docker:
docker_layer_caching: true
- run_tests
- save_cache:
key: v0-go-mod-{{ checksum "go.sum" }}
paths:
- "/go/pkg/mod"
- deploy_nightly


Expand All @@ -76,7 +107,7 @@ workflows:
- build
filters:
tags:
only: /^v[0-9]+(\.[0-9]+){2}(-(rc|beta)[0-9]+)?/
only: /^v[0-9]+(\.[0-9]+){2}(-(rc|beta|test)[0-9]+)?/
branches:
ignore: /.*/

Expand Down
3 changes: 1 addition & 2 deletions Dockerfile_build_ubuntu64
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ RUN gem install fpm
# Install protobuf3 protoc binary
ENV PROTO_VERSION 3.11.1
RUN wget -q https://github.com/google/protobuf/releases/download/v${PROTO_VERSION}/protoc-${PROTO_VERSION}-linux-x86_64.zip \
&& unzip -j protoc-${PROTO_VERSION}-linux-x86_64.zip bin/protoc -d /bin \
&& unzip -oj protoc-${PROTO_VERSION}-linux-x86_64.zip bin/protoc -d /bin \
rm protoc-${PROTO_VERSION}-linux-x86_64.zip

# Install protobuf3 python library
Expand All @@ -49,7 +49,6 @@ RUN wget -q https://github.com/google/protobuf/releases/download/v${PROTO_VERSIO
&& rm -rf /protobuf-${PROTO_VERSION} protobuf-python-${PROTO_VERSION}.tar.gz

ENV PROJECT_DIR $GOPATH/src/github.com/influxdata/kapacitor
#ENV PKG_CONFIG $PROJECT_DIR/pkg-config.sh
ENV PATH $GOPATH/bin:$PATH
RUN mkdir -p $PROJECT_DIR
WORKDIR $PROJECT_DIR
Expand Down
Loading