Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide cc support #38

Merged
merged 13 commits into from
Mar 25, 2025
Prev Previous commit
Update README with basic local setup instructions for VSCode
Co-authored-by: zzirnheld-mia <[email protected]>
  • Loading branch information
LaithSaq and zzirnheld-mia committed Mar 24, 2025
commit 9d30a41ed1ec1ab44afee55e97d3838fa803d269
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -48,6 +48,24 @@ The following table lists the configurable parameters for MiddleMail. To pass th
| `REDIS_INSTANCE_NAME` | The Redis instance name |
| `DISABLE_SMTP` | Do not actually send anything via SMTP. |

## Basic Local Setup
This setup assumes the use of Visual Studio Code as an editor. If not using
VSCode, configure environment variables in whatever way is appropriate for your
preferred launch mechanism. This setup also runs the dependencies in Docker.
You don't have to do this, but it sure is convenient.

1. Clone this repository.
1. Create a `launch.json` in which you configure the environment variables described above in the Configuration section. This `launch.json` should target the build of the `MiddleMail.Server` project, since that's the standalone process. You probably also need to create a `tasks.json` to run it, with a build task, but that's no different from the standard `launch.json` setup.
1. Run the `docker-compose.dev.yml` file to spin up dependency services. It mainly includes:
- A RabbitMQ container as an email message queue.
- An Elasticsearch container as a storage solution.
- _Note that if you're not using Elasticsearch, you can edit the services found in `MiddleMail/Server/Program.cs` to replace `ElasticSearchStorage` in `services.AddSingleton<IStorage, ElasticSearchStorage>();` with `MemoryStorage`, an in-memory storage solution. You will also need to edit the dependencies in `MiddleMail.Server.csproj` to depend on `MiddleMail.Storage.Memory` instead of `MiddleMail.Storage.Elastic`._
- A Redis container as a caching solution.
- An smtp4dev container as an SMTP server for development and testing.
1. Run the MiddleMailServer process (with your `launch.json`).
1. Optional: Test your new MiddleMail instance using the `tools/EmailMessageGenerator` project to send test emails.


## Tools

| Project | Description |