Wykres commitów

106 Commity (4f428c305576ccf1f1ff1fb18b11bbf1402ca7bd)

Autor SHA1 Wiadomość Data
Min RK 4f428c3055
Merge pull request #681 from Xarthisius/abspath_in_scripts
[MRG] Allow absolute paths in build_script_files. Fixes #673
2019-09-07 12:33:14 +02:00
Min RK 31da8e32b1 run chown as root 2019-07-18 17:55:38 +02:00
Min RK 654be046ac set permissions on repo_dir prior to preassemble 2019-07-18 14:40:08 +02:00
Min RK 5b12e072b1 move stencila to preassemble 2019-07-16 08:35:35 +02:00
Tim Head 09b84811ae Make sure all loops over dict items are deterministic 2019-07-12 07:23:41 +02:00
Tim Head 66227f85b4 Detect failure of pre-assembly in R buildpack
If the pre-assembly step succeeds we do not re-run it after copying the
repository contents.
2019-07-06 16:21:29 +02:00
Kacper Kowalik (Xarthisius) 24234d9365
Allow absolute paths in build_script_files. Fixes #673 2019-06-28 08:44:11 -05:00
Tim Head 10ca25d986 Install APT packages before copying the repo contents 2019-06-25 12:57:54 +02:00
Tim Head 8b004e06dc Apply auto formatting
Apologies to anyone finding this commit via git blame or log

run the autoformatting by

    pre-commit run --all-files
2019-06-03 21:37:25 +02:00
yuvipanda 74fc378230 Clarify comment around memswap & memory 2019-05-08 09:44:58 -07:00
Tim Head 2eb4781c2e Swap limit doesn't have to be bigger than memory limit 2019-05-08 18:22:11 +02:00
Tim Head 032baf6d04 Add check to `build()` for memory limit type 2019-05-08 14:23:43 +02:00
Tim Head ef2860371a Fix memory limits set for container image builds 2019-05-08 08:11:38 +02:00
yuvipanda 4dd32f3563 Make sure ENTRYPOINT is an absolute path
Unlike other parts of the generated Dockerfile,
the start script is evaluated at run time, rather
than at build time. Currently, we assume that the
current working directory is the same at runtime
as build time for the start script. This doesn't
hold true always, and particularly not in JupyterHub
environments where ${HOME} is often overlaid with
a persistent directory.

We change this to always refer to the full path,
using the ${REPO_DIR} environment variable. This
lets people building JupyterHub images to set
REPO_DIR to something like /srv/repo (like hubploy
does), and still have a working start script.
2019-04-30 10:04:53 -07:00
Tim Head 5e67e3c743
Support .binder directory (#653)
Support .binder directory
2019-04-30 18:29:38 +02:00
Tim Head e15007d528 Make sure start script is executable 2019-04-30 08:43:19 +02:00
Joseph Hamman 7ac4cb4932 error if both binder and .binder dirs exist 2019-04-29 08:05:49 -07:00
Joseph Hamman e83b12f5b2 add missing break 2019-04-29 06:47:51 -07:00
Joseph Hamman c230c70f4e support for .binder directory 2019-04-27 17:01:20 -07:00
Min RK 15a23711e6 invoke start script from our entrypoint
rather than replacing our entrypoint
2019-04-25 15:56:26 +02:00
Min RK 9678dde251 install notebook in its own env
leave the conda root env alone

adds conda activation to profile.d and ensures that we
start with a login shell via the ENTRYPOINT
2019-04-25 15:44:51 +02:00
Gladys Nalvarte 5bf2eadcf8 Exposes CPU limit 2019-02-15 14:57:58 +01:00
Gladys Nalvarte 8c6329de61 npm installation 2019-02-07 15:36:00 +01:00
benjamin 234e0b62d3 Moved postBuild comment into the condition. 2019-01-05 19:42:15 +00:00
yuvipanda 29407aa83f Put ${REPO_PATH}/.local/bin in PATH too 2018-12-18 11:50:35 -08:00
yuvipanda 21154d3b86 Use REPO_DIR rather than REPO_PATH
https://github.com/jupyter/repo2docker/pull/507#issuecomment-448184651
is a good justification
2018-12-18 11:50:35 -08:00
yuvipanda 0f3076387a Set REPO_PATH as late as possible
Leads to maximum cache re-use
2018-12-18 11:50:24 -08:00
yuvipanda 3dfe0a8143 Copy repo to ${REPO_DIR} rather than ${HOME}
We want to put the repo somewhere other than ${HOME}
so we can mount persistent storage in ${HOME} more easily.
Most of repo2docker assumes current directory is where
the contents are, so we should be able to get most of it
working by setting WORKDIR to ${REPO_PATH} and letting
${REPO_PATH} be configurable.

Unclear what to do for plain Dockerfiles, Legacy Dockerfiles &
nix.
2018-12-18 11:50:24 -08:00
yuvipanda 7eb1ac46af Redirect apt-get install output to /dev/null
`apt-get install` calls `dpkg` underneath to do the
installation. Unfortunately, `-qq` does not get passed
through, and we end up with a lot of log output even with
`-qq`. Redirecting stdout to /dev/null stops this output.
Errors come out to stderr, so those will be displayed.
2018-12-17 16:31:14 -08:00
yuvipanda 6ec05e3693 Pass quiet flag to apt properly
-qq is a parameter to 'apt-get' rather than the subcommand
2018-12-17 16:28:48 -08:00
yuvipanda b555adda43 Fix cache-busting when running tests locally
When you run repo2docker locally, the uid is usually set
to the current user's uid. However, when we push the content
to Docker, we invariably set the uid of the scripts we
use as part of repo2docker at 1000. This causes a cache bust
every time.

This patch uses the correct uid, and fixes cache busting. Makes
local test runs *much* faster.

Fixes #508
2018-12-16 11:15:36 -08:00
James Bourbeau 624ad94073 Remove getattr usage 2018-12-13 11:09:50 -06:00
James Bourbeau 2e31e6e80e Add Dockerfile repo2docker labels 2018-12-12 22:05:06 -06:00
yuvipanda 3b0b77259f Inject docker.APIClient into methods that need them
- Creating a new client with 'auto' version causes repeated
  unnecessary network requests to discover version of docker daemon.
- Testing is easier this way, since we can inject a mocked docker
  client more easily
2018-12-10 11:18:01 -08:00
yuvipanda 1dacdd4c46 Allow specifying images to reuse cache from
This lets us explicitly specify images that repo2docker
should try to re-use cached layers from. Docker normally only
looks for layers from images that were *built* locally - if
we want it to look in images that were *pulled* from a registry,
we need to specify it here.
2018-12-05 11:10:50 -08:00
yuvipanda 82e0dc0149 Make apt be quieter
Currently a *lot* of our log info is from apt packages being
installed, and package lists being updated. This is mostly not
very useful information to users. The following outputs are
hidden:

- apt-get update, purge & clean
- apt-get installs for base packages

When there is any error from any of the apt-get steps, they will
be printed. Any packages the user explicitly lists (via apt.txt)
will have their install status messages output.
2018-11-28 23:11:36 -08:00
nuest 68194a08a2 reformat some long lines 2018-11-09 07:46:31 +01:00
nuest 58a5c8b4c2 make loops more readable 2018-11-09 07:40:31 +01:00
Tim Head c49694a5ea
Update repo2docker/buildpacks/base.py
Co-Authored-By: nuest <daniel.nuest@wwu.de>
2018-11-07 18:51:57 +01:00
Tim Head d849664826
Update repo2docker/buildpacks/base.py
Co-Authored-By: nuest <daniel.nuest@wwu.de>
2018-11-07 18:51:51 +01:00
nuest df7c6205c0 do not install Stencila Python context if only python-jupyter cells found 2018-11-05 19:00:39 +01:00
nuest b032a7cd27 safe one if clause (intersection is already false-y) 2018-11-05 18:51:10 +01:00
nuest b1bff5bf5e parse Stencila xml files instead of regex 2018-10-30 17:01:05 +01:00
nuest 9c81c3ed19 rename stencila_manifest_contexts to stencila_contexts
also remove dev comment
2018-10-30 16:25:40 +01:00
nuest d6dc570a14 continue Stencila detection if /binder dir is present, improve 2018-10-30 16:02:40 +01:00
nuest 3f4da20f7e reduce calls to stencila_manifest_contexts 2018-10-30 11:58:46 +01:00
nuest da41a90e04 update versions of stencila/r and stencila/py 2018-10-30 10:33:18 +01:00
nuest 3a479b6dee install R for Stencila from R buildpack 2018-10-30 10:32:42 +01:00
nuest 8342fbd1c0 do not look for stencila if binder dir found 2018-10-30 09:02:47 +01:00
nuest 9624f0f161 extract contexts from stencila document 2018-10-29 22:51:28 +01:00