Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
99 commits
Select commit Hold shift + click to select a range
bd19f3e
Update Alpine to 3.14 (thanks to John Haugeland)(#76)
badlop Dec 28, 2021
258c0fb
Upload docker image as a github artifact
badlop Dec 28, 2021
861cb9b
Fix testing when current month has no tagged version: test latest
badlop Jan 5, 2022
d414512
Test changes in mix independently
badlop Jan 13, 2022
856296e
mix: Fix build with Alpine 3.12 and higher (thanks to Paul Menzel)(#77)
badlop Jan 13, 2022
2ae9f00
Use Elixir's release instead of Distillery's release
badlop Mar 8, 2022
2cdfd7d
Join mix building into main tests, it just adds a few seconds
badlop Mar 14, 2022
ba822a8
Prepare a short and general description to show in Docker Hub
badlop May 1, 2022
ca93e83
Add local links in main repo README
badlop May 17, 2022
2998bc6
Add link to the alternate container image in ecs README
badlop May 17, 2022
90671eb
Runs tini in the container to cope with zombies
jsautret Jun 22, 2022
ba4aab7
Add Composer Examples section
badlop Nov 7, 2022
b5aa67b
Update link to the local example of CTL_ON_CREATE usage
badlop Nov 7, 2022
01e416f
Add code-server and devcontainer images, useful for VSCode
badlop Dec 5, 2022
329fac0
Only test mix and ecs builds when those paths are modified
badlop Dec 5, 2022
ddf9503
Remove .travis.yml as there are GitHub Actions already used for that
badlop Dec 12, 2022
5cb2190
Update actions versions as requested by GitHub Actions
badlop Dec 20, 2022
28c5bc0
Update to ubuntu-latest, which right now is 22.04
badlop Dec 20, 2022
4222010
Update Alpine to the latest image cached in GitHub Actions, 3.16 (#91)
badlop Dec 20, 2022
8f2043e
Use Config instead of the deprecated Mix.Config
badlop Dec 20, 2022
54c7c3d
Don't require a very specific action version
badlop Dec 20, 2022
2c42a59
ecs/Dockerfile: add tini as runtime init
Jan 30, 2023
f0141b2
Merge pull request #93 from sando38/master
badlop Mar 7, 2023
78d03df
Workaround for devcontainer alpine script that was removed recently
badlop Feb 28, 2023
f81905d
Set ERLANG_NODE fixed to ejabberd@localhost
badlop Aug 16, 2021
cc800c3
Document how to setup clustering
badlop Mar 7, 2023
96092f6
Document how to change the mnesia node name
badlop Mar 7, 2023
bf261bc
Merge pull request #73 from badlop/erlang-node-localhost
badlop Mar 7, 2023
7206cb9
Update workflow for ecs and mix images
badlop Mar 28, 2023
db77841
Add links to ghcr.io
badlop Apr 3, 2023
dd773c1
Reword some sentences: containers are no longer only a Docker exclusi…
badlop Apr 3, 2023
b331b49
Upgrade OS packages for eCS
jsautret Apr 12, 2023
225ce0a
No need to setup captcha_url, by default auto may be good enough
badlop Apr 17, 2023
0fb6e25
Ensure we get a single tag when dealing with local docker image
badlop May 9, 2023
f5db404
Update Alpine to 3.17
badlop May 9, 2023
40aad28
Always check ecs results and show ejabberd logs
badlop May 15, 2023
0c73c30
Use local registry for mix->ecs images, only push to ghcr when it's a…
badlop May 16, 2023
3d5efe9
Dockerfile: compile ejabberdapi during build
Jun 13, 2023
47498d8
actions: fix test
Jun 13, 2023
9361646
Merge pull request #98 from sando38/master
badlop Jun 20, 2023
72d317a
Halt ejabberd if a command in CTL_ON_ fails during ejabberd startup (…
badlop Jun 20, 2023
ee1d178
Push mix and ecs images to GHCR when tagging
badlop Dec 12, 2023
c0acc7a
Recognize "!" flag in CTL_ON_{CREATE|START} to ignore failing commands
prefiks Feb 13, 2024
f81004e
Document new "!" flag to prepend commands in CTL_ON (#110)
badlop Feb 13, 2024
6cafab7
ejabberdctl: Document to stop live shell with control+g
badlop Feb 28, 2024
6ff46ae
ejabberdctl: Reorganize and complete documentation of node start/debu…
badlop Feb 28, 2024
abea089
Tests: Update action to publish image automatically to Docker Hub
badlop Feb 28, 2024
7c29c7b
Tests: Remove unnecesary tags
badlop Feb 28, 2024
8c79330
Tests: Update steps names to match their current purpose
badlop Feb 28, 2024
8868e9e
Tests: Use explicit ubuntu-22.04 instead of a varying ubuntu-latest
badlop Feb 28, 2024
0a14715
Tests: Update actions to use Node.js 20 as recommended by Github Actions
badlop Feb 28, 2024
fba8bf6
mix and ecs images: Update Alpine to 3.19
badlop Feb 28, 2024
228ab57
Fix missing ejabberd version number in ecs 24.02 image (111)
badlop Mar 4, 2024
b9528e7
Update actions versions to use Node.js 20
badlop Mar 4, 2024
33b4b1b
code-server: Fix problem getting erlang-wx
badlop Mar 4, 2024
5801faa
Fix wrong container name in Docker Hub when puhsing the images
badlop Mar 4, 2024
e1517aa
fix: invalid CTL_ON_CREATE usage in docker-compose example
LeszekBlazewski Apr 19, 2024
ce8ea0a
Merge pull request #112 from LeszekBlazewski/fix-command-on-start-docs
badlop Apr 19, 2024
63069d4
Use latest ejabberd-api version, which fixes go version numbering
badlop Jun 13, 2024
e7ff12e
Update golang image to latest stable version, from 1.20 to 1.22
badlop Jul 17, 2024
5cb5592
Apply changes from upstream ejabberd 24.07
badlop Jul 18, 2024
902bf3c
Use same general badges in both container images readme files
badlop Aug 20, 2024
a0884bd
Fix headers markdown to allow mkdocs display the TOC correctly in doc…
badlop Aug 20, 2024
c8d51e4
Revert partially recent commit: don't apply uid changes from 24.07
badlop Aug 20, 2024
7213a3c
Add ejabberd/bin to PATH to allow easier calling ejabberdctl
badlop Aug 20, 2024
612e0c1
Link paths to mimic the ejabberd installer path structure
badlop Aug 20, 2024
c49b1ce
Document recent change: the ejabberdctl script is now in the PATH
badlop Aug 20, 2024
9087a21
Enable mod_s2s_bidi as upstream ejabberd config file
badlop Oct 29, 2024
6041bb9
Tests: Use ubuntu-24.04 (processone/ejabberd#4281)
badlop Nov 18, 2024
fe39e3b
Fix executable permissions removed inadvertedly in 5cb5592
badlop Nov 22, 2024
a7f67df
code-server: Bump debian version to get Erlang/OTP 27
badlop Jan 20, 2025
fd61bbd
code-server: Simplify preparation of home dir
badlop Jan 20, 2025
bcbc96e
code-server: Expose typical port numbers, use the lowest 1870 for cod…
badlop Jan 20, 2025
dc13b8a
Copy configuration from ejabberd upstream (#120)
badlop Jan 23, 2025
7e93f07
Allow commit/branch to be build
Jan 28, 2025
0a9aca6
Merge pull request #121 from fabiang/version-commit
prefiks Feb 13, 2025
b75a086
Support building container image with podman
badlop Dec 30, 2024
403f228
Copy captcha scripts to immutable path for easy calling
badlop Dec 30, 2024
5f46c05
Define and use macros in the configuration file
badlop Jan 24, 2025
890d04c
Listen for webadmin in a port number lower than any other
badlop Dec 31, 2024
76ab164
Support ERL_DIST_PORT
badlop Dec 31, 2024
3019cb0
Copy sql files in Dockerfile, copy also to /home/ejabberd/database/sql/
badlop Jan 2, 2025
339f790
Place Mnesia in database/ and link to database/NODENAME for backwards…
badlop Jan 15, 2025
f7a3691
Copy CONTAINER.md from ejabberd git, which now documents both images
badlop Dec 26, 2024
5db78ea
Adapt README.md to the ecs container image
badlop Jan 15, 2025
a1665f6
Update ecs README from upstream ejabberd repository
badlop Mar 28, 2025
f379d4b
Add backward support for old mnesia spool dir path that included node…
badlop Apr 1, 2025
9771b18
Update ecs documentation from upstream ejabberd
badlop Apr 16, 2025
e494c43
Copied README.md from ejabberd 25.07
badlop Jul 11, 2025
186a4bb
Copied README.md from ejabberd 25.08
badlop Aug 24, 2025
9a3b49e
Bump alpine to 1.22 and golang 1.25 (#125)
badlop Sep 15, 2025
db8214c
Copied README.md from ejabberd 25.10
badlop Oct 30, 2025
d563358
Copy some improvements from ejabberd upstream
badlop Oct 30, 2025
5e6953e
Copy recent improvements from ejabberd container image
badlop Nov 17, 2025
5984f5a
Copy other improvements from ejabberd container image
badlop Jan 21, 2026
541e07b
Copied CONTAINER.md from ejabberd 26.01
badlop Jan 21, 2026
aac2251
ejabberdctl.cfg: Move FIREWALL_WINDOW down, as it is used only for EPMD
badlop Feb 11, 2026
cbc5a98
Remove mod_muc_occupantid in example config: feature is now in mod_muc
badlop Feb 11, 2026
08800f5
Copied CONTAINER.md from ejabberd 26.03
badlop Mar 25, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 42 additions & 0 deletions .github/workflows/code-server.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: code-server

on:
push:
paths:
- '.github/workflows/code-server.yml'
- 'code-server/**'

jobs:

code-server:

runs-on: ubuntu-latest
permissions:
contents: read
packages: write

steps:

- uses: actions/checkout@v4

- name: Build image
run: docker build
code-server
--tag code-server

- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Push image
run: |
IMAGE_ID=ghcr.io/${{ github.repository_owner }}/code-server
# Strip git ref prefix from version
VERSION=$(echo "${{ github.ref }}" | sed -e 's,.*/\(.*\),\1,')
# Use Docker `latest` tag convention
[ "$VERSION" == "master" ] && VERSION=latest
docker tag code-server $IMAGE_ID:$VERSION
docker push $IMAGE_ID:$VERSION
42 changes: 42 additions & 0 deletions .github/workflows/devcontainer.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: devcontainer

on:
push:
paths:
- '.github/workflows/devcontainer.yml'
- 'devcontainer/**'

jobs:

devcontainer:

runs-on: ubuntu-latest
permissions:
contents: read
packages: write

steps:

- uses: actions/checkout@v4

- name: Build image
run: docker build
devcontainer
--tag devcontainer

- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Push image
run: |
IMAGE_ID=ghcr.io/${{ github.repository_owner }}/devcontainer
# Strip git ref prefix from version
VERSION=$(echo "${{ github.ref }}" | sed -e 's,.*/\(.*\),\1,')
# Use Docker `latest` tag convention
[ "$VERSION" == "master" ] && VERSION=latest
docker tag devcontainer $IMAGE_ID:$VERSION
docker push $IMAGE_ID:$VERSION
173 changes: 161 additions & 12 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,44 +2,193 @@ name: Tests

on:
push:
paths-ignore:
- '**.md'
- '**.bat'
paths:
- '.github/workflows/tests.yml'
- 'ecs/**'
- 'mix/**'
pull_request:
paths-ignore:
- '**.md'
- '**.bat'
paths:
- '.github/workflows/tests.yml'
- 'ecs/**'
- 'mix/**'

env:
REGISTRY_GHCR: ghcr.io
REGISTRY_LOCAL: localhost:5000
REGISTRY_DOCKER: docker.io
MIX_IMAGENAME_GHCR: ${{ github.repository_owner }}/mix
ECS_IMAGENAME_GHCR: ${{ github.repository_owner }}/ecs
MIX_IMAGENAME_DOCKERHUB: ejabberd/mix
ECS_IMAGENAME_DOCKERHUB: ejabberd/ecs

jobs:

build:
name: Build
runs-on: ubuntu-20.04
runs-on: ubuntu-24.04
strategy:
fail-fast: true
max-parallel: 1
permissions:
packages: write
services:
registry:
image: registry:2
ports:
- 5000:5000

steps:

- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Login to GHCR
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY_GHCR }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build ecs image
- name: Get git describe
id: gitdescribe
run: echo "ver=$(git describe --tags --exact-match 2>/dev/null || echo latest)" >> $GITHUB_OUTPUT

- name: Extract mix metadata (tags, labels)
id: mixmeta
if: github.ref_type == 'tag'
uses: docker/metadata-action@v5
with:
images: |
${{ env.REGISTRY_GHCR }}/${{ env.MIX_IMAGENAME_GHCR }}
${{ env.REGISTRY_DOCKER }}/${{ env.MIX_IMAGENAME_DOCKERHUB }}
labels: |
org.opencontainers.image.revision=${{ steps.gitdescribe.outputs.ver }}
org.opencontainers.image.licenses=GPL-2.0
org.opencontainers.image.vendor=ProcessOne

- name: Extract ecs metadata (tags, labels)
id: ecsmeta
if: github.ref_type == 'tag'
uses: docker/metadata-action@v5
with:
images: |
${{ env.REGISTRY_GHCR }}/${{ env.ECS_IMAGENAME_GHCR }}
${{ env.REGISTRY_DOCKER }}/${{ env.ECS_IMAGENAME_DOCKERHUB }}
labels: |
org.opencontainers.image.revision=${{ steps.gitdescribe.outputs.ver }}
org.opencontainers.image.licenses=GPL-2.0
org.opencontainers.image.vendor=ProcessOne

- name: Prepare local tags
id: localreg
run: |
cd ecs
./build.sh
tag="$(echo ${{ github.ref_name }} | sed -e 's|[/]\+|-|g')"
echo "mixlocaltag=${{ env.REGISTRY_LOCAL }}/${{ env.MIX_IMAGENAME_GHCR }}:$tag" >> $GITHUB_OUTPUT
echo "ecslocaltag=${{ env.REGISTRY_LOCAL }}/${{ env.ECS_IMAGENAME_GHCR }}:$tag" >> $GITHUB_OUTPUT

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
with:
driver-opts: network=host

- name: Build and push local mix image
uses: docker/build-push-action@v5
with:
build-args: |
VERSION=${{ steps.gitdescribe.outputs.ver }}
cache-from: type=gha
cache-to: type=gha,mode=max
context: mix
labels: ${{ steps.mixmeta.outputs.labels }}
platforms: linux/amd64
push: true
tags: |
${{ steps.localreg.outputs.mixlocaltag }}

- name: Prepare ecs Dockerfile
run: sed -i 's|docker.io/ejabberd/mix|${{ steps.localreg.outputs.mixlocaltag }}|g' ecs/Dockerfile

- name: Build and push local ecs image
uses: docker/build-push-action@v5
with:
build-args: |
VERSION=${{ steps.gitdescribe.outputs.ver }}
cache-from: type=gha
cache-to: type=gha,mode=max
context: ecs
labels: ${{ steps.ecsmeta.outputs.labels }}
platforms: linux/amd64
push: true
tags: |
${{ steps.localreg.outputs.ecslocaltag }}

- name: Run ecs image
run: |
docker images
docker run --name ejabberd -d -p 5222:5222 ejabberd/ecs:latest
docker run --name ejabberd -d -p 5222:5222 ${{ steps.localreg.outputs.ecslocaltag }}

- name: Wait ejabberd started
run: |
docker exec ejabberd bin/ejabberdctl started

- name: Check ecs results
if: always()
run: |
docker ps -s
docker logs ejabberd
docker logs ejabberd | grep -q "Start accepting TCP connections" || exit 1
docker logs ejabberd | grep -q "error" && exit 1 || exit 0
docker logs ejabberd | grep -q "Error" && exit 1 || exit 0

- name: Save image
run: |
docker image save ${{ steps.localreg.outputs.ecslocaltag }} --output ejabberd-latest.tar

- name: Upload image
uses: actions/upload-artifact@v4
with:
name: ejabberd-image
path: ejabberd-latest.tar

- run: |
echo "::notice::To get this image, download ejabberd-image.zip, "\
"uncompress it and run: " \
"docker image load -i ejabberd-latest.tar"

- name: Build and push mix image
uses: docker/build-push-action@v5
if: github.ref_type == 'tag'
with:
build-args: |
VERSION=${{ steps.gitdescribe.outputs.ver }}
cache-from: type=gha
cache-to: type=gha,mode=max
context: mix
labels: ${{ steps.mixmeta.outputs.labels }}
platforms: linux/amd64
push: true
tags: |
${{ steps.mixmeta.outputs.tags }}

- name: Build and push ecs image
uses: docker/build-push-action@v5
if: github.ref_type == 'tag'
with:
build-args: |
VERSION=${{ steps.gitdescribe.outputs.ver }}
cache-from: type=gha
cache-to: type=gha,mode=max
context: ecs
labels: ${{ steps.ecsmeta.outputs.labels }}
platforms: linux/amd64
push: true
tags: |
${{ steps.ecsmeta.outputs.tags }}
27 changes: 0 additions & 27 deletions .travis.yml

This file was deleted.

35 changes: 28 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,33 @@

# docker-ejabberd

This repository contains a set of Docker images for ejabberd.
This repository contains a set of container images to run or develop ejabberd:

- [ejabberd/mix](https://hub.docker.com/r/ejabberd/mix/): This image allows you to build develop
environment for ejabberd, using all dependencies packaged from the Docker image. You do not
need anything else to build ejabberd from source and write your own ejabberd plugins.
- [ejabberd/ecs](https://hub.docker.com/r/ejabberd/ecs/): This image is suitable for running
ejabberd with Docker in a simple, single-node setup.
- [mix](mix/) (published in [docker.io/ejabberd/mix](https://hub.docker.com/r/ejabberd/mix/)
and [ghcr.io/processone/mix](https://github.com/processone/docker-ejabberd/pkgs/container/mix)):

Please read the README file in each repository for documentation for each image.
Build a development environment for ejabberd. See [mix README](mix/README.md) file for details.

- [ecs](ecs/) (published in [docker.io/ejabberd/ecs](https://hub.docker.com/r/ejabberd/ecs/)
and [ghcr.io/processone/ecs](https://github.com/processone/docker-ejabberd/pkgs/container/ecs)):

Run ejabberd in a container with simple setup.
See [ecs README](ecs/README.md) file for details.

- [code-server](code-server/) (published in [ghcr.io/processone/code-server](https://github.com/orgs/processone/packages/container/package/code-server)):

Run Coder's code-server with a local ejabberd git clone.
See [VSCode section](https://docs.ejabberd.im/developer/vscode/) in ejabberds Docs.

- [devcontainer](devcontainer/) (published in [ghcr.io/processone/devcontainer](https://github.com/orgs/processone/packages/container/package/devcontainer)):

Use as a Dev Container for ejabberd in Visual Studio Code.
See [VSCode section](https://docs.ejabberd.im/developer/vscode/) in ejabberds Docs.

The [ejabberd source code repository](https://github.com/processone/ejabberd) also provides:

- [ejabberd](https://github.com/processone/ejabberd/tree/master/.github/container) (published in [ghcr.io/processone/ejabberd](https://github.com/processone/ejabberd/pkgs/container/ejabberd)):

Run ejabberd in a container with simple setup.
See [ejabberd's CONTAINER](https://github.com/processone/ejabberd/blob/master/CONTAINER.md) file for details.
Check the [differences between this image and `ecs`](https://github.com/processone/docker-ejabberd/blob/master/ecs/HUB-README.md#alternative-image-in-github).
30 changes: 30 additions & 0 deletions code-server/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
FROM debian:sid-slim

RUN apt-get update \
&& apt-get -y --no-install-recommends install \
curl ca-certificates \
autoconf automake git make gcc g++ \
erlang erlang-dev elixir rebar3 \
libexpat1-dev libgd-dev libpam0g-dev \
libsqlite3-dev libwebp-dev libyaml-dev \
libssl-dev

RUN curl -fsSL https://code-server.dev/install.sh | sh

RUN addgroup vscode --gid 1000 \
&& adduser --shell /bin/bash --ingroup vscode vscode -u 1000

USER vscode

RUN /usr/bin/code-server --install-extension erlang-ls.erlang-ls

WORKDIR /home/vscode
RUN echo "export PATH=/workspaces/ejabberd/_build/relive:$PATH" >>.bashrc \
&& echo "COOKIE" >.erlang.cookie \
&& chmod 400 .erlang.cookie

WORKDIR /workspaces/ejabberd
VOLUME ["workspaces/ejabberd"]
EXPOSE 1870 1883 4369-4399 5210 5222 5269 5280 5443

ENTRYPOINT ["code-server", "--bind-addr", "0.0.0.0:1870", "--auth", "none", "/workspaces/ejabberd"]
Loading