Skip to content

Commit 13f578b

Browse files
authored
Build R API document. (#6)
1 parent 8508a80 commit 13f578b

File tree

3 files changed

+50
-0
lines changed

3 files changed

+50
-0
lines changed

.github/workflows/containers.yml

+1
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ jobs:
4545
container_id:
4646
- xgb-ci.clang_tidy
4747
- xgb-ci.cpu
48+
- xgb-ci.cpu_build_r_doc
4849
- xgb-ci.gpu
4950
- xgb-ci.gpu_build_r_rockylinux8
5051
- xgb-ci.gpu_build_rockylinux8

containers/ci_container.yml

+3
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ xgb-ci.gpu_build_r_rockylinux8:
2727
CUDA_VERSION: "12.4.1"
2828
R_VERSION: "4.3.2"
2929

30+
xgb-ci.cpu_build_r_doc:
31+
container_def: cpu_build_r_doc
32+
3033
xgb-ci.gpu:
3134
container_def: gpu
3235
build_args:
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
FROM ubuntu:22.04
2+
3+
SHELL ["/bin/bash", "-c"]
4+
5+
ENV DEBIAN_FRONTEND=noninteractive
6+
7+
# Install all basic requirements
8+
RUN \
9+
apt-get update && \
10+
apt install --no-install-recommends software-properties-common dirmngr wget -y && \
11+
wget -qO- https://cloud.r-project.org/bin/linux/ubuntu/marutter_pubkey.asc | tee -a /etc/apt/trusted.gpg.d/cran_ubuntu_key.asc && \
12+
add-apt-repository "deb https://cloud.r-project.org/bin/linux/ubuntu $(lsb_release -cs)-cran40/" && \
13+
apt-get update && \
14+
apt-get install -y --no-install-recommends r-base
15+
16+
RUN \
17+
apt-get install \
18+
make cmake g++ gcc \
19+
libssl-dev libfreetype6-dev libpng-dev libtiff5-dev \
20+
libjpeg-dev libxml2-dev libcurl4-openssl-dev libharfbuzz-dev \
21+
libfribidi-dev libfontconfig1-dev libfontconfig1-dev libv8-dev \
22+
pandoc gfortran libblas-dev liblapack-dev librsvg2-dev -y
23+
24+
ENV GOSU_VERSION=1.10
25+
26+
# Install lightweight sudo (not bound to TTY)
27+
RUN set -ex; \
28+
wget -nv -O /usr/local/bin/gosu "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-amd64" && \
29+
chmod +x /usr/local/bin/gosu && \
30+
gosu nobody true
31+
32+
# Default entry-point to use if running locally
33+
# It will preserve attributes of created files
34+
COPY entrypoint.sh /scripts/
35+
36+
WORKDIR /workspace
37+
38+
RUN mkdir /tmp/rtmpdir
39+
40+
ENV R_LIBS_USER=/tmp/rtmpdir
41+
ENV DOWNLOAD_STATIC_LIBV8=0
42+
43+
RUN \
44+
MAKEFLAGS=-j$(nproc) Rscript -e "install.packages(c('pkgdown', 'knitr'), repos = 'https://mirror.las.iastate.edu/CRAN/', Ncpus = parallel::detectCores())"
45+
46+
ENTRYPOINT ["/scripts/entrypoint.sh"]

0 commit comments

Comments
 (0)