Skip to content

Separate development Docker from production Docker #59

Description

@nexspro

Context

The current Docker setup appears useful for development, but it may not be ideal as a production runtime image.

The current Dockerfile keeps development/build-related tools such as build tools and Git in the image.

Problem

A development Docker image and a production Docker image do not always have the same goals.

Development images can include tools that make local work easier, while production images should usually be smaller, safer, and more focused on runtime needs.

For Nexspro V1, the Docker strategy for internet deployment should be clear.

Goal

Decide whether Nexspro V1 should keep the current development-oriented Docker image for deployment or introduce a separate production Docker image.

Acceptance criteria

  • Current Dockerfile is reviewed
  • Development Docker usage is documented
  • Production Docker requirements are reviewed
  • Decision is made: keep current image for V1 or add separate production image
  • If a production image is added, unnecessary build tools are removed from the runtime image
  • If the current image is kept, the reason is documented
  • Local development still works
  • Production boot is tested if production Docker is changed
  • CI passes

Technical notes

Known file:

Dockerfile

Current finding:

  • the image is useful for development
  • build tools and Git may remain in the runtime image

Things to review:

  • local development needs
  • production runtime needs
  • image size
  • security surface
  • deployment target
  • Kamal or hosting compatibility
  • whether multi-stage build is needed

For V1, it is acceptable to document that the current Dockerfile is development-focused if production deployment is not using it yet.

Out of scope

This issue should not redesign the full deployment strategy.

This issue should not change unrelated CI behavior.

This issue should not optimize Docker prematurely unless production deployment actually needs it.

The goal is only to clarify and, if needed, separate development Docker from production Docker for Nexspro V1.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions