Docker hosting: how to deploy a Docker container or a Dockerfile
To host a container you need a host that builds or pulls the image, starts its CMD, sends traffic to the port it listens on and stops it with SIGTERM. On Livops a Dockerfile at the root of the repository is built on Livops's servers and runs for 39 credits a month (39,000 so'm); a public image from Docker Hub, GHCR or Quay runs without a build. Here is what a container needs, and how a VPS, Render, Railway, Fly.io, DigitalOcean and Heroku compare.
By Livops team, the people who build and run LivopsUpdated
A Dockerfile is the most portable way there is to describe a server: anywhere that runs containers will run it. What changes between hosts is who builds the image, what the container is allowed to do, where its traffic and its files go, and how it is stopped. This page lists what a container needs to behave well in production, compares where to run one with each provider’s own prices, and ends with exactly how Livops builds and runs a Dockerfile.
What does a container need in production?
To listen on the port it is given, on every interface
The host decides the port and passes it in, usually in PORT. Bind 0.0.0.0, not localhost: a server bound to the loopback answers only inside its own container. EXPOSE does not publish anything; it is documentation, between whoever builds the image and whoever runs it, of the port the app is meant to use[1].
A CMD in exec form, so SIGTERM arrives
The shell form of ENTRYPOINT runs your program under /bin/sh -c, which does not pass signals on: the program is not PID 1 and never receives the SIGTERM from docker stop[1]. Write CMD ["node", "server.js"], not CMD node server.js, and have the program finish its requests when SIGTERM arrives.
A small image from a multi-stage build
A multi-stage build compiles in one image and copies only the result into the last one; none of the build tools reach the image that runs[2]. Smaller images build, push and start faster, and carry fewer packages to patch.
FROM golang:1.27 AS build
WORKDIR /src
COPY . .
RUN CGO_ENABLED=0 go build -o /out/app .
FROM gcr.io/distroless/static
COPY --from=build /out/app /app
USER 1000
CMD ["/app"]
No secrets in the image
Build arguments are visible in docker history, so the Dockerfile reference warns against passing credentials or tokens with --build-arg[1]. Secrets belong in the environment the container is started with.
A non-root user
Run the app as an ordinary user. A host that drops privileges will do it anyway, and then files your Dockerfile created as root, and ports below 1024, are out of reach.
A health check
HEALTHCHECK tells Docker how to test that the container still works, which catches a server stuck in a loop while its process is still running[1]. Platforms usually check over HTTP instead; a cheap /healthz route serves both.
Somewhere to keep data
A container’s own file system goes with the container. Data that must survive a deploy needs a volume or, better, a database.
The options at a glance
| Option | What it is | Smallest paid always-on container | What you still maintain |
|---|---|---|---|
| Livops | A platform; builds your Dockerfile; servers in Uzbekistan | 39 credits (39,000 so’m) a month | Your Dockerfile |
| A VPS in Uzbekistan | A virtual machine with root | 82,000 so’m a month: 1 vCPU, 2 GB, 30 GB HDD (SmartCloud)[3] | Docker, the system, a proxy, HTTPS, deploys |
| Render | A platform; custom Docker containers | $7 a month: 0.5 CPU, 512 MB[4] | Your Dockerfile |
| Railway | A platform billed by usage | Hobby: $5 a month, including $5 of usage[6] | Your Dockerfile |
| Fly.io | Virtual machines billed by the second | $2.19 a month: shared-cpu-1x, 256 MB[7] | Your Dockerfile |
| DigitalOcean App Platform | A platform with container instances | $5 a month: 1 shared vCPU, 512 MiB[8] | Your Dockerfile |
| Heroku | Dynos; deploys from Git or Docker | Basic: $7 a month, 0.5 GB[9] | Your Dockerfile |
Other providers’ prices are from each provider’s own page, read on 20 November 2026; the dates are in Sources below. Livops prices are the ones the cabinet bills today.
Each option
Livops
Push a repository with a Dockerfile and Livops builds it on its own servers, on every push, with a layer cache kept per project. Or run a public image without a build. Payment is in so’m through Payme or Click, Uzbekistan’s payment services; the servers are in Uzbekistan, close to users there and farther from users elsewhere. The container runs unprivileged with no Linux capabilities, one app’s memory stops at 2 GB, and a build may run for ten minutes: an image that needs root, privileged mode or more memory belongs on a VPS.
A VPS
With root and Docker, any image runs exactly as on your laptop, and several fit on SmartCloud’s cheapest 2 GB machine, 82,000 so’m a month[3]. In exchange you run Docker itself, a reverse proxy, certificates, a way to deploy a new image, restarts after a reboot, and the system’s updates.
Render
Render runs custom Docker containers beside its native runtimes[4]. The smallest paid instance is $7 a month for 0.5 CPU and 512 MB[4], and web services have a free instance type[5].
Railway
Hobby is $5 a month with $5 of usage included and always-on services; memory is about $10 per GB a month and CPU about $20 per vCPU a month, billed by the second[6]. A service can grow to 48 vCPU and 48 GB on Hobby[6], far past what Livops offers. Plans are paid by card[6].
Fly.io
Fly runs containers as virtual machines; the smallest, shared-cpu-1x with 256 MB, is $2.19 a month, billed by the second while it runs[7]. A stopped machine still pays $0.15 per GB a month for its root file system[7].
DigitalOcean App Platform
$5 a month buys a fixed shared instance with 1 vCPU, 512 MiB and 50 GiB of outbound transfer, limited to one container instance[8]. Deploying from a container registry is part of the paid tier[8].
Heroku
Heroku deploys with Git or Docker from its Eco tier up[9]. Basic, $7 a month with 0.5 GB, is the cheapest dyno that stays on; Eco, $5, sleeps after 30 minutes of inactivity[9].
Your own Docker or a platform?
docker compose up on a VPS is the shortest path from a laptop to a server, and nothing about the image has to change. What it does not do is everything after: rebuild on push, keep the old container serving until the new one answers, restart after a crash or a reboot, renew certificates, keep the disk from filling with old images. A platform does those and asks you to live within its rules — an unprivileged user, its port, its limits. If you need the whole machine, take a VPS. If you need the container to stay up, use a platform.
Where can you run a container for free?
- Livops has no free tier for apps. On an account that has not paid yet, the first bot or app runs for 15 minutes on a zero balance, once. Static sites are free.
- Render gives each workspace 750 free instance hours a month; a free web service spins down after 15 minutes without inbound traffic and takes about a minute to start again[5].
- Railway has a Free plan with $1 of usage a month, up to 1 vCPU and 0.5 GB per service, that sleeps after 5 to 10 minutes without outbound traffic; a trial gives $5 for 30 days with no card[6].
- Fly.io has no free tier for new organisations: a $1 trial for 7 days, and a personal bill under $5 a month is waived[7].
- DigitalOcean App Platform is free for up to 3 static sites only[8].
- Heroku lists no free dyno[9].
Docker hosting on Livops
From a Dockerfile
- Put the
Dockerfileat the root of the repository, or of the folder you set as the project’s root in a monorepo. In the cabinet, create a project from the GitHub repository or an uploaded folder. - Put settings and secrets under Variables, and add a database under Databases if you need one; its address arrives as
DATABASE_URL. - Deploy. The log shows the image being built, step by step.
When the Dockerfile is used:
- A project whose language Livops would otherwise build itself — Go, Rust, Java, PHP — is built from its
Dockerfilewhen it has one, and so is anything detection does not recognise. - A framework detection is sure of, such as Next.js, keeps its own build, and so does a Node or Python app whose start it found. A folder of HTML stays a free static site. A
Dockerfilethat only copies a build from your machine (COPY target/*.jar) is skipped, because that folder is not in the repository. "builder": "dockerfile"inlivops.jsonbuilds from the Dockerfile anyway;"preset"never does. It is read when the project is created.
How it is built and run:
- The build runs on Livops’s servers in its own rootless BuildKit, with a layer cache per project and the same ten-minute limit as any build. Your variables are not passed in, and there are no build arguments: they reach the container when it starts.
- What starts is the image’s own
CMD. A Dockerfile with anEXPOSEline makes the project a web app; without one you choose web, worker or bot. - The user is uid 1000 with every Linux capability dropped, so ports below 1024 and files only root can read are out of reach.
- The port is in
PORT, 3000 unless you change it. The container has a minute to answer HTTP there — onhealthPathwith 2xx or 3xx, iflivops.jsonnames one. If it ignoresPORTand listens on exactly one other port, 1024 or higher, it is started once more on that port, which is kept, and the log says so; with several ports it is not guessed. - Files: the project’s disk is at
/data(DATA_DIR=/data) and survives deploys. Folders the Dockerfile makes withmkdirget a place on that disk too. The rest of the container’s file system is gone after a restart. - A new version takes traffic only once it answers. The old one keeps running 15 seconds for requests in flight, then gets SIGTERM and 30 seconds. If it crashes later it is started again; ten crashes inside 15 minutes and it is stopped, and you are told why.
{
"builder": "dockerfile",
"kind": "web",
"healthPath": "/healthz",
"memory": 512
}
From a ready image
In the New project dialog, choose a Docker image as the source and give its name, for example ghcr.io/owner/app:1.4.2, and the port it listens on.
- Public images only, from
docker.io,ghcr.ioorquay.io; a name with no registry is Docker Hub. - The port must be 1024 or higher. The container runs as user 1000 without Linux capabilities, so an image built to run as root will not start.
- The image may be at most 2 GiB and must pull within 5 minutes.
A web app is 39 credits a month (39,000 so’m), whichever way it is built; memory is 256, 512, 1024 or 2048 MB and the size is part of what you pay for. One credit is 1,000 so’m; see Pricing and Ways to deploy.
Questions
Does Livops build my Dockerfile, or do I push an image?
Either. A Dockerfile at the root of the project (or of the folder you choose) is built on Livops's servers on every push. A ready public image from docker.io, ghcr.io or quay.io runs without a build: you give its name and the port it listens on.
When does Livops use my Dockerfile instead of detecting the framework?
When the Dockerfile is the only way it knows to build the project: Go, Rust, Java and other projects with a Dockerfile are built from it, and so is anything detection does not recognise. A Next.js app, or a Node or Python app it can start itself, keeps its own build. "builder": "dockerfile" or "preset" in livops.json decides it outright, read when the project is created.
Can I use build arguments or my variables during the build?
No. The project's variables are not passed into a Dockerfile build, so nothing secret ends up in the image's history. They are given to the container when it starts.
Which port should the container listen on?
The one in the PORT variable, 3000 unless you change it, on 0.0.0.0. The container runs unprivileged, so a port below 1024 cannot be bound. If it ignores PORT and listens on exactly one other port, 1024 or higher, Livops starts it again on that port once and keeps it.
Where can a container write files that last?
In /data, which is also the DATA_DIR variable: it survives restarts and deploys. Folders the Dockerfile makes with mkdir are kept on the project's disk too. Anything else written inside the container is gone after a restart.
Why does my image start on my laptop and not on the server?
Often it was built for another CPU, which ends in exec format error; Livops builds your Dockerfile itself, so the image matches. The other usual causes are listening on localhost, a port below 1024, or a file owned by root that a non-root user cannot read.
How much does a container cost on Livops?
39 credits a month for a web app, 39,000 so'm at 1,000 so'm a credit. There is no free tier for apps; the first app on an account that has not paid runs for 15 minutes on a zero balance, once.
Sources
- Docker — Dockerfile reference (docs.docker.com). Checked .
- Docker — Multi-stage builds (docs.docker.com). Checked .
- SmartCloud — VDS plans (smartcloud.uz). Checked .
- Render — Pricing (render.com). Checked .
- Render — Deploy for free (render.com). Checked .
- Railway — Pricing (railway.com). Checked .
- Fly.io — Pricing (docs.fly.io). Checked .
- DigitalOcean — App Platform pricing (digitalocean.com). Checked .
- Heroku — Pricing (heroku.com). Checked .
Put your project online today
Connect GitHub or drop a folder. No card is asked for.
Deploy your DockerfileRelated
- exec format error in Docker: the image was built for another CPUThe kernel refused to run the container's program because it is not an executable for this machine: almost always a binary or image built for arm64 (an Apple Silicon Mac) running on an amd64 server, or the reverse. Build for the server's platform with --platform linux/amd64, or as a multi-platform image; if the file is a script, give it a #! line.
- App not listening on $PORT: why the health check failed after deployThe platform started your app, tried the port it gave it, and nothing answered in time. Almost always the app listens on its own fixed port instead of the PORT variable, listens on localhost (127.0.0.1) instead of 0.0.0.0, or crashed or was still starting when the check gave up. Listen on 0.0.0.0 and the port in PORT, and it passes.
- Error: listen EADDRINUSE: address already in use — how to fix itYour server tried to listen on a port that another process on the same machine already holds. On your computer, stop the old process, usually a dev server still running in another terminal. In a deploy, it almost always means the app starts its server twice, or two processes in one container ask for the same port.
- Node.js hosting in 2026: how to deploy an Express appA Node.js server in production needs one long-running process that listens on the port it is given, restarts when it crashes and exits cleanly on SIGTERM. On Livops you push a repository with package.json and it runs as a web app for 39 credits a month (39,000 so'm). Here is what Node needs, and how a VPS, Render, Railway, Fly.io, DigitalOcean and Heroku compare.
- Go hosting in 2026: how to deploy a Go appA Go web app compiles to one binary, so hosting it means building that binary, running it on the port it is given and shutting it down with http.Server.Shutdown. On Livops you push a repository with go.mod: it is built with CGO off into a static binary and runs as a web app for 39 credits a month (39,000 so'm). Here is what Go needs, and how a VPS, Render, Railway, Fly.io and DigitalOcean compare.
- Rust web app hosting: how to deploy an axum or Actix Web appA Rust web app is one release binary that binds 0.0.0.0 on the port it is given and shuts down on SIGTERM. The hard part is the build: a first release build takes minutes, so the host must keep its cache. On Livops you push a repository with Cargo.toml, it is built with cargo build --release and runs as a web app for 39 credits a month (39,000 so'm).