Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit d852e8a

Browse filesBrowse files
authored
Refactor update_tools.sh workflow and regenerate par files (bazel-contrib#209)
This reorganizes and comments some package dependencies in the Dockerfile. It also regenerates the par files, so that we're now using pars based on the current version of Bazel. Fixes bazel-contrib#208.
1 parent 08ba1d6 commit d852e8a
Copy full SHA for d852e8a

File tree

3 files changed

+25
-9
lines changed
Filter options

3 files changed

+25
-9
lines changed

‎tools/piptool.par

Copy file name to clipboard
9.5 KB
Binary file not shown.

‎tools/update_tools/Dockerfile

Copy file name to clipboard
+25-9Lines changed: 25 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,35 @@
11
FROM gcr.io/gcp-runtimes/ubuntu_16_0_4:latest
22

3-
# Install Bazel (https://docs.bazel.build/versions/master/install-ubuntu.html)
4-
RUN apt-get update -y && apt-get install openjdk-8-jdk wget git unzip build-essential -y
5-
RUN wget https://github.com/bazelbuild/bazel/releases/download/0.24.0/bazel-0.24.0-installer-linux-x86_64.sh -O /tmp/bazel-installer.sh
3+
# Install Bazel (https://docs.bazel.build/versions/master/install-ubuntu.html#install-with-installer-ubuntu).
4+
RUN apt-get update -y && apt-get install -y \
5+
# The JDK requirement is from the instructions for the bazel apt package,
6+
# which we're not using here, but let's be safe.
7+
openjdk-8-jdk \
8+
# These requirements are from the link above.
9+
pkg-config zip g++ zlib1g-dev unzip python3 \
10+
# And why should python3 have all the fun?
11+
python \
12+
# We also need git for git_repository to work. Maybe these other ones too.
13+
git unzip build-essential \
14+
# And wget for the below command.
15+
wget
16+
17+
RUN wget https://github.com/bazelbuild/bazel/releases/download/0.28.0/bazel-0.28.0-installer-linux-x86_64.sh -O /tmp/bazel-installer.sh
618
RUN chmod +x /tmp/bazel-installer.sh && /tmp/bazel-installer.sh
7-
RUN bazel help info >/dev/null 2>&1
819

9-
# Install Python 2.7.12
10-
RUN apt-get install python -y
20+
# Sanity check the install.
21+
RUN bazel help info >/dev/null 2>&1
1122

12-
# Build par files. We have a source and work directory to avoid
13-
# stomping on other files as root.
23+
# Build par files. We have a source and work directory to avoid stomping on
24+
# other files as root.
1425
CMD cp -r /opt/rules_python_source /opt/rules_python && \
1526
cd /opt/rules_python && \
1627
bazel clean && \
17-
bazel build //rules_python:piptool.par //rules_python:whltool.par && \
28+
bazel build //rules_python:piptool.par //rules_python:whltool.par \
29+
# This works around a bug in git_repository to give us better debugging
30+
# if there's an error.
31+
# TODO(brandjon): Remove this once we're using Bazel 0.29, which
32+
# contains the fix.
33+
--incompatible_string_join_requires_strings=false && \
1834
cp bazel-bin/rules_python/piptool.par bazel-bin/rules_python/whltool.par /opt/rules_python_source/tools/ && \
1935
chown --reference=/opt/rules_python_source/update_tools.sh /opt/rules_python_source/tools/piptool.par /opt/rules_python_source/tools/whltool.par

‎tools/whltool.par

Copy file name to clipboard
9.5 KB
Binary file not shown.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.