Migrate to hardened docker images

Open
#441 5 comments 1 reaction 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
52/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Quiet
Tech stack
docker, node.js, typescript

Research direction

Start with the private mirrors Dockerfile and inspect how the npm script currently launches the app and where the transpiled JavaScript is produced. Review the simple-git usage and test the image build and runtime behavior with Docker Hardened Images for Node.js. Done means the image uses the hardened base, launches the transpiled JavaScript directly with node, and retains the dependencies needed by simple-git.

Written by the indexing model from the issue text.

Description

enhancement
Is your feature request related to a problem?

The current docker images used by private mirrors contain many dependencies that are unnecessary to the functioning of the app and present a vulnerability risk.

Describe the solution you'd like

Docker published Docker Hardened Images for Node.js that should reduce the number of unnecessary dependencies in the private mirrors images.

Describe alternatives you've considered

Alternatively the current private mirrors Dockerfile could have logic added to remove unnecessary dependencies but this has the risk of not being thorough or unintentionally breaking things.

Additional context

As part of this change the Dockerfile will need to be updated to not use an npm script as the final command in favor of directly executing the transpiled Javascript with node. There may also be complications due to the use of simple-git in private mirrors which will require testing to ensure that the new images still have the necessary dependencies.

Dominant language
TypeScript
Stars
203
Forks
42
Avg merge
1h 15m
Merged PRs (30d)
8

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from github-community-projects/private-mirrors

All issues in github-community-projects/private-mirrors

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.