emilyalbini · GitHub

added 12 commits

October 29, 2019 17:26
If someone also builds docs.rs outside of Docker they need to have a
place to store the prefix and the rustwide workspace. This commit adds
a directory named ignored to both the gitignore and the dockerignore.
The user is not actually used to run the application (is run as root),
but only during parts of the build process. It's not really needed, so
this removes it.
- The CRATESFYI_CONTAINER_NAME variable was removed as it's not needed
  anymore.
- The CRATESFYI_DATABASE_URL variable was moved to docker-compose.yml as
  it's only correct when starting the website with it.
- The CRATESFYI_GITHUB_USERNAME and CRATESFYI_GITHUB_ACCESSTOKEN
  variables were moved to a new, gitignored .env file in the root of the
  repository, to allow people changing them without accidentally
  committing them.
- The DOCS_RS_DOCKER variable was moved to the entrypoint just to remove
  yet another useless layer from the image.
This prevents a stale index from being backed into the image.
Using multi-stage builds got us from 2.8GB to 500MB, which is a great
space saving.

@emilyalbini

@emilyalbini

jyn514

@emilyalbini

jyn514

Co-Authored-By: Joshua Nelson <jyn514@gmail.com>

@emilyalbini

@emilyalbini

jyn514 added a commit that referenced this pull request

Nov 5, 2019
@miller-time ran into this when trying out docker.
When the Dockerfile got split up in #455
`gcc` never got installed in the second container, so there's no linker.

jyn514 added a commit to jyn514/docs.rs that referenced this pull request

Nov 6, 2019
miller-time ran into this when trying out docker.
When the Dockerfile got split up in rust-lang#455
`gcc` never got installed in the second container, so there's no linker.

Read the original on github.com ↗