Why is IIS giving me a 502.5 error on asp.net core app?
I took over a project from a guy who didn't really know what he was doing in terms of angular / .net core / node js, etc.
We have a new version that works on my machine (of course), but for some reason, when I updated the web server, I'm getting 502.5.
Yes, I know there are a lot of 502.5 posts on SO, but still have the problem... not sure what to do next :(. Also, I'm not a web guy, I just took this over as a favor.
Here is what I know right now:
1) works fine on my machine
2) used to work fine on the web server until the latest push (I have done other pushes)
3) the site is NOT a DLL like some of the other SO posts, mine is an exe for some reason.
4) event log shows:
Application 'MACHINE/WEBROOT/APPHOST/xxxCONTROL' with physical root 'C:inetpubwwwrootxxxControl' failed to start process with commandline '.xx_control.exe ', ErrorCode = '0x80070002' : 0.
Some of the other SO posts with the apps running as DLLs have the exe as the arg and dotnet as the proc. Do I need to do that?
5) if I just run xx_control, it starts and runs on localhost:
6) my web config looks like this:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<system.webServer>
<handlers>
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModule" resourceType="Unspecified" />
</handlers>
<aspNetCore processPath=".xx_control.exe" arguments="" stdoutLogEnabled="false">
<environmentVariables />
</aspNetCore>
</system.webServer>
<connectionStrings>
<add name="xxxx" connectionString="Server=xxxxxx;Database=xxxxx;Uid=xxxxxx;pwd=xxxxx;" providerName="System.Data.SqlClient" />
</connectionStrings>
</configuration>
7) If I try do a publish, it errors out (it always has which is why I was copying the stuff over manually)
1>------ Build started: Project: xxx_Control, Configuration: Release Any CPU ------
1>xxx_Control -> C:Sourcexxxxxxxxx_ControlbinReleasenet472xxx_Control.exe
2>------ Publish started: Project: xxx_Control, Configuration: Release Any CPU ------
Connecting to C:WindowsTempxxx...
xxx_Control -> C:Sourcexxxxxxxxx_ControlbinReleasenet472win7-x86xxx_Control.exe
npm install
npm WARN saveError EPERM: operation not permitted, rename 'C:Sourcexxxxxxxxx_Controlnpm-shrinkwrap.json.1698582667' -> 'C:Sourcexxxxxxxxx_Controlnpm-shrinkwrap.json'
audited 15221 packages in 9.82s
found 183 vulnerabilities (125 low, 52 moderate, 5 high, 1 critical)
run npm audit fix
to fix them, or npm audit
for details
node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js --env.prod
internal/modules/cjs/loader.js:583
throw err;
^
EXEC(0,0): Error : Cannot find module './$data'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)
at Function.Module._load (internal/modules/cjs/loader.js:507:25)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (internal/modules/cjs/helpers.js:20:18)
at Object. (C:Sourcexxxxxxxxx_Controlnode_modulesajvlibajv.js:10:23)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
C:Sourcexxxxxxxxx_Controlxxx_Control.csproj(111,5): Error MSB3073: The command "node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js --env.prod" exited with code 1.
2>Build failed. Check the Output window for more details.
========== Build: 1 succeeded, 0 failed, 1 up-to-date, 0 skipped ==========
========== Publish: 0 succeeded, 1 failed, 0 skipped ==========
7) I'm supposed to copy the bins from binReleasenet472 correct? There are also some in the binReleasenet472win7-x86 directory.. I tried both for the heck of it... same thing...
Any ideas?
node.js angularjs asp.net-core
|
show 2 more comments
I took over a project from a guy who didn't really know what he was doing in terms of angular / .net core / node js, etc.
We have a new version that works on my machine (of course), but for some reason, when I updated the web server, I'm getting 502.5.
Yes, I know there are a lot of 502.5 posts on SO, but still have the problem... not sure what to do next :(. Also, I'm not a web guy, I just took this over as a favor.
Here is what I know right now:
1) works fine on my machine
2) used to work fine on the web server until the latest push (I have done other pushes)
3) the site is NOT a DLL like some of the other SO posts, mine is an exe for some reason.
4) event log shows:
Application 'MACHINE/WEBROOT/APPHOST/xxxCONTROL' with physical root 'C:inetpubwwwrootxxxControl' failed to start process with commandline '.xx_control.exe ', ErrorCode = '0x80070002' : 0.
Some of the other SO posts with the apps running as DLLs have the exe as the arg and dotnet as the proc. Do I need to do that?
5) if I just run xx_control, it starts and runs on localhost:
6) my web config looks like this:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<system.webServer>
<handlers>
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModule" resourceType="Unspecified" />
</handlers>
<aspNetCore processPath=".xx_control.exe" arguments="" stdoutLogEnabled="false">
<environmentVariables />
</aspNetCore>
</system.webServer>
<connectionStrings>
<add name="xxxx" connectionString="Server=xxxxxx;Database=xxxxx;Uid=xxxxxx;pwd=xxxxx;" providerName="System.Data.SqlClient" />
</connectionStrings>
</configuration>
7) If I try do a publish, it errors out (it always has which is why I was copying the stuff over manually)
1>------ Build started: Project: xxx_Control, Configuration: Release Any CPU ------
1>xxx_Control -> C:Sourcexxxxxxxxx_ControlbinReleasenet472xxx_Control.exe
2>------ Publish started: Project: xxx_Control, Configuration: Release Any CPU ------
Connecting to C:WindowsTempxxx...
xxx_Control -> C:Sourcexxxxxxxxx_ControlbinReleasenet472win7-x86xxx_Control.exe
npm install
npm WARN saveError EPERM: operation not permitted, rename 'C:Sourcexxxxxxxxx_Controlnpm-shrinkwrap.json.1698582667' -> 'C:Sourcexxxxxxxxx_Controlnpm-shrinkwrap.json'
audited 15221 packages in 9.82s
found 183 vulnerabilities (125 low, 52 moderate, 5 high, 1 critical)
run npm audit fix
to fix them, or npm audit
for details
node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js --env.prod
internal/modules/cjs/loader.js:583
throw err;
^
EXEC(0,0): Error : Cannot find module './$data'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)
at Function.Module._load (internal/modules/cjs/loader.js:507:25)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (internal/modules/cjs/helpers.js:20:18)
at Object. (C:Sourcexxxxxxxxx_Controlnode_modulesajvlibajv.js:10:23)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
C:Sourcexxxxxxxxx_Controlxxx_Control.csproj(111,5): Error MSB3073: The command "node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js --env.prod" exited with code 1.
2>Build failed. Check the Output window for more details.
========== Build: 1 succeeded, 0 failed, 1 up-to-date, 0 skipped ==========
========== Publish: 0 succeeded, 1 failed, 0 skipped ==========
7) I'm supposed to copy the bins from binReleasenet472 correct? There are also some in the binReleasenet472win7-x86 directory.. I tried both for the heck of it... same thing...
Any ideas?
node.js angularjs asp.net-core
I think, firstly you should resolve npm issues for keeping project alive. After that you could use normal publish. Also you create .net core application and use net472(it is full framework) build i think it is incorect. But problem on the server is not here, try to reinstall hosting boundle docs.microsoft.com/en-us/aspnet/core/host-and-deploy/iis/… then use iisreset and check your app
– itikhomi
Jan 18 at 19:40
Have you tried pushing an older working build?
– Kevin B
Jan 18 at 19:55
@itikhomi I tried setting it up on my dev PC and I get the same exact errors. Like I said in the post, the original guy that built it didn't know what he was doing and I do pretty much everything EXCEPT web development lol. I've got .net core and the hosting bundle installed. So something is messed up... does the web.config look right?
– SledgeHammer
Jan 18 at 20:09
@itikhomi Also, when I run the exe directly, it works there too...
– SledgeHammer
Jan 18 at 20:10
@itikhomi do you know what the $data module error is?
– SledgeHammer
Jan 18 at 20:10
|
show 2 more comments
I took over a project from a guy who didn't really know what he was doing in terms of angular / .net core / node js, etc.
We have a new version that works on my machine (of course), but for some reason, when I updated the web server, I'm getting 502.5.
Yes, I know there are a lot of 502.5 posts on SO, but still have the problem... not sure what to do next :(. Also, I'm not a web guy, I just took this over as a favor.
Here is what I know right now:
1) works fine on my machine
2) used to work fine on the web server until the latest push (I have done other pushes)
3) the site is NOT a DLL like some of the other SO posts, mine is an exe for some reason.
4) event log shows:
Application 'MACHINE/WEBROOT/APPHOST/xxxCONTROL' with physical root 'C:inetpubwwwrootxxxControl' failed to start process with commandline '.xx_control.exe ', ErrorCode = '0x80070002' : 0.
Some of the other SO posts with the apps running as DLLs have the exe as the arg and dotnet as the proc. Do I need to do that?
5) if I just run xx_control, it starts and runs on localhost:
6) my web config looks like this:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<system.webServer>
<handlers>
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModule" resourceType="Unspecified" />
</handlers>
<aspNetCore processPath=".xx_control.exe" arguments="" stdoutLogEnabled="false">
<environmentVariables />
</aspNetCore>
</system.webServer>
<connectionStrings>
<add name="xxxx" connectionString="Server=xxxxxx;Database=xxxxx;Uid=xxxxxx;pwd=xxxxx;" providerName="System.Data.SqlClient" />
</connectionStrings>
</configuration>
7) If I try do a publish, it errors out (it always has which is why I was copying the stuff over manually)
1>------ Build started: Project: xxx_Control, Configuration: Release Any CPU ------
1>xxx_Control -> C:Sourcexxxxxxxxx_ControlbinReleasenet472xxx_Control.exe
2>------ Publish started: Project: xxx_Control, Configuration: Release Any CPU ------
Connecting to C:WindowsTempxxx...
xxx_Control -> C:Sourcexxxxxxxxx_ControlbinReleasenet472win7-x86xxx_Control.exe
npm install
npm WARN saveError EPERM: operation not permitted, rename 'C:Sourcexxxxxxxxx_Controlnpm-shrinkwrap.json.1698582667' -> 'C:Sourcexxxxxxxxx_Controlnpm-shrinkwrap.json'
audited 15221 packages in 9.82s
found 183 vulnerabilities (125 low, 52 moderate, 5 high, 1 critical)
run npm audit fix
to fix them, or npm audit
for details
node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js --env.prod
internal/modules/cjs/loader.js:583
throw err;
^
EXEC(0,0): Error : Cannot find module './$data'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)
at Function.Module._load (internal/modules/cjs/loader.js:507:25)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (internal/modules/cjs/helpers.js:20:18)
at Object. (C:Sourcexxxxxxxxx_Controlnode_modulesajvlibajv.js:10:23)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
C:Sourcexxxxxxxxx_Controlxxx_Control.csproj(111,5): Error MSB3073: The command "node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js --env.prod" exited with code 1.
2>Build failed. Check the Output window for more details.
========== Build: 1 succeeded, 0 failed, 1 up-to-date, 0 skipped ==========
========== Publish: 0 succeeded, 1 failed, 0 skipped ==========
7) I'm supposed to copy the bins from binReleasenet472 correct? There are also some in the binReleasenet472win7-x86 directory.. I tried both for the heck of it... same thing...
Any ideas?
node.js angularjs asp.net-core
I took over a project from a guy who didn't really know what he was doing in terms of angular / .net core / node js, etc.
We have a new version that works on my machine (of course), but for some reason, when I updated the web server, I'm getting 502.5.
Yes, I know there are a lot of 502.5 posts on SO, but still have the problem... not sure what to do next :(. Also, I'm not a web guy, I just took this over as a favor.
Here is what I know right now:
1) works fine on my machine
2) used to work fine on the web server until the latest push (I have done other pushes)
3) the site is NOT a DLL like some of the other SO posts, mine is an exe for some reason.
4) event log shows:
Application 'MACHINE/WEBROOT/APPHOST/xxxCONTROL' with physical root 'C:inetpubwwwrootxxxControl' failed to start process with commandline '.xx_control.exe ', ErrorCode = '0x80070002' : 0.
Some of the other SO posts with the apps running as DLLs have the exe as the arg and dotnet as the proc. Do I need to do that?
5) if I just run xx_control, it starts and runs on localhost:
6) my web config looks like this:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<system.webServer>
<handlers>
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModule" resourceType="Unspecified" />
</handlers>
<aspNetCore processPath=".xx_control.exe" arguments="" stdoutLogEnabled="false">
<environmentVariables />
</aspNetCore>
</system.webServer>
<connectionStrings>
<add name="xxxx" connectionString="Server=xxxxxx;Database=xxxxx;Uid=xxxxxx;pwd=xxxxx;" providerName="System.Data.SqlClient" />
</connectionStrings>
</configuration>
7) If I try do a publish, it errors out (it always has which is why I was copying the stuff over manually)
1>------ Build started: Project: xxx_Control, Configuration: Release Any CPU ------
1>xxx_Control -> C:Sourcexxxxxxxxx_ControlbinReleasenet472xxx_Control.exe
2>------ Publish started: Project: xxx_Control, Configuration: Release Any CPU ------
Connecting to C:WindowsTempxxx...
xxx_Control -> C:Sourcexxxxxxxxx_ControlbinReleasenet472win7-x86xxx_Control.exe
npm install
npm WARN saveError EPERM: operation not permitted, rename 'C:Sourcexxxxxxxxx_Controlnpm-shrinkwrap.json.1698582667' -> 'C:Sourcexxxxxxxxx_Controlnpm-shrinkwrap.json'
audited 15221 packages in 9.82s
found 183 vulnerabilities (125 low, 52 moderate, 5 high, 1 critical)
run npm audit fix
to fix them, or npm audit
for details
node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js --env.prod
internal/modules/cjs/loader.js:583
throw err;
^
EXEC(0,0): Error : Cannot find module './$data'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)
at Function.Module._load (internal/modules/cjs/loader.js:507:25)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (internal/modules/cjs/helpers.js:20:18)
at Object. (C:Sourcexxxxxxxxx_Controlnode_modulesajvlibajv.js:10:23)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
C:Sourcexxxxxxxxx_Controlxxx_Control.csproj(111,5): Error MSB3073: The command "node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js --env.prod" exited with code 1.
2>Build failed. Check the Output window for more details.
========== Build: 1 succeeded, 0 failed, 1 up-to-date, 0 skipped ==========
========== Publish: 0 succeeded, 1 failed, 0 skipped ==========
7) I'm supposed to copy the bins from binReleasenet472 correct? There are also some in the binReleasenet472win7-x86 directory.. I tried both for the heck of it... same thing...
Any ideas?
node.js angularjs asp.net-core
node.js angularjs asp.net-core
asked Jan 18 at 19:01
SledgeHammerSledgeHammer
3,64421132
3,64421132
I think, firstly you should resolve npm issues for keeping project alive. After that you could use normal publish. Also you create .net core application and use net472(it is full framework) build i think it is incorect. But problem on the server is not here, try to reinstall hosting boundle docs.microsoft.com/en-us/aspnet/core/host-and-deploy/iis/… then use iisreset and check your app
– itikhomi
Jan 18 at 19:40
Have you tried pushing an older working build?
– Kevin B
Jan 18 at 19:55
@itikhomi I tried setting it up on my dev PC and I get the same exact errors. Like I said in the post, the original guy that built it didn't know what he was doing and I do pretty much everything EXCEPT web development lol. I've got .net core and the hosting bundle installed. So something is messed up... does the web.config look right?
– SledgeHammer
Jan 18 at 20:09
@itikhomi Also, when I run the exe directly, it works there too...
– SledgeHammer
Jan 18 at 20:10
@itikhomi do you know what the $data module error is?
– SledgeHammer
Jan 18 at 20:10
|
show 2 more comments
I think, firstly you should resolve npm issues for keeping project alive. After that you could use normal publish. Also you create .net core application and use net472(it is full framework) build i think it is incorect. But problem on the server is not here, try to reinstall hosting boundle docs.microsoft.com/en-us/aspnet/core/host-and-deploy/iis/… then use iisreset and check your app
– itikhomi
Jan 18 at 19:40
Have you tried pushing an older working build?
– Kevin B
Jan 18 at 19:55
@itikhomi I tried setting it up on my dev PC and I get the same exact errors. Like I said in the post, the original guy that built it didn't know what he was doing and I do pretty much everything EXCEPT web development lol. I've got .net core and the hosting bundle installed. So something is messed up... does the web.config look right?
– SledgeHammer
Jan 18 at 20:09
@itikhomi Also, when I run the exe directly, it works there too...
– SledgeHammer
Jan 18 at 20:10
@itikhomi do you know what the $data module error is?
– SledgeHammer
Jan 18 at 20:10
I think, firstly you should resolve npm issues for keeping project alive. After that you could use normal publish. Also you create .net core application and use net472(it is full framework) build i think it is incorect. But problem on the server is not here, try to reinstall hosting boundle docs.microsoft.com/en-us/aspnet/core/host-and-deploy/iis/… then use iisreset and check your app
– itikhomi
Jan 18 at 19:40
I think, firstly you should resolve npm issues for keeping project alive. After that you could use normal publish. Also you create .net core application and use net472(it is full framework) build i think it is incorect. But problem on the server is not here, try to reinstall hosting boundle docs.microsoft.com/en-us/aspnet/core/host-and-deploy/iis/… then use iisreset and check your app
– itikhomi
Jan 18 at 19:40
Have you tried pushing an older working build?
– Kevin B
Jan 18 at 19:55
Have you tried pushing an older working build?
– Kevin B
Jan 18 at 19:55
@itikhomi I tried setting it up on my dev PC and I get the same exact errors. Like I said in the post, the original guy that built it didn't know what he was doing and I do pretty much everything EXCEPT web development lol. I've got .net core and the hosting bundle installed. So something is messed up... does the web.config look right?
– SledgeHammer
Jan 18 at 20:09
@itikhomi I tried setting it up on my dev PC and I get the same exact errors. Like I said in the post, the original guy that built it didn't know what he was doing and I do pretty much everything EXCEPT web development lol. I've got .net core and the hosting bundle installed. So something is messed up... does the web.config look right?
– SledgeHammer
Jan 18 at 20:09
@itikhomi Also, when I run the exe directly, it works there too...
– SledgeHammer
Jan 18 at 20:10
@itikhomi Also, when I run the exe directly, it works there too...
– SledgeHammer
Jan 18 at 20:10
@itikhomi do you know what the $data module error is?
– SledgeHammer
Jan 18 at 20:10
@itikhomi do you know what the $data module error is?
– SledgeHammer
Jan 18 at 20:10
|
show 2 more comments
1 Answer
1
active
oldest
votes
I ran into this recently, with a project that was initially netcoreapp, then had to be changed to net461 for the framework, due to dependencies. Hence the file used is an exe, not a DLL.
Removing all of the files in the deployed directory, and publishing again, got it working for me.
Problem is the publish doesn't work... get a Error : Cannot find module './$data' and a webpack exit status 1 error.
– SledgeHammer
Jan 18 at 21:04
Can you publish to another location at all? That is, not one where the app had existed previously. Or set the publish to remove existing files? Also, if you enable logging in the web.config you might get a bit more detail of the issue.
– Scott Hoffman
Jan 18 at 21:10
I'm trying to publish to a folder on my dev PC. Also tried to publish to zip, both give me the 2 errors even through everything builds and runs.
– SledgeHammer
Jan 18 at 22:00
Not sure if I overwrote the prod web.config by accident, but since I can't do a publish, I can't regenerate it. Ugh.
– SledgeHammer
Jan 18 at 22:01
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f54259991%2fwhy-is-iis-giving-me-a-502-5-error-on-asp-net-core-app%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
I ran into this recently, with a project that was initially netcoreapp, then had to be changed to net461 for the framework, due to dependencies. Hence the file used is an exe, not a DLL.
Removing all of the files in the deployed directory, and publishing again, got it working for me.
Problem is the publish doesn't work... get a Error : Cannot find module './$data' and a webpack exit status 1 error.
– SledgeHammer
Jan 18 at 21:04
Can you publish to another location at all? That is, not one where the app had existed previously. Or set the publish to remove existing files? Also, if you enable logging in the web.config you might get a bit more detail of the issue.
– Scott Hoffman
Jan 18 at 21:10
I'm trying to publish to a folder on my dev PC. Also tried to publish to zip, both give me the 2 errors even through everything builds and runs.
– SledgeHammer
Jan 18 at 22:00
Not sure if I overwrote the prod web.config by accident, but since I can't do a publish, I can't regenerate it. Ugh.
– SledgeHammer
Jan 18 at 22:01
add a comment |
I ran into this recently, with a project that was initially netcoreapp, then had to be changed to net461 for the framework, due to dependencies. Hence the file used is an exe, not a DLL.
Removing all of the files in the deployed directory, and publishing again, got it working for me.
Problem is the publish doesn't work... get a Error : Cannot find module './$data' and a webpack exit status 1 error.
– SledgeHammer
Jan 18 at 21:04
Can you publish to another location at all? That is, not one where the app had existed previously. Or set the publish to remove existing files? Also, if you enable logging in the web.config you might get a bit more detail of the issue.
– Scott Hoffman
Jan 18 at 21:10
I'm trying to publish to a folder on my dev PC. Also tried to publish to zip, both give me the 2 errors even through everything builds and runs.
– SledgeHammer
Jan 18 at 22:00
Not sure if I overwrote the prod web.config by accident, but since I can't do a publish, I can't regenerate it. Ugh.
– SledgeHammer
Jan 18 at 22:01
add a comment |
I ran into this recently, with a project that was initially netcoreapp, then had to be changed to net461 for the framework, due to dependencies. Hence the file used is an exe, not a DLL.
Removing all of the files in the deployed directory, and publishing again, got it working for me.
I ran into this recently, with a project that was initially netcoreapp, then had to be changed to net461 for the framework, due to dependencies. Hence the file used is an exe, not a DLL.
Removing all of the files in the deployed directory, and publishing again, got it working for me.
answered Jan 18 at 21:03
Scott HoffmanScott Hoffman
460615
460615
Problem is the publish doesn't work... get a Error : Cannot find module './$data' and a webpack exit status 1 error.
– SledgeHammer
Jan 18 at 21:04
Can you publish to another location at all? That is, not one where the app had existed previously. Or set the publish to remove existing files? Also, if you enable logging in the web.config you might get a bit more detail of the issue.
– Scott Hoffman
Jan 18 at 21:10
I'm trying to publish to a folder on my dev PC. Also tried to publish to zip, both give me the 2 errors even through everything builds and runs.
– SledgeHammer
Jan 18 at 22:00
Not sure if I overwrote the prod web.config by accident, but since I can't do a publish, I can't regenerate it. Ugh.
– SledgeHammer
Jan 18 at 22:01
add a comment |
Problem is the publish doesn't work... get a Error : Cannot find module './$data' and a webpack exit status 1 error.
– SledgeHammer
Jan 18 at 21:04
Can you publish to another location at all? That is, not one where the app had existed previously. Or set the publish to remove existing files? Also, if you enable logging in the web.config you might get a bit more detail of the issue.
– Scott Hoffman
Jan 18 at 21:10
I'm trying to publish to a folder on my dev PC. Also tried to publish to zip, both give me the 2 errors even through everything builds and runs.
– SledgeHammer
Jan 18 at 22:00
Not sure if I overwrote the prod web.config by accident, but since I can't do a publish, I can't regenerate it. Ugh.
– SledgeHammer
Jan 18 at 22:01
Problem is the publish doesn't work... get a Error : Cannot find module './$data' and a webpack exit status 1 error.
– SledgeHammer
Jan 18 at 21:04
Problem is the publish doesn't work... get a Error : Cannot find module './$data' and a webpack exit status 1 error.
– SledgeHammer
Jan 18 at 21:04
Can you publish to another location at all? That is, not one where the app had existed previously. Or set the publish to remove existing files? Also, if you enable logging in the web.config you might get a bit more detail of the issue.
– Scott Hoffman
Jan 18 at 21:10
Can you publish to another location at all? That is, not one where the app had existed previously. Or set the publish to remove existing files? Also, if you enable logging in the web.config you might get a bit more detail of the issue.
– Scott Hoffman
Jan 18 at 21:10
I'm trying to publish to a folder on my dev PC. Also tried to publish to zip, both give me the 2 errors even through everything builds and runs.
– SledgeHammer
Jan 18 at 22:00
I'm trying to publish to a folder on my dev PC. Also tried to publish to zip, both give me the 2 errors even through everything builds and runs.
– SledgeHammer
Jan 18 at 22:00
Not sure if I overwrote the prod web.config by accident, but since I can't do a publish, I can't regenerate it. Ugh.
– SledgeHammer
Jan 18 at 22:01
Not sure if I overwrote the prod web.config by accident, but since I can't do a publish, I can't regenerate it. Ugh.
– SledgeHammer
Jan 18 at 22:01
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f54259991%2fwhy-is-iis-giving-me-a-502-5-error-on-asp-net-core-app%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
I think, firstly you should resolve npm issues for keeping project alive. After that you could use normal publish. Also you create .net core application and use net472(it is full framework) build i think it is incorect. But problem on the server is not here, try to reinstall hosting boundle docs.microsoft.com/en-us/aspnet/core/host-and-deploy/iis/… then use iisreset and check your app
– itikhomi
Jan 18 at 19:40
Have you tried pushing an older working build?
– Kevin B
Jan 18 at 19:55
@itikhomi I tried setting it up on my dev PC and I get the same exact errors. Like I said in the post, the original guy that built it didn't know what he was doing and I do pretty much everything EXCEPT web development lol. I've got .net core and the hosting bundle installed. So something is messed up... does the web.config look right?
– SledgeHammer
Jan 18 at 20:09
@itikhomi Also, when I run the exe directly, it works there too...
– SledgeHammer
Jan 18 at 20:10
@itikhomi do you know what the $data module error is?
– SledgeHammer
Jan 18 at 20:10