Sign inSign up

sanicframework/sanic

By sanicframework

•Updated 4 months ago

Official Docker images for Sanic

Image
10

10K+

sanicframework/sanic repository overview

⁠Sanic Docker image

This image is meant to be a starting point for you to build your own Sanic⁠ application running on Docker. It makes no decisions for you and is completely unopinionated (just like the Sanic framework itself).

⁠What versions are available?

We currently build images for Python 3.10 and 3.11, but if you need any other just let us know.

For each of those Python versions, you can choose one of the following Sanic versions:

  • LTS: The latest LTS version released
  • Latest: The latest Sanic version released (regardless of whether it's LTS or not)
  • Specific version: The latest version of the version requested (the image will always contain the latest patch version)

The container runs Alpine Linux.

⁠How do I use this?

Setup your own Dockerfile

FROM sanicframework/sanic:lts-py3.10

RUN mkdir /srv
COPY . /srv

EXPOSE 8888

ENTRYPOINT ["python3" "/srv/my-sanic-server.py"]

Build it

docker build -t my-sanic-server .

Run it as you would any other container

docker run my-sanic-server

Tag summary

Content type

Image

Digest

sha256:5b1dc1d04…

Size

140.8 MB

Last updated

4 months ago

docker pull sanicframework/sanic:latest-py3.11