File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ ARG GO_VERSION=1.18
2+ FROM golang:${GO_VERSION}-bullseye
3+
4+ ARG BAZELISK_VERSION=1.24.0
5+ RUN CGO_ENABLED=0 GOOS=linux GOBIN=/usr/local/bin go install github.com/bazelbuild/bazelisk@v${BAZELISK_VERSION}
6+
7+ # Install packages
8+ # git required for blueprint
9+ # build-essential needed for io_bazel_rules_go
10+ RUN apt update \
11+ && apt -y --no-install-recommends install \
12+ ca-certificates \
13+ build-essential \
14+ gcc-aarch64-linux-gnu \
15+ git \
16+ ninja-build \
17+ python3 \
18+ python3-dev \
19+ python3-pip \
20+ python-is-python3 \
21+ python3-ply \
22+ rsync \
23+ && rm -rf /var/lib/apt/lists/*
24+
25+ RUN printf '%s\n ' 'export PATH=/home/ci/.local/bin:/go/bin:/usr/local/go/bin:$PATH' \
26+ > /etc/profile.d/bob-build-env-path.sh
27+
28+
29+ ARG USER_ID=1001
30+ RUN useradd --create-home --shell /bin/bash --uid $USER_ID ci
31+ USER ci
32+ WORKDIR /home/ci
33+
34+ ENV PATH=/home/ci/.local/bin:$PATH
35+ ENV BAZELISK_HOME=/home/ci/.cache/bazelisk
36+
37+ # Pre-download _latest_ bazel version to save time in CI
38+ RUN bash -lc 'go version' && \
39+ USE_BAZEL_VERSION=latest bazelisk --version && \
40+ USE_BAZEL_VERSION=8.0.0 bazelisk --version
Original file line number Diff line number Diff line change 1+ # bob-build-env docker image
2+
3+ This docker image contains the required dependencies to run the build tests in ci, including
4+ the new bazel based build tests.
5+
6+ # Creating the docker image
7+
8+ ```
9+ docker build -t bob-build-env ci/docker/bob-build-env/
10+ docker tag bob-build-env:latest gpuddk--docker.artifactory.arm.com/gpuddk/bob-build-env:latest
11+ ```
12+
13+ # Pushing to Artifactory
14+
15+ ```
16+ export EMAIL=<your_email>
17+ export ART_TOKEN=<artifactory_token>
18+ docker login -u$EMAIL -p$ART_TOKEN gpuddk--docker.artifactory.arm.com
19+ docker push gpuddk--docker.artifactory.arm.com/gpuddk/bob-build-env:latest
20+ ```
You can’t perform that action at this time.
0 commit comments