Tag: azure

如果将节点应用程序埋在回购目录中,如何将节点应用程序部署到azure色

我正尝试通过“remote git repo”方法将项目部署到Azure。 但是在我的回购中,实际的节点应用程序只有几个目录。因此,当推送回购时,Azure不会执行任何操作。 有没有一些方法来configurationazure网站从埋在回购目录中运行?

Web Servicesangular色与Cloud Services / Node.js中的工作者angular色

Webangular色(Node.js)和工作者angular色(Node.js)有什么区别? 两者都可以在80端口上运行。 两者的代码是相同的。 我知道Webangular色在IIS上运行,但为什么我需要IIS作为代理,如果Node.js有他自己的WebServer?

将节点本地模块部署到Azure WebSites

我正在尝试将以下示例节点应用程序部署到Azure网站: var http = require('http'); var port = process.env.port || 1337; http.createServer(function (req, res) { res.writeHead(200, { 'Content-Type': 'text/html' }); try { var canvasModule = require('canvas'), canvas = new canvasModule(200, 200), ctx = canvas.getContext('2d'); ctx.rotate(0.5); ctx.font = '30px Impact'; var message = "Hello World"; ctx.fillText(message, 40, 40); ctx.strokeRect(30, 5, 160, 50); res.end('<html><img src="' + canvas.toDataURL() […]

在Azure中为SVG和字体显示NodeJS web.config

我在快速网站中遇到了问题,该网站使用SVG和其他文件,如字体。 在本地运行应用程序时没有任何问题,但是一旦在Azure上部署,SVG和字体就不会再出现。 在项目根目录下创build一个web.config文件: <?xml version="1.0" encoding="utf-8"?> <configuration> <system.webServer> <staticContent> <mimeMap fileExtension=".svg" mimeType="image/svg+xml" /> <mimeMap fileExtension=".woff" mimeType="application/x-woff" /> <mimeMap fileExtension=".ttf" mimeType="application/x-woff" /> </staticContent> </system.webServer> </configuration> 也使用这个解决scheme:( Windows Azure中的Svgs和其他MIMEtypes ) 这两个解决scheme现在允许加载SVG文件,但网页不再加载。 (HTTP 500) 它似乎覆盖dynamic内容的configuration。 如何configurationdynamic内容,使应用程序再次工作?

无法在Azure上部署node.js项目,Bcrypt是罪魁祸首

我目前正在部署在Azure上的node.js项目上工作。 我刚刚使用bcrypt添encryption码encryption。 我的testing计算机上的一切正常,但是当我在Azure上部署时,部署失败,我收到了以下消息: node-gyp rebuild C:\DWASFiles\Sites\invata\VirtualDirectory0\site\wwwroot\node_modules\bcrypt>node "D:\Program Files (x86)\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node- gyp\bin\node-gyp.js" rebuild gypnpm ERR! bcrypt@0.7.6 install: `node-gyp rebuild` npm ERR! `cmd "/c" "node-gyp rebuild"` failed with 1 An error has occurred during web site deployment. npm ERR! npm ERR! Failed at the bcrypt@0.7.6 install script. BCrypt安装有点棘手,因为它需要下载和安装openSSL。 那么是否有可能在Azure上部署这样的模块,或者是没有希望的? 谢谢,Stéphane

随机失败的Azure主题/订阅请求

我正在使用Azure的服务总线(主题/订阅专门)来回发送消息。 看似随意的,当发送消息到主题时,消息似乎正在消失,没有错误抛出。 如果我查看Azurepipe理门户中有关该主题的图表,可以看到一部分邮件失败。 2个问题: 1 – 什么可以导致请求失败的文档在哪里? 2 – 如何logging这些请求,以便我可以看到错误?

使用Node.js Passport的Azure AD身份validation返回“此API版本不支持”

我目前正在开发一个使用Azure AD进行身份validation的应用程序。 应用程序应支持多个租户,但只有预定义的租户列表才能访问应用程序。 使用passport-azure-ad库,我将OIDCStrategy添加到护照中,如下所示: // Use Azure AD OAuth2 strategy. passport.use('strategyName', new OIDCStrategy({ callbackURL: 'http://localhost:8080/oauth2/strategyName/callback', clientID: 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx', clientSecret: 'secret', identityMetadata: 'https://login.microsoftonline.com/test.mydomain.com/v2.0/.well-known/openid-configuration', responseType: 'id_token', responseMode: 'form_post', skipUserProfile: true }, function (iss, sub, profile, accessToken, refreshToken, done) { console.log(profile); done(); })); 在我的路线上,我有以下设置: // Authentication endpoint. router.get('/strategyName', app.passport.authenticate('strategyName')); router.post('/strategyName/callback', function (req, res, next) { app.passport.authenticate('strategyName', function (err, account) […]

如何使用Azure API格式执行查询:用户身份validation

我想获得JSON数据作为解释在restAPI文档https://dev.applicationinsights.io/documentation/overview customEvents | where customDimensions.teamId == '8bcb0466-8227-4de4-b001-b70381b9cd04' 由于其他api的限制为每分钟15个呼叫,每天1500个,因为文档https://dev.applicationinsights.io/documentation/Authorization/Rate-limits说使用Azure API和Azure Active Directory,但没有可用的示例那。 我想在节点js中执行它,但是没有find相同的sdk。 对于AD身份validation,我使用了assport-azure-ad库。

Bower未能在Azure上部署

我正在使用Azure部署Node.js Web应用程序。 我已经把Github作为我的部署库,并且像Jay Harris的网页中提到的那样设置了deploy.sh:http://www.cptloadtest.com/2013/12/03/Git-And-Grunt-Deploy-To- Windows的Azure.aspx 我的应用程序依赖于bower,但是当它试图部署时,我得到一个bower失败的错误。 以下是Azure日志的输出: npm http 304 https://registry.npmjs.org/delayed-stream/0.0.5 npm http 304 https://registry.npmjs.org/amdefine C:\DWASFiles\Sites\videogelpub\AppData\npm\bower -> C:\DWASFiles\Sites\videogelpub\AppData\npm\node_modules\bower\bin\bower bower@1.3.1 C:\DWASFiles\Sites\videogelpub\AppData\npm\node_modules\bower ├── is-root@0.1.0 ├── junk@0.2.2 error: could not lock config file d:/home/.gitconfig: Permission denied ├── stringify-object@0.2.0 ├── abbrev@1.0.4 ├── chmodr@0.1.0 ├── which@1.0.5 ├── osenv@0.0.3 ├── archy@0.0.2 ├── graceful-fs@2.0.3 ├── rimraf@2.2.6 ├── open@0.0.4 ├── bower-endpoint-parser@0.2.1 ├── lru-cache@2.5.0 […]

Active Directory集成问题Nodejs

我是新的Node js,我想用Azure Active Directory进行身份validation。 我下载的节点和安装的NPM如上所述 npm install express npm install ejs npm install ejs-locals npm install restify npm install mongoose npm install bunyan npm install assert-plus npm install passport npm install passport-azure-ad 之后按照文档,我遵循第3步:设置您的应用程序使用passport-node-js策略 这里是config.js exports.creds = { returnURL: 'https://hpe.onmicrosoft.com/8d332647-xxxx-4xxc-8xx-11776XXXXX', identityMetadata: 'https://login.microsoftonline.com', // For using Microsoft you should never need to change this. clientID: '22XXXX9-b5fa-XXXXb-bc7a-XXXXXXXa92a', clientSecret: […]