简体   繁体   English

通过github将AngularJS应用程序部署到Azure无法正常工作

[英]Deploying AngularJS app to Azure via github not working

Long story short, we have an old, ill-maintained web app hosted in a google cloud account we don't have access to anymore, so we want to move it over to our company Azure account. 长话短说,我们有一个旧的,维护欠佳的Web应用程序托管在我们不再有权访问的Google云帐户中,因此我们希望将其移至我们的公司Azure帐户。

In Azure, we created a new web app, and set it to pull from our repo. 在Azure中,我们创建了一个新的Web应用程序,并将其设置为从我们的存储库中提取。 First build failed, but that's because it was using a really old Kudu deployment script. 首次构建失败,但这是因为它使用的是非常古老的Kudu部署脚本。 So I generated a new one (using azure-cli) and pushed the new script. 因此,我生成了一个新脚本(使用azure-cli)并推送了新脚本。 In Azure, the build succeeded now, but when I go to the url for the site, nothing is there. 在Azure中,构建现在成功了,但是当我转到该站点的url时,什么都没有。 As far as I can tell, the app is never starting. 据我所知,该应用程序从未启动。

Here's all of the information that I could think of that might be relevant. 这是我可能想到的所有相关信息。 I don't fully understand all of the gruntfile stuff (I just know I type 'grunt serve' to work on the app locally :P), so I'm not sure if that's what I'm missing or what. 我不完全理解gruntfile的所有内容(我只知道键入'grunt serve'才能在本地应用程序:P上工作),所以我不确定这是我所缺少的还是什么。 If there's any other info needed, just let me know and I can add it. 如果需要其他任何信息,请告诉我,然后我可以添加它。

Thanks for any help! 谢谢你的帮助!

Please consider using HTML <base> element to specify the base URL for all relative URLs contained within a document. 请考虑使用HTML <base> element为文档中包含的所有相对URL指定基本URL。

In this case, you can specify a base URL in index.html like below: 在这种情况下,您可以在index.html指定基本网址,如下所示:

<head>
    <base href="/app/">
</head>

Also, if you don't want type /app/index.html in the URL to visit your site, you cloud add this to Default documents under Application settings menu in the Azure portal . 另外,如果您不想在URL中键入/app/index.html来访问您的网站,则可以将其添加到Azure门户中“ 应用程序设置”菜单下的“ 默认文档 ”中。

在此处输入图片说明

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 将两个github存储库部署到单个Azure Web应用程序 - Deploying two github repositories to single azure web app 通过FTP将Node.js应用程序部署到Azure不起作用 - deploying nodejs app to Azure via FTP does not work 通过GitHub部署时,Express 4应用程序在Azure中不起作用 - Express 4 app doesn't work in Azure when deployed via GitHub 使用 Github Actions 将 Angular 应用程序部署到 Azure 失败。 找不到 package.json - Deploying angular app to Azure with Github Actions failed. package.json not found 部署 AngularJS 和 NodeJS 应用程序的建议 - Suggestions for deploying AngularJS and NodeJS app 在Azure Functions上部署节点应用程序 - Deploying a Node app on Azure Functions 通过持续集成将NodeJS Express部署到Azure Web应用程序,出现EADDRINUSE错误 - Deploying NodeJS Express to Azure web app via continuous integration, get EADDRINUSE error 如何通过appveyor(从github中拉出)将node.js应用程序部署到azure? - How can a node.js app be deployed to azure via appveyor (pulled from github)? 在部署Angular 2项目时,Azure持续部署失败了Github - Azure Continuous deployment failed with Github when deploying an Angular 2 project 在Windows Azure上部署节点/ Express应用程序时出错 - Error deploying a node/Express app on Windows Azure
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM