Deploy a Docker App from a Dockerfile in India | Replov
Skip to main content

Docker

Deploy any app with a Dockerfile on Replov

When the service’s root directory contains a Dockerfile, Replov builds that image instead of detecting a framework. This works for Web Services, Private Services, Background Workers and Cron Jobs, and is the most predictable way to run Go, Rust, Java, Python or anything else with exact system dependencies.

Last verified against the product on .

Before you start

  • A Dockerfile that builds with docker build from your repository root.
  • A process that listens on the PORT environment variable (web and private services).

How Replov builds it

  • The build context is always the repository root, and the Dockerfile is taken from the service’s Root Directory. In a monorepo, write COPY paths relative to the repository root.
  • Your environment variables are passed as build arguments, but Docker only uses the ones your Dockerfile declares with ARG.
  • Your Dockerfile’s CMD or ENTRYPOINT starts the container. Leave Replov’s Start Command empty.
  • Static Sites do not use a custom Dockerfile; they always use Replov’s Nginx build.

Deploy it

  1. 1

    Sign in to Replov and connect GitHub (Connect GitHub / Import from GitHub). Replov asks for access to the repositories you choose.

  2. 2

    Create a project for the repository, then add a service to it.

  3. 3

    Choose the service type, select the repository and Branch, and set Root Directory to the folder that contains the Dockerfile (empty for the repository root).

  4. 4

    Leave Build Command and Start Command empty.

  5. 5

    Add Environment Variables and secrets, pick a compute tier, and deploy.

Example: Dockerfile (Go example)

FROM golang:1.23-alpine AS build
WORKDIR /src
COPY . .
RUN go build -o /app ./cmd/server

FROM alpine:3.20
COPY --from=build /app /app
ENV PORT=3000
CMD ["/app"]

Environment variables and ports

  • Listen on PORT (Replov sets it to 3000 for web and private services) and bind to 0.0.0.0. EXPOSE in the Dockerfile does not change the port Replov routes to.
  • Values your build needs must be declared with ARG; runtime values arrive as normal environment variables.

Domains and HTTPS

Every web service and static site gets an HTTPS address of the form <service-name>-<4 characters>.replov.com once it is live.

To use your own domain, open the service, choose Connect Domain and publish the CNAME and TXT records Replov shows at your DNS provider. After verification Replov routes the hostname and issues a Let’s Encrypt certificate automatically. More on HTTPS.

Logs and monitoring

The build log streams while the deployment runs; the first failing command and the lines just above it usually explain a failed build. Runtime logs (with live streaming) and CPU, memory and network metrics are on the service page. See service logs.

Troubleshooting

COPY fails with “file not found” in a monorepo
The build context is the repository root. Use paths like COPY apps/api/ ./ rather than paths relative to the Dockerfile.
A build argument is empty
Declare it with ARG in the Dockerfile; undeclared build arguments are ignored by Docker.
The service never becomes healthy
The process is listening on a different port. Read PORT or listen on 3000.

Deploy your repository on Replov

Connect GitHub, choose a service type and a compute tier, and watch the build log.