jupyterhub/repo2docker

Expanded documentation for command line arguments

Open

#564 opened on Jan 26, 2019

View on GitHub
 (3 comments) (0 reactions) (0 assignees)Python (1,544 stars) (358 forks)batch import
documentationenhancementhelp wanted

Description

This week, I built a repo for CI/CD for building a stack of Docker images using repo2docker (see pangeo-stacks). Along the way, I encountered a few areas in the documentation that could use some tuning. I'm happy to help contribute some additional docs, but first thought it would be good to first enumerate the spots that I found lacking detail.

1. config file

--config <config>
Path to config file for repo2docker

Questions: What is the repo2docker config file? How should this be formatted? When would I use it?

https://github.com/jupyter/repo2docker/blob/18e9d2f8178fc72a69f1acb54a2be783d71355fb/repo2docker/__main__.py#L223

2. appendix and subdir

--appendix <appendix>
--subdir <subdir>

These two options lack doc strings in the command line app. The appendix in particular must be a string (not a path to a file as I first assumed). I still don't know what the subdir is.

3. push

--push
Push docker image to repository

This would benefit from a more complete description. Specifically, an example using --push and --image-name would be super useful when sorting out where to put the Dockerhub ID, image name, and tag.

4. cache

--cache-from <cache_from>

No description here. How would I use this?


Proposal

  • Each command line option should have an example value demonstrating its use. For the --image-name option, you may have something like Name of image to be built. If unspecified will be autogenerate. (form: TARGET_IMAGE[:TAG], e.g. jupyter/myimage:latest).
  • Add a section to the docs with a bunch of usage examples. Currently there are three or four examples in https://repo2docker.readthedocs.io/en/latest/usage.html but they don't cover many of the tougher to understand options.

Contributor guide