-
Notifications
You must be signed in to change notification settings - Fork 4k
GH-48013: [R] Add CI job for musl (Alpine Linux) to replicate CRAN checks #48014
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
Merged
Merged
Changes from all commits
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
ca514cc
Add Alpine Linux R Dockerfile
thisisnic 786095d
Remove RE2
thisisnic a9b2fad
Add more docker CI boilerpate
thisisnic 1266ee2
Add stuff to actually install Arrow
thisisnic 1f34820
Add image to compose file
thisisnic 4282113
Add bash
thisisnic 0e3a348
Add alpine-specific commands
thisisnic 22fadf7
Add to system dependencies script too
thisisnic c45e0f7
add linux headers
thisisnic ecbbdca
Add python deps
thisisnic 8f2a047
remove python dep
thisisnic 37a7aac
Add not_cran and move to next to other R builds
thisisnic 528de01
pass in not_cran=false and rername
thisisnic b133606
add texlive dependency
thisisnic 4153585
Add extra tex dependencies
thisisnic 6d465be
add devscripts for checkbashims
thisisnic bc22b46
Add bash
thisisnic 82c40c0
Remove bashism
thisisnic cf0c854
Set ARROW_R_DEV to whatever has been passed in
thisisnic 4a3e265
Remove unnecessary NOT_CRAN flag
thisisnic a63c478
Fix spacing
thisisnic b4f611c
Don't build vignettes
thisisnic 9a81605
Add missing parentheses
thisisnic 5fa4d16
Revert unnecessary brace and manually set 'NOT_CRAN'
thisisnic File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,84 @@ | ||
| # Licensed to the Apache Software Foundation (ASF) under one | ||
| # or more contributor license agreements. See the NOTICE file | ||
| # distributed with this work for additional information | ||
| # regarding copyright ownership. The ASF licenses this file | ||
| # to you under the Apache License, Version 2.0 (the | ||
| # "License"); you may not use this file except in compliance | ||
| # with the License. You may obtain a copy of the License at | ||
| # | ||
| # http://www.apache.org/licenses/LICENSE-2.0 | ||
| # | ||
| # Unless required by applicable law or agreed to in writing, | ||
| # software distributed under the License is distributed on an | ||
| # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
| # KIND, either express or implied. See the License for the | ||
| # specific language governing permissions and limitations | ||
| # under the License. | ||
|
|
||
| # Minimal Alpine Linux container with R for testing Arrow R package | ||
| # on musl libc (CRAN runs checks on Alpine Linux 3.22) | ||
| # Replicates CRAN's Alpine environment as closely as possible | ||
|
|
||
| ARG arch=amd64 | ||
| FROM ${arch}/alpine:3.22 | ||
|
|
||
| # Install R and essential build tools | ||
| # Note: bash is needed for Arrow CI scripts, even though CRAN's Alpine uses BusyBox | ||
| RUN apk add \ | ||
| R \ | ||
| R-dev \ | ||
| R-doc \ | ||
| bash \ | ||
| checkbashisms \ | ||
| cmake \ | ||
| curl-dev \ | ||
| g++ \ | ||
| gcc \ | ||
| git \ | ||
| linux-headers \ | ||
| make \ | ||
| musl-locales \ | ||
| openssl-dev \ | ||
| pkgconfig \ | ||
| zlib-dev && \ | ||
| rm -rf /var/cache/apk/* && \ | ||
| ln -s /usr/share/zoneinfo/Etc/UTC /etc/localtime && \ | ||
| echo "Etc/UTC" > /etc/timezone | ||
|
|
||
| # Set locale and timezone | ||
| ENV LANG=C.UTF-8 \ | ||
| LC_COLLATE=C \ | ||
| MUSL_LOCPATH=/usr/share/i18n/locales/musl | ||
|
|
||
| # Set CRAN repo | ||
| RUN echo 'options(repos = c(CRAN = "https://cran.rstudio.com"))' >> /usr/lib/R/etc/Rprofile.site | ||
|
|
||
| # Install pak for package management (following rhub pattern) | ||
| RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/pak/%s/%s/%s/%s", "devel", .Platform$pkgType, R.Version()$os, R.Version()$arch))' | ||
|
|
||
| # Enable automatic system requirements installation | ||
| ENV PKG_SYSREQS=true \ | ||
| R_PKG_SYSREQS2=true | ||
|
|
||
| # Set up parallel compilation | ||
| RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> /usr/lib/R/etc/Renviron.site | ||
|
|
||
| # Configure image and install Arrow-specific tooling | ||
| COPY ci/scripts/r_docker_configure.sh /arrow/ci/scripts/ | ||
| COPY ci/etc/rprofile /arrow/ci/etc/ | ||
| COPY ci/scripts/r_install_system_dependencies.sh /arrow/ci/scripts/ | ||
| COPY ci/scripts/install_minio.sh /arrow/ci/scripts/ | ||
| COPY ci/scripts/install_gcs_testbench.sh /arrow/ci/scripts/ | ||
| RUN /arrow/ci/scripts/r_docker_configure.sh | ||
|
|
||
| # Install sccache | ||
| COPY ci/scripts/install_sccache.sh /arrow/ci/scripts/ | ||
| RUN /arrow/ci/scripts/install_sccache.sh unknown-linux-musl /usr/local/bin | ||
|
|
||
| # Install R package dependencies | ||
| COPY ci/scripts/r_deps.sh /arrow/ci/scripts/ | ||
| COPY r/DESCRIPTION /arrow/r/ | ||
| RUN /arrow/ci/scripts/r_deps.sh /arrow | ||
|
|
||
| # Verify R works and this is musl | ||
| RUN R --version && ldd --version 2>&1 | grep -q musl |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.