Docker image for the IceWarp Email Service created by the IceWarp team.
220
Docker image for the IceWarp Email Service created by the IceWarp team.
lapi-email-service is a stateless HTTP gateway that exposes the IceWarp
public email API and translates every call into one or more calls against
the Mail API of a running IceWarp
server. It holds no
database, no cache and no session store, so it can be scaled horizontally and
restarted freely.
It serves the public email REST surface — mail listing and reading, compose /
send / reply / forward, bulk operations, folders (CRUD, search, sync), tags,
attachments, snooze, summary, blacklist / whitelist and shared folders
(/email, /email_folder, /shared, …) — maps upstream errors onto proper
HTTP status codes, and builds direct attachment download links. Endpoints owned
by other services answer with a uniform HTTP 501.
services:
email-service:
image: icewarptechnology/lapi-email-service:${EMAIL_SERVICE_IMAGE:-latest}
restart: unless-stopped
environment:
- EMAIL_SERVICE_UPSTREAM_BASE_URL
- EMAIL_SERVICE_TICKET_BASE_URL
- EMAIL_SERVICE_LOGGER_LEVEL
- EMAIL_SERVICE_LOGGER_ENV
ports:
- "8080:8080/tcp" # HTTP
depends_on:
- icewarp
# .env
EMAIL_SERVICE_UPSTREAM_BASE_URL=http://icewarp:80/mailapi
EMAIL_SERVICE_TICKET_BASE_URL=https://webmail.example.com/mailapi
EMAIL_SERVICE_LOGGER_LEVEL=info
EMAIL_SERVICE_LOGGER_ENV=production
Or as a single command:
docker run --detach --publish 8080:8080 \
--env EMAIL_SERVICE_UPSTREAM_BASE_URL=http://icewarp:80/mailapi \
--env EMAIL_SERVICE_TICKET_BASE_URL=https://webmail.example.com/mailapi \
icewarptechnology/lapi-email-service
icewarp, http://icewarp:80/mailapi works out of the box.Every API request must carry an Authorization: Bearer <credential> header.
The credential may be either an api-service wrapper JWT — the upstream token
is read from its token claim, the caller identity from identityId — or the
raw IceWarp (TC) token, which is forwarded upstream verbatim. The JWT is
decoded locally without signature verification; token validity is enforced by
the IceWarp server, not by this image. A missing or empty Bearer value is
answered with HTTP 401.
30s)host:port (default :8080)10s)30s)trace/debug/info/warn/error (default info)development)error)0/1 - Enable the Prometheus metrics endpoint (default enabled)/metrics)Configuration is resolved in three layers, each overriding the previous one:
built-in defaults, a YAML config file, then EMAIL_SERVICE_* environment
variables. In most deployments the environment variables above are all you
need.
There's a default configuration file stored at /etc/email-service/config.yaml.
You can copy it out of the image to your home directory:
sudo docker run --rm -v ~:/cfg icewarptechnology/lapi-email-service cp /etc/email-service/config.yaml /cfg
Edit it and then run the container with the modified config mounted over the default one:
docker run --detach --publish 8080:8080 --volume ~/config.yaml:/etc/email-service/config.yaml:ro icewarptechnology/lapi-email-service
To review the configuration the container would actually use, without starting the server:
docker run --rm icewarptechnology/lapi-email-service config -c /etc/email-service/config.yaml --format yaml
/metrics./metrics./metrics.5xx is logged at
error level, 4xx at warn, everything else at info.If you encounter any issues with this image, please refer to our Knowledge Base or reach out to our Support Team for assistance.
Content type
Image
Digest
sha256:e49d58925…
Size
14.1 MB
Last updated
3 days ago
docker pull icewarptechnology/lapi-email-service