Prosody Docker

用于 Prosody XMPP 服务器的 Docker 映像构建系统。「Docker image building system for the Prosody XMPP server」

Github星跟踪图

Docker build scripts for Prosody build server

This is the Prosody Docker image building repository. It is used by our build server to build and publish Docker images for stable releases and nightly builds.

Note: Using this Dockerfile outside of our build server is not a supported use-case. There are many
alternative Dockerfiles for Prosody available which can be used for this:

Published images

For images please see here: Prosody on Docker.

Running

It works by copying in a recently built deb file and running the install on the system.

Docker images are built off an Debian 10 (buster) base.

docker run -d --name prosody -p 5222:5222 prosody/prosody

A user can be created by using environment variables LOCAL, DOMAIN, and PASSWORD. This performs the following action on startup:

prosodyctl register local domain password

Any error from this script is ignored. Prosody will not check the user exists before running the command (i.e. existing users will be overwritten). It is expected that mod_admin_adhoc will then be in place for managing users (and the server).

Ports

The image exposes the following ports to the docker host:

  • 80: HTTP port
  • 5222: c2s port
  • 5269: s2s port
  • 5347: XMPP component port
  • 5280: BOSH / websocket port
  • 5281: Secure BOSH / websocket port

Note: These default ports can be changed in your configuration file. Therefore if you change these ports will not be exposed.

Volumes

Volumes can be mounted at the following locations for adding in files:

  • /etc/prosody:
    • Prosody configuration file(s)
    • SSL certificates
  • /var/log/prosody:
    • Log files for prosody - if not mounted these will be stored on the system
    • Note: This location can be changed in the configuration, update to match
    • Also note: The log directory on the host (/logs/prosody in the example below) must be writeable by the prosody user
  • /usr/lib/prosody-modules (suggested):

Example

docker run -d \
   -p 5222:5222 \
   -p 5269:5269 \
   -p localhost:5347:5347 \
   -e LOCAL=romeo \
   -e DOMAIN=shakespeare.lit \
   -e PASSWORD=juliet4ever \
   -v /data/prosody/configuration:/etc/prosody \
   -v /logs/prosody:/var/log/prosody \
   -v /data/prosody/modules:/usr/lib/prosody-modules \
   prosody/prosody:0.9

Building

Use the build-docker.sh script as follows:

./build-docker.sh /path/to/built-image.deb version_tag [, ...version_tag2, ...]

Where argument 1 is a pointer to the build deb file that you'd like to make an image from and 'version_tag' is the tag you'd like to push to the Docker registry with.

You can specify multiple tags by adding additional tag names to the end of the command. This is useful where a for example release 0.10.4 is made which also consitutes 'latest', '0.10-nightly', '0.10.4', '0.10' images.

After running the script will clean up any images generated (but not the base images - for efficiency purposes).

主要指标

概览
名称与所有者prosody/prosody-docker
主编程语言Lua
编程语言Shell (语言数: 3)
平台
许可证
所有者活动
创建于2014-11-13 09:29:23
推送于2025-04-21 19:34:18
最后一次提交2025-04-21 19:50:21
发布数12
最新版本名称1.6.0 (发布于 )
第一版名称1.0.0 (发布于 )
用户参与
星数156
关注者数8
派生数48
提交数91
已启用问题?
问题数57
打开的问题数10
拉请求数13
打开的拉请求数1
关闭的拉请求数5
项目设置
已启用Wiki?
已存档?
是复刻?
已锁定?
是镜像?
是私有?