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

smtp4dev won't run if ASPNETCORE_ENVIRONMENT environment variable is 'Development' #99

Closed
christofjans opened this issue Mar 8, 2019 · 2 comments

Comments

@christofjans
Copy link

I installed smtp4dev using the dotnet tool command:

dotnet tool install -g Rnwood.Smtp4dev --version "3.0.0-*"

Then, when I try to run it using smtp4dev I get reams of errors but the most important one seems to be related to aspnet-webpack

Application startup exception: System.AggregateException: One or more errors occurred. (Webpack dev middleware failed because of an error while loading 'aspnet-webpack'. Error was: Error: Cannot find module 'aspnet-webpack'
@rnwood
Copy link
Owner

rnwood commented Mar 8, 2019

Please can you confirm what it prints during startup:
Hosting environment: Production

@rnwood rnwood changed the title smtp4dev won't run smtp4dev won't run if ASPNETCORE_ENVIRONMENT environment variable is 'Development'(?) Mar 8, 2019
@christofjans
Copy link
Author

christofjans commented Mar 8, 2019

After executing the command smtp4dev the first few lines are:

smtp4dev version 3.0.0.0
https://github.com/rnwood/smtp4dev

Application startup exception: System.AggregateException: One or more errors occurred. (Webpack dev middleware failed because of an error while loading 'aspnet-webpack'. Error was: Error: Cannot find module 'aspnet-webpack'
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)

I did not see the output Hosting environment: anywhere.

The value of the env var ASPNETCORE_ENVIRONMENT is indeed set to Development on my machine.

@rnwood rnwood changed the title smtp4dev won't run if ASPNETCORE_ENVIRONMENT environment variable is 'Development'(?) smtp4dev won't run if ASPNETCORE_ENVIRONMENT environment variable is 'Development' Mar 8, 2019
@rnwood rnwood closed this as completed in c12538f Mar 8, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants