{"id":20532045,"url":"https://github.com/monogramm/autodiscover-email-settings","last_synced_at":"2025-04-05T01:04:15.290Z","repository":{"id":36240300,"uuid":"173385361","full_name":"Monogramm/autodiscover-email-settings","owner":"Monogramm","description":":whale: :wrench: Provides Autodiscover capabilities for IMAP/POP/SMTP/LDAP services on Microsoft Outlook/Apple Mail and Autoconfig capabilities for Thunderbird","archived":false,"fork":false,"pushed_at":"2025-02-20T05:25:16.000Z","size":254,"stargazers_count":136,"open_issues_count":10,"forks_count":21,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-29T00:04:48.736Z","etag":null,"topics":["apple-mail","autoconf","autoconfigure","autodiscover","docker","email","imap","ldap","node","outlook","pop","pop3","smtp","thunderbird"],"latest_commit_sha":null,"homepage":"","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Monogramm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-03-02T00:28:31.000Z","updated_at":"2025-03-23T08:25:53.000Z","dependencies_parsed_at":"2024-09-14T13:24:06.450Z","dependency_job_id":"b7f7b029-a0e7-43af-8e48-76c8e3314ee8","html_url":"https://github.com/Monogramm/autodiscover-email-settings","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Monogramm%2Fautodiscover-email-settings","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Monogramm%2Fautodiscover-email-settings/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Monogramm%2Fautodiscover-email-settings/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Monogramm%2Fautodiscover-email-settings/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Monogramm","download_url":"https://codeload.github.com/Monogramm/autodiscover-email-settings/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247271517,"owners_count":20911587,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["apple-mail","autoconf","autoconfigure","autodiscover","docker","email","imap","ldap","node","outlook","pop","pop3","smtp","thunderbird"],"created_at":"2024-11-16T00:12:18.760Z","updated_at":"2025-04-05T01:04:15.270Z","avatar_url":"https://github.com/Monogramm.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ![Autodiscover](icon.svg) Autodiscover Email Settings\n\n[![Build Status](https://travis-ci.org/Monogramm/autodiscover-email-settings.svg)](https://travis-ci.org/Monogramm/autodiscover-email-settings)\n[![Codacy Badge](https://api.codacy.com/project/badge/Grade/f471992f0aa348b791c9ed17ccea344d)](https://www.codacy.com/gh/Monogramm/autodiscover-email-settings?utm_source=github.com\u0026utm_medium=referral\u0026utm_content=Monogramm/autodiscover-email-settings\u0026utm_campaign=Badge_Grade)\n[![Docker Pulls](https://img.shields.io/docker/pulls/monogramm/autodiscover-email-settings.svg)](https://hub.docker.com/r/monogramm/autodiscover-email-settings/)\n![Docker Image Size (latest by date)](https://img.shields.io/docker/image-size/monogramm/autodiscover-email-settings)\n\nThis service is created to autodiscover your provider email settings.\n\nIt provides IMAP/POP/SMTP/LDAP Autodiscover capabilities on Microsoft Outlook/Apple Mail, Autoconfig capabilities for Thunderbird, and Configuration Profiles for iOS/Apple Mail.\n\n**A simple support page is also available at the root of the autodiscover domain.**\n\n![General settings](docs/screenshot_01.png)\n\n![General settings](docs/screenshot_02.png)\n\n## DNS settings\n\n    autoconfig              IN      A      {{$AUTODISCOVER_IP}}\n    autodiscover            IN      A      {{$AUTODISCOVER_IP}}\n    imap                    IN      CNAME  {{$MX_DOMAIN}}.\n    smtp                    IN      CNAME  {{$MX_DOMAIN}}.\n    @                       IN      MX 10  {{$MX_DOMAIN}}.\n    @                       IN      TXT    \"mailconf=https://autoconfig.{{$DOMAIN}}/mail/config-v1.1.xml\"\n    _imaps._tcp             IN      SRV    0 0 {{IMAP_PORT}} {{MX_DOMAIN}}.\n    _pop3s._tcp             IN      SRV    0 0 {{POP_PORT}} {{MX_DOMAIN}}.\n    _submission._tcp        IN      SRV    0 0 {{SMTP_PORT}} {{MX_DOMAIN}}.\n    _autodiscover._tcp      IN      SRV    0 0 443 autodiscover.{{$DOMAIN}}.\n    _ldap._tcp              IN      SRV    0 0 {{LDAP_PORT}} {{LDAP_HOST}}.\n\nReplace above variables with data according to this table\n\n| Variable        | Description                         |\n| --------------- | ----------------------------------- |\n| MX_DOMAIN       | The hostname name of your MX server |\n| DOMAIN          | Your apex/bare/naked Domain         |\n| AUTODISCOVER_IP | IP of the Autoconfig HTTP           |\n| IMAP_PORT       | Port for your IMAP server           |\n| POP_PORT        | Port for your POP server            |\n| SMTP_PORT       | Port for your SMTP server           |\n| LDAP_HOST       | The hostname of your LDAP server    |\n| LDAP_PORT       | Port for your LDAP server           |\n\n* * *\n\n## Usage\n\n[traefik](https://github.com/containous/traefik) can proxy your containers on docker, on docker swarm, and on a wide range of orchestrators.\nYou can also achieve this with another proxy like [Nginx](https://www.nginx.com/) for instance.\n\nThough not the preferred solution, it is also possible to run the project without docker, as a `systemd` service.\n\n### docker\n\n```yaml\nversion: '2'\n\nservices:\n  autodiscover-example-com:\n    image: monogramm/autodiscover-email-settings:latest\n    container_name: autodiscover\n    environment:\n      - COMPANY_NAME=Company\n      - SUPPORT_URL=https://autodiscover.example.com\n      - DOMAIN=example.com\n      # IMAP configuration (host mandatory to enable)\n      - IMAP_HOST=imap.example.com\n      - IMAP_PORT=993\n      - IMAP_SOCKET=SSL\n      # POP configuration (host mandatory to enable)\n      - POP_HOST=pop3.example.com\n      - POP_PORT=995\n      - POP_SOCKET=SSL\n      # SMTP configuration (host mandatory to enable)\n      - SMTP_HOST=smtp.example.com\n      - SMTP_PORT=587\n      - SMTP_SOCKET=STARTTLS\n      # MobileSync/ActiveSync configuration (url mandatory to enable)\n      - MOBILESYNC_URL=https://sync.example.com\n      - MOBILESYNC_NAME=sync.example.com\n      # LDAP configuration (host mandatory to enable)\n      - LDAP_HOST=ldap.example.com\n      - LDAP_PORT=636\n      - LDAP_SOCKET=SSL\n      - LDAP_BASE=dc=ldap,dc=example,dc=com\n      - LDAP_USER_FIELD=uid\n      - LDAP_USER_BASE=ou=People,dc=ldap,dc=example,dc=com\n      - LDAP_SEARCH=(|(objectClass=PostfixBookMailAccount))\n      # Apple mobile config identifiers (identifier mandatory to enable)\n      - PROFILE_IDENTIFIER=com.example.autodiscover\n      - PROFILE_UUID=92943D26-CAB3-4086-897D-DC6C0D8B1E86\n      - MAIL_UUID=7A981A9E-D5D0-4EF8-87FE-39FD6A506FAC\n      - LDAP_UUID=6ECB6BA9-2208-4ABF-9E60-4E9F4CD7309E\n    labels:\n      - \"traefik.port=8000\"\n      - \"traefik.frontend.rule=Host:autoconfig.example.com,autodiscover.example.com\"\n```\n\n### docker swarm\n\n```yaml\nversion: '3'\n\nservices:\n  autodiscover-example-com:\n    image: monogramm/autodiscover-email-settings:latest\n    container_name: autodiscover\n    environment:\n      - COMPANY_NAME=Company\n      - SUPPORT_URL=https://autodiscover.example.com\n      - DOMAIN=example.com\n      # IMAP configuration (host mandatory to enable)\n      - IMAP_HOST=imap.example.com\n      - IMAP_PORT=993\n      - IMAP_SOCKET=SSL\n      # POP configuration (host mandatory to enable)\n      - POP_HOST=pop3.example.com\n      - POP_PORT=995\n      - POP_SOCKET=SSL\n      # SMTP configuration (host mandatory to enable)\n      - SMTP_HOST=smtp.example.com\n      - SMTP_PORT=587\n      - SMTP_SOCKET=STARTTLS\n      # MobileSync/ActiveSync configuration (url mandatory to enable)\n      - MOBILESYNC_URL=https://sync.example.com\n      - MOBILESYNC_NAME=sync.example.com\n      # LDAP configuration (host mandatory to enable)\n      - LDAP_HOST=ldap.example.com\n      - LDAP_PORT=636\n      - LDAP_SOCKET=SSL\n      - LDAP_BASE=dc=ldap,dc=example,dc=com\n      - LDAP_USER_FIELD=uid\n      - LDAP_USER_BASE=ou=People,dc=ldap,dc=example,dc=com\n      - LDAP_SEARCH=(|(objectClass=PostfixBookMailAccount))\n      # Apple mobile config identifiers (identifier mandatory to enable)\n      - PROFILE_IDENTIFIER=com.example.autodiscover\n      - PROFILE_UUID=92943D26-CAB3-4086-897D-DC6C0D8B1E86\n      - MAIL_UUID=7A981A9E-D5D0-4EF8-87FE-39FD6A506FAC\n      - LDAP_UUID=6ECB6BA9-2208-4ABF-9E60-4E9F4CD7309E\n    deploy:\n      replicas: 1\n      labels:\n        - \"traefik.port=8000\"\n        - \"traefik.frontend.rule=Host:autoconfig.example.com,autodiscover.example.com\"\n```\n\n### nginx\n\nThe following is an example of NGinx configuration assuming NGinx for Autodiscover Email Settings located at `autoconfig.example.com` and `autodiscover.example.com`. The following setup assumes NGinx to be running on the host machine and autodiscover to expose itself on port 8000:\n\n```nginx\n# HTTP configuration with HTTPS redirection\nserver {\n    listen 80;\n    listen [::]:80;\n    server_name autoconfig.example.com autodiscover.example.com;\n    return 301 https://$server_name$request_uri;\n}\n\n# HTTPS configuration with Let's Encrypt certificates\nserver {\n    listen 443 ssl http2;\n    listen [::]:443 ssl http2;\n    server_name autoconfig.example.com autodiscover.example.com;\n\n    # Set location of error and access logs\n    error_log /var/log/nginx/autoconfig.example.com/error.log;\n    access_log /var/log/nginx/autoconfig.example.com/access.log combined_ssl;\n\n    # Hide Nginx version\n    server_tokens off;\n\n    # SSL configuration (adapt to your environment or managed by Certbot)\n    ssl_certificate /etc/letsencrypt/live/autoconfig.example.com/fullchain.pem;\n    ssl_certificate_key /etc/letsencrypt/live/autoconfig.example.com/privkey.pem;\n    include /etc/nginx/ssl_params;\n    include /etc/nginx/header_params;\n\n    location / {\n        proxy_set_header X-Real-IP $remote_addr;\n        proxy_set_header X-Forwarded-Proto $scheme;\n        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;\n        proxy_set_header Host $http_host;\n\n        # Enable HSTS once SSL configuration fully validated\n        #add_header Strict-Transport-Security \"max-age=15552000; includeSubDomains\" always;\n        add_header Front-End-Https on;\n\n        # Redirect NGinx traffic to locally running autodiscover\n        # if NGinx is running inside docker, adapt to either DOCKER_HOST or docker container name\n        proxy_pass http://127.0.0.1:8000;\n\n        proxy_redirect off;\n    }\n}\n```\n\n### service\n\nThe following is an example of `systemd` service configuration for Autodiscover Email Settings. The following setup assumes the following:\n- `node` and `yarn` are installed on your marchine\n- project is located at `/srv/http/autodiscover`\n- the project dependencies have been previously installed with `yarn --prod`\n- there is an `autodiscover` user and group with sufficient permissions to read the project and run `node`\n\n```properties\n[Unit]\nDescription=Autodiscover service\n\n[Service]\nType=simple\nWorkingDirectory=/srv/http/autodiscover\nUser=autodiscover\nGroup=autodiscover\nEnvironment=\"NODE_ENV=production\"\n\n#Environment=\"COMPANY_NAME=Company\"\n#Environment=\"SUPPORT_URL=https://autodiscover.example.com\"\n#Environment=\"DOMAIN=example.com\"\n\n# IMAP configuration (host mandatory to enable)\nEnvironment=\"IMAP_HOST=imap.example.com\"\nEnvironment=\"IMAP_PORT=993\"\nEnvironment=\"IMAP_SOCKET=SSL\"\n\n# POP configuration (host mandatory to enable)\n#Environment=\"POP_HOST=imap.example.com\"\n#Environment=\"POP_PORT=995\"\n#Environment=\"POP_SOCKET=SSL\"\n\n# SMTP configuration (host mandatory to enable)\nEnvironment=\"SMTP_HOST=imap.example.com\"\nEnvironment=\"SMTP_PORT=465\"\nEnvironment=\"SMTP_SOCKET=SSL\"\n\n# MobileSync/ActiveSync configuration (url mandatory to enable)\n#Environment=\"MOBILESYNC_URL=https://sync.example.com\"\n#Environment=\"MOBILESYNC_NAME=sync.example.com\"\n\n# LDAP configuration (host mandatory to enable)\n#Environment=\"LDAP_HOST=ldap.example.com\"\n#Environment=\"LDAP_PORT=636\"\n#Environment=\"LDAP_SOCKET=SSL\"\n#Environment=\"LDAP_BASE=dc=ldap,dc=example,dc=com\"\n#Environment=\"LDAP_USER_FIELD=uid\"\n#Environment=\"LDAP_USER_BASE=ou=People,dc=ldap,dc=example,dc=com\"\n#Environment=\"LDAP_SEARCH=(|(objectClass=PostfixBookMailAccount))\"\n\n# Apple mobile config identifiers (identifier mandatory to enable)\nEnvironment=\"PROFILE_IDENTIFIER=com.example.autodiscover\"\nEnvironment=\"PROFILE_UUID=92943D26-CAB3-4086-897D-DC6C0D8B1E86\"\nEnvironment=\"MAIL_UUID=7A981A9E-D5D0-4EF8-87FE-39FD6A506FAC\"\n#Environment=\"LDAP_UUID=6ECB6BA9-2208-4ABF-9E60-4E9F4CD7309E\"\n\nExecStart=/usr/bin/node /srv/http/autodiscover/index.js\nRestart=always\n\n[Install]\nWantedBy=multi-user.target\n\n```\n\n## Credits\n\nInspired from \u003chttps://github.com/sylvaindumont/autodiscover.xml\u003e, but without the few restrictions mentioned in the original project notes and with a simple support page to allow manual setup and iOS profile download.\n\nThe original project was inspired from \u003chttps://github.com/johansmitsnl/docker-email-autodiscover\u003e, but with \u003chttps://github.com/Tiliq/autodiscover.xml\u003e instead of \u003chttps://github.com/gronke/email-autodiscover\u003e to allow a much lighter image based of node on alpine instead of apache on debian.\n\nThanks to [@HLFH ](https://github.com/HLFH) for providing sample NGinx configuration and systemd service configuration.\n\n## Notes\n\nThe above autoconfiguration methods assume the following:\n\n-   If username does not contain `@`, full email address will be generated based on domain settings\n\n## Links\n\n-   Mozilla [Autoconfig configuration](https://developer.mozilla.org/en-US/docs/Mozilla/Thunderbird/Autoconfiguration/FileFormat/HowTo)\n\n-   Microsoft [Exchange Command Reference](https://docs.microsoft.com/en-us/openspecs/exchange_server_protocols/ms-ascmd/1a3490f1-afe1-418a-aa92-6f630036d65a)\n\n-   Apple [ConfigurationProfile reference](https://developer.apple.com/library/archive/featuredarticles/iPhoneConfigurationProfileRef/index.html)\n\n-   [DNS SRV Records for LDAP](https://github.com/doctorjbeam/LDAPAutoDiscover)\n\n-   [Bootstrap](https://getbootstrap.com/), [jQuery](https://jquery.com/) and [Popper.js](https://popper.js.org/) used for default support page\n\n## License\n\nThis project is distributed under the [MIT License](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmonogramm%2Fautodiscover-email-settings","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmonogramm%2Fautodiscover-email-settings","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmonogramm%2Fautodiscover-email-settings/lists"}