Skip to content

This Docker image add ssmtp service to official Docker Php7 Apache image.

Notifications You must be signed in to change notification settings

harobed/docker-php-ssmtp

Repository files navigation

Php7 + Apache + SSMTP

This image add ssmtp service to official Docker Php7 Apache image.

With ssmtp* you can use buildin mail Php function to send mails via smtp server configured by SSMTP_* environment variables.

This image enable also Apache Rewrite mod, RewriteEngine can be used in .htaccess.

docker-compose.yml example to connect apache service to postfix:

version: '3'
services:
  apache:
    image: harobed/php-ssmtp:7-apache
    environment:
      - SSMTP_HOST=postfix
      - SSMTP_PORT=25
      - SSMTP_FROM_HOSTNAME=example.com
      - SSMTP_USE_TLS=Yes
      - SSMTP_USE_STARLTLS=Yes
      - SSMTP_AUTH_USER=user
      - SSMTP_AUTH_PASSWORD=password
    ports:
      - 80

  postfix:
    image: harobed/versatile-postfix:latest
    command: exemple.com user:password
    environment:
      - DISABLE_DKIM=1

networks:
  default:
    driver: bridge

See Dockerfile to see environment variable default values.

How to test

$ git clone https://github.com/harobed/docker-php-ssmtp.git
$ cd docker-php-ssmtp
$ docker-compose up -d
$ echo "Browse to http://`docker-compose port apache 80`"

About

This Docker image add ssmtp service to official Docker Php7 Apache image.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published