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

Oleg/bazel test #5

Closed
wants to merge 5 commits into from
Closed
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
3 changes: 3 additions & 0 deletions .bazelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
build --@rules_rust//rust/toolchain/channel=nightly
build --cxxopt=-std=c++14
build --host_cxxopt=-std=c++14
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,6 @@
# Substrate
*.log
*.out

# bazel
bazel-*
40 changes: 40 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
stages:
- test
- build

variables:
CI_IMAGE: "docker.io/paritytech/ci-unified:latest"
BUILDAH_IMAGE: "quay.io/buildah/stable:v1.29"
BUILDAH_COMMAND: "buildah --storage-driver overlay2"
VAULT_ADDR: "https://vault.parity-mgmt-vault.parity.io"
VAULT_AUTH_PATH: "gitlab-parity-io-jwt"
VAULT_AUTH_ROLE: "gitlab_${CI_PROJECT_NAME}"
HELM_SECRETS_DRIVER: vals

default:
image: $CI_IMAGE
tags:
- linux-docker-vm-c2

test-unit:
stage: test
script:
- echo "Test..."
build-bazel:
stage: build
script:
- apt update && apt install apt-transport-https curl gnupg -y;
curl -fsSL https://bazel.build/bazel-release.pub.gpg | gpg --dearmor >bazel-archive-keyring.gpg;
mv bazel-archive-keyring.gpg /usr/share/keyrings;
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/bazel-archive-keyring.gpg] https://storage.googleapis.com/bazel-apt stable jdk1.8" | tee /etc/apt/sources.list.d/bazel.list
- apt update && apt install bazel -y
- bazel build //cli --action_env=PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin --remote_cache=https://storage.googleapis.com/bazel-cache-parity-build --google_default_credentials

build-cargo:
stage: build
cache:
key: target
paths:
- target/
script:
- cargo build
Empty file added BUILD.bazel
Empty file.
Loading
Loading