Acts as an SMTP server for HP printers, taking attachments and writing them to a folder
1.8K
This repository contains an SMTP server application designed to be connected to by HP printers, specifically the CM2320nf MFP model. The server accepts attachments, which are images scanned by the printer, and stores them in a specified file path.
The application can be configured using command-line parameters or environment variables.
--SmtpPort: The port on which the SMTP server will listen. Defaults to 25 for executable, and 25000 for the docker container (kubernetes doesn't like ports below 1024).--OutputPath: The path where the attachments will be stored. This parameter is required.SMTP_SMTPPORT: The port on which the SMTP server will listen. Defaults to 25.SMTP_OUTPUTPATH: The path where the attachments will be stored. This variable is required.You can run the application using Docker.
Build the Docker image:
docker build -t dsmithson/smtp-server-service:latest .
Run the Docker container:
docker run -d -p 25:25 -e SMTP_OUTPUTPATH=/attachments dsmithson/smtp-server-service:latest
You can also specify the port:
docker run -d -p 2525:2525 -e SMTP_SMTPPORT=2525 -e SMTP_OUTPUTPATH=/attachments dsmithson/smtp-server-service:latest
Ensure you have the .NET Core runtime installed.
Build the application:
dotnet build
Run the application:
dotnet run --project /src/SmtpServerService/SmtpServerService.csproj --SmtpPort 25 --OutputPath /attachments
Or using environment variables:
SMTP_SMTPPORT=25 SMTP_OUTPUTPATH=/attachments dotnet run --project /src/SmtpServerService/SmtpServerService.csproj
This project is licensed under the MIT License - see the LICENSE file for details.
Content type
Image
Digest
sha256:db0b17d6d…
Size
2.8 MB
Last updated
about 2 years ago
docker pull dsmithson/printersmtpserver