Skip to content

Instantly share code, notes, and snippets.

@arturohernandez10
Last active February 8, 2021 15:38
Show Gist options
  • Save arturohernandez10/c52a0c167c9e66bc2f3335bc45ee1a32 to your computer and use it in GitHub Desktop.
Save arturohernandez10/c52a0c167c9e66bc2f3335bc45ee1a32 to your computer and use it in GitHub Desktop.
Setup PaperCut

Installing and setting up papercut via command line

You need to have choco installed if you don't, run the following in a powershell with admin privileges.

Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
choco install papercut
echo 127.0.0.1  smtp.sendgrid.net >> %WINDIR%\System32\Drivers\Etc\Hosts

If you already have choco just run the following commands in any console, with admin rights

choco install papercut
echo 127.0.0.1  smtp.sendgrid.net >> %WINDIR%\System32\Drivers\Etc\Hosts

Configuration

You can continue to use smtp.sendgrid.net in your setup. Paper cut will receive all the email regardless of the receiver. If you would like to set up another SMTP server just add it to your Hosts file or replace >HOST< in the following command line and run it with admin right.

echo 127.0.0.1 HOST >> %WINDIR%\System32\Drivers\Etc\Hosts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment