Module 3 - Azure - Web Apps
Module 3 - 微软云 Azure - Web Apps
1. Create new Web application in the Azure Portal
Azure Portal -> App Services -> Add -> Web App。
在这个过程中,Azure Portal 会要求你创建一个 Resource Group(资源组),在资源组里面,你会看到 App Service, App Service Plan, Application Insights(Optional)。
2. Deploy your application from Visual Studio to Azure by using deployment slot
首先在个人电脑上安装 Microsfot Visual Studio Community 2019;
然后按照教程 在Azure中创建ASP.net Core Web App 一步一步操作即可。
完成之后,在 Azure Portal 选中你所创建的 App Service,再选择 Deployment Slot,再选择 Add Slot,即可创建一个Slot(插槽)。
比如说,你可以为 Dev、SIT、UAT、PreProd(Staging)、PROD、BCP等分别创建不同的插槽。插槽的妙处在于你可以在类似生产的环境进行验证之后,然后对 Staging 和 Production 的内容进行交换(Swap)。
Add Slot

3. Move you project to Version Control system (Git or TFS) and set up Continuous Deployment process from your VC system to Azure
我选择的仓库托管中心是 GitHub,所以首先确保在 github.com 拥有自己的账号。
并且在个人电脑上安装 Git 的客户端。确保可以在本地磁盘打开 Git Bash。
Git 中 SSH key 生成步骤 按照该文章的说明,运行 ssh-keygen -t rsa -C "youremail@example.com" 在 ~/.ssh 目录下生成私钥 id_rsa 和公钥 id_rsa.pub,
并且需要把公钥的内容配置到 GitHub 网站。
在 GitHub 上新建一个仓库,名字和我的 Visual Studio 的项目的名字一致 myFirstAzureWebApp。
然后在本地磁盘的 myFirstAzureWebApp 项目文件夹下打开 Git Bash,
通过以下命令建立 本地库 和 远程库 之间的联系。
echo "# myFirstAzureWebApp" >> README.md
git init
git status
git add --all
git commit -m "first commit" -a
git remote add origin git@github.com:kingmax-chan/myFirstAzureWebApp.git
git push -u origin master
以后的新增开发一般通过 git status, git add, git commit, git push 等命令,就可以满足基本需求。
在 GitHub 授权给 Azure App Service。

通过 Azure Portal -> App Services -> Deployment Center -> Source Control -> Build Provider -> Configure -> Summary,
可以建立 GitHub 的特定代码库 到 Azure的特定App Service 或 Web App 之间的联系。
建立本地库--》远程库--》Azure Web Serice 的联系之后,以后每次在本地进行 git push 操作,都会向远程库推送,进而触发Azure中对应的App Service的 Build 和 Deploy 的操作。
而这一系列的动作,除了 git push,都是自动进行的。
Deployment Center ---> Source Control

Deployment Center ---> Build Provider

Deployment Center ---> Configure

Deployment Center ---> Summary

Module 3 - Azure - Web Apps的更多相关文章
- 免费电子书:Azure Web Apps开发者入门
(此文章同时发表在本人微信公众号"dotNET每日精华文章",欢迎右边二维码来关注.) 题记:之前介绍过微软正在逐步出版一个名为Azure Essential的入门系列教程,最近刚 ...
- Windows Azure Web Site (7) Web Site配置
<Windows Azure Platform 系列文章目录> 在上一章内容中,我们已经部署了Azure WebSite.我们可以在Web Site配置页面进行配置.如下图: 另外,我们还 ...
- 如何修改Windows Azure Web App的时区
Windows Azure的时区默认使用UTC,如果是VM可以直接修改,但Azure Web Apps的隔离性导致我们无法进行设置.应用系统使用DateTime.Now的地方很多,不可能做出一一修改. ...
- 尝鲜一试,Azure静态网站应用服务(Azure Static Web Apps) 免费预览,协同Github自动发布静态SPA
背景 最近在浏览微软的文档的时候发现,微软喜欢用Hugo这个文档框架,有些技术产品的文档页面就用Hugo来做的,同时搭配Github + Azure Static Web Apps Service这个 ...
- Microsoft Azure Web Sites应用与实践【2】—— 通过本地IIS 远程管理Microsoft Azure Web Site
Microsoft Azure Web Sites应用与实践 系列: [1]—— 打造你的第一个Microsoft Azure Website [2]—— 通过本地IIS 远程管理Microsoft ...
- Windows Azure Web Site (1) 用户手册
<Windows Azure Platform 系列文章目录> 下载地址: Web Apps用户手册
- Building Modern Web Apps-构建现代的 Web 应用程序
Building Modern Web Apps-构建现代的 Web 应用程序 视频长度:1 小时左右 视频作者:Scott Hunter 和 Scott Hanselman 视频背景:Visual ...
- Java create azure web app
create a certificate <java-install-dir>/bin/ keytool -genkey -alias <keystore-id> -keyst ...
- Microsoft Azure Web Sites应用与实践【4】—— Microsoft Azure网站的“后门”
Microsoft Azure Web Sites应用与实践 系列: [1]—— 打造你的第一个Microsoft Azure Website [2]—— 通过本地IIS 远程管理Microsoft ...
随机推荐
- Xshell 连接 vmware中的CentOS 7
参考内容: Xshell 连接 CentOS 7 与 Ubuntu Server,http://www.linuxidc.com/Linux/2017-03/141333.ht ...
- Tornado之异步authenticated
authenticated是tornado自带的登录验证装饰器,它的实现比较简单,验证比较简易,无法做到真正意义的前后端分离并且是同步的方式,所以这里我对它进行了重写,以适应异步JWT方式的登录验证. ...
- spring-aop 的注释用法
一.书写增强有效代码 //切面注释@Aspectpublic class errorLogger { private static Logger logger = Logger.getLogger(e ...
- Java开发人员必须掌握的Linux命令-学以致用(5)
================================================= 人工智能教程.零基础!通俗易懂!风趣幽默!大家可以看看是否对自己有帮助! 点击查看高清无码教程 == ...
- helm-chart7,调试与hook
调试 几个命令可以帮助进行调试 helm lint 首选工具,返回错误和警告信息. helm install --dry-run --debug:服务器会渲染你的模板,然后返回结果清单文件. helm ...
- C_使用clock()函数获取程序执行时间
clock():捕捉从程序开始运行到clock()被调用时所耗费的时间.这个时间单位是clock tick ,即“时钟打点”. 常数CLK_TCK:机器时钟每秒所走的时钟打点数. #include & ...
- select应用
服务端源码 #!/usr/bin/env python3 # -*- coding: utf-8 -*- """ @author: zengchunyun "& ...
- [LeetCode] Max Increase to Keep City Skyline 保持城市天际线的最大增高
In a 2 dimensional array grid, each value grid[i][j] represents the height of a building located the ...
- [LeetCode] Encode N-ary Tree to Binary Tree 将N叉树编码为二叉树
Design an algorithm to encode an N-ary tree into a binary tree and decode the binary tree to get the ...
- linux中安装python+selenium+chrome