Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
V
verse
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Analyze
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
rocker
verse
Commits
3c062d88
Commit
3c062d88
authored
6 years ago
by
Carl Boettiger
Browse files
Options
Downloads
Patches
Plain Diff
test: make 3.5.1 == latest
parent
60448f64
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
r-ver/3.5.1/hooks/post_push
+49
-0
49 additions, 0 deletions
r-ver/3.5.1/hooks/post_push
r-ver/Dockerfile
+1
-132
1 addition, 132 deletions
r-ver/Dockerfile
r-ver/Dockerfile
+1
-132
1 addition, 132 deletions
r-ver/Dockerfile
with
51 additions
and
264 deletions
r-ver/3.5.1/hooks/post_push
0 → 100644
+
49
−
0
View file @
3c062d88
#!/bin/bash
set
-e
# add additional tags without bugfix and minor version
MAJ_MIN_BUG
=
${
PWD
##*/
}
MAJ_MIN
=
$(
echo
$MAJ_MIN_BUG
|
sed
"s/
\.
[^
\.
]*
$/
/"
)
MAJ
=
$(
echo
$MAJ_MIN
|
sed
"s/
\.
[^
\.
]*
$/
/"
)
echo
"Add version tags for major and major.minor releases."
## x.y.z
# Tag for major.minor.bug is already provided by Docker Hub configuration
## x.y
# Check if this image is newest within major.minor
NEWEST_MAJ_MIN
=
`
ls
../ |
grep
"^
$MAJ_MIN
"
|
sort
--version-sort
|
tail
-n
1
`
if
[
"
$MAJ_MIN_BUG
"
==
"
$NEWEST_MAJ_MIN
"
]
then
echo
"This version is also the newest major.minor version, add tag '
$MAJ_MIN
' to '
$MAJ_MIN_BUG
'"
docker tag
$IMAGE_NAME
$DOCKER_REPO
:
$MAJ_MIN
docker push
$DOCKER_REPO
:
$MAJ_MIN
else
echo
"
$NEWEST_MAJ_MIN
is newest version starting with
$MAJ_MIN
, not tagging this one (
$MAJ_MIN_BUG
)."
fi
## x
# Check if this image is "latest" within major
NEWEST_MAJ
=
`
ls
../ |
grep
"^
$MAJ
"
|
sort
--version-sort
|
tail
-n
1
`
if
[
"
$MAJ_MIN_BUG
"
==
"
$NEWEST_MAJ
"
]
then
echo
"This version is also the newest major version, add tag '
$MAJ
' to '
$MAJ_MIN_BUG
'."
docker tag
$IMAGE_NAME
$DOCKER_REPO
:
$MAJ
docker push
$DOCKER_REPO
:
$MAJ
else
echo
"
$NEWEST_MAJ
is newest version starting with
$MAJ
, not tagging this one (
$MAJ_MIN_BUG
)."
fi
## Get "latest": list parent directory files starting with number, sort them and only select the last one
LATEST
=
`
ls
../ |
grep
'^[0-9]'
|
sort
--version-sort
|
tail
-n
1
`
if
[
"
$MAJ_MIN_BUG
"
==
"
$LATEST
"
]
then
echo
"This version is also newest version overall, add 'latest' tag to
$MAJ_MIN_BUG
"
docker tag
$IMAGE_NAME
$DOCKER_REPO
:latest
docker push
$DOCKER_REPO
:latest
else
echo
"
$LATEST
is newest version overall, not tagging this one (
$MAJ_MIN_BUG
) with latest."
fi
echo
"Version tagging completed."
This diff is collapsed.
Click to expand it.
r-ver/Dockerfile
deleted
100644 → 0
+
1
−
132
View file @
60448f64
FROM
debian:stretch
LABEL
org.label-schema.license="GPL-2.0" \
org.label-schema.vcs-url="https://github.com/rocker-org/rocker-versioned" \
org.label-schema.vendor="Rocker Project" \
maintainer="Carl Boettiger <cboettig@ropensci.org>"
ARG
R_VERSION
ARG
BUILD_DATE
ENV
R_VERSION=${R_VERSION:-3.5.1} \
LC_ALL=en_US.UTF-8 \
LANG=en_US.UTF-8 \
TERM=xterm
RUN
apt-get update
\
&&
apt-get
install
-y
--no-install-recommends
\
bash-completion
\
ca-certificates
\
file
\
fonts-texgyre
\
g++
\
gfortran
\
gsfonts
\
libblas-dev
\
libbz2-1.0
\
libcurl3
\
libicu57
\
libjpeg62-turbo
\
libopenblas-dev
\
libpangocairo-1.0-0
\
libpcre3
\
libpng16-16
\
libreadline7
\
libtiff5
\
liblzma5
\
locales
\
make
\
unzip
\
zip
\
zlib1g
\
&&
echo
"en_US.UTF-8 UTF-8"
>>
/etc/locale.gen
\
&&
locale-gen en_US.utf8
\
&&
/usr/sbin/update-locale
LANG
=
en_US.UTF-8
\
&&
BUILDDEPS
=
"curl
\
default-jdk
\
libbz2-dev
\
libcairo2-dev
\
libcurl4-openssl-dev
\
libpango1.0-dev
\
libjpeg-dev
\
libicu-dev
\
libpcre3-dev
\
libpng-dev
\
libreadline-dev
\
libtiff5-dev
\
liblzma-dev
\
libx11-dev
\
libxt-dev
\
perl
\
tcl8.6-dev
\
tk8.6-dev
\
texinfo
\
texlive-extra-utils
\
texlive-fonts-recommended
\
texlive-fonts-extra
\
texlive-latex-recommended
\
x11proto-core-dev
\
xauth
\
xfonts-base
\
xvfb
\
zlib1g-dev"
\
&&
apt-get
install
-y
--no-install-recommends
$BUILDDEPS
\
&&
cd
tmp/
\
## Download source code
&& curl -O https://cran.r-project.org/src/base/R-3/R-${R_VERSION}.tar.gz \
## Extract source code
&& tar -xf R-${R_VERSION}.tar.gz \
&& cd R-${R_VERSION} \
## Set compiler flags
&& R_PAPERSIZE=letter \
R_BATCHSAVE="--no-save --no-restore" \
R_BROWSER=xdg-open \
PAGER=/usr/bin/pager \
PERL=/usr/bin/perl \
R_UNZIPCMD=/usr/bin/unzip \
R_ZIPCMD=/usr/bin/zip \
R_PRINTCMD=/usr/bin/lpr \
LIBnn=lib \
AWK=/usr/bin/awk \
CFLAGS="-g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g" \
CXXFLAGS="-g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g" \
## Configure options
./configure --enable-R-shlib \
--enable-memory-profiling \
--with-readline \
--with-blas \
--with-tcltk \
--disable-nls \
--with-recommended-packages \
## Build and install
&& make \
&& make install \
## Add a default CRAN mirror
&& echo "options(repos = c(CRAN = 'https://cran.rstudio.com/'), download.file.method = 'libcurl')" >> /usr/local/lib/R/etc/Rprofile.site \
## Add a library directory (for user-installed packages)
&& mkdir -p /usr/local/lib/R/site-library \
&& chown root:staff /usr/local/lib/R/site-library \
&& chmod g+wx /usr/local/lib/R/site-library \
## Fix library path
&& echo "R_LIBS_USER='/usr/local/lib/R/site-library'" >> /usr/local/lib/R/etc/Renviron \
&& echo "R_LIBS=\${R_LIBS-'/usr/local/lib/R/site-library:/usr/local/lib/R/library:/usr/lib/R/library'}" >> /usr/local/lib/R/etc/Renviron \
## install packages from date-locked MRAN snapshot of CRAN
&& [ -z "$BUILD_DATE" ] && BUILD_DATE=$(TZ="America/Los_Angeles" date -I) || true \
&& MRAN=https://mran.microsoft.com/snapshot/${BUILD_DATE} \
&& echo MRAN=$MRAN >> /etc/environment \
&& export MRAN=$MRAN \
## MRAN becomes default only in versioned images
## Use littler installation scripts
&& Rscript -e "install.packages(c('littler', 'docopt'))" \
&& ln -s /usr/local/lib/R/site-library/littler/examples/install2.r /usr/local/bin/install2.r \
&& ln -s /usr/local/lib/R/site-library/littler/examples/installGithub.r /usr/local/bin/installGithub.r \
&& ln -s /usr/local/lib/R/site-library/littler/bin/r /usr/local/bin/r \
## Clean up from R source install
&& cd / \
&& rm -rf /tmp/* \
&& apt-get remove --purge -y $BUILDDEPS \
&& apt-get autoremove -y \
&& apt-get autoclean -y \
&& rm -rf /var/lib/apt/lists/*
CMD
["R"]
This diff is collapsed.
Click to expand it.
r-ver/Dockerfile
0 → 120000
+
1
−
132
View file @
3c062d88
3.5.1/Dockerfile
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment