前段时间帮朋友写了一个网站,现在做一个记录。

.Net Core 安装:

 curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg
sudo mv microsoft.gpg /etc/apt/trusted.gpg.d/microsoft.gpg
sudo sh -c 'echo "deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-trusty-prod trusty main" > /etc/apt/sources.list.d/dotnetdev.list'
sudo apt-get update
sudo apt-get install dotnet-sdk-2.0.

参考自:https://www.microsoft.com/net/core#linuxubuntu

Nginx安装:

 sudo apt-get install update
sudo apt-get install nginx

参考字:http://blog.csdn.net/woshihaiyong168/article/details/53927308

MySql安装:

 sudo apt-get install mysql-server

其中输入两次来设置Root密码。

然后需要配置远程连接,请参考:http://www.cnblogs.com/BTMaster/p/4035402.html

Supervisor安装:

 sudo apt-get install supervisor  

参考自:http://blog.csdn.net/github_37730997/article/details/60582525

以上,安装内容就完成了。

配置:

Supervisor配置:

参考自:http://blog.csdn.net/shengzhu1/article/details/54348371

 [program:Project_Name]
command=/usr/bin/dotnet ???.dll
directory=Project_Publish_location
autostart=true
autorestart=true
stderr_logfile=/var/log/Error.err.log
stdout_logfile=/var/log/Out.out.log
user=root
stopsignal=INT

.net core 编译:

 dotnet publish

Supervisor 启动和停止:

 sudo service supervisor start
sudo service supervisor stop

Nginx配置:

         location / {
proxy_pass http://localhost:5000;
proxy_http_version 1.1;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection keep-alive;
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}

阿里云Ubuntu 14.04 + Nginx + .net core + MySql的更多相关文章

  1. 阿里云Ubuntu 14.04 + Nginx + let's encrypt 搭建https访问

    参考页面: https://certbot.eff.org/#ubuntutrusty-nginx http://bbs.qcloud.com/thread-12059-1-1.html http:/ ...

  2. 在阿里云Ubuntu 14.04 Linux服务器上安装docker

    参考 How To Install and Use Docker: Getting Started 这篇最靠谱的文档在阿里云 Ubuntu  14.04 服务器上成功安装 docker . ---- ...

  3. 阿里云 ubuntu 14.04 模板上安装 docker

    ubuntu 14.04 的内核是 3.13 ,所以内核不用升级. 安装过程例如以下: # apt-get update # apt-get install apt-transport-https # ...

  4. 阿里云 Ubuntu 14.04 安装mysql 5.6

    1. 升级apt-get apt-get update 如果出现 : 说明没有你不是root用户,则需要用sudo命令 sudo apt-get update 下面出现权限问题都可以参照这个方法. 2 ...

  5. 在阿里云Ubuntu 14.04.5 LTS下安装nethogs0.8.5

    由于默认安装的nethogs不能使用,提示:Creating socket failed while establishing local IP - are you root? 搜索资料后检查当前版本 ...

  6. Laravel项目部署上线(阿里云 Ubuntu 16.04)

    第一次尝试把本地的项目上线,   购买了某云的轻量应用服务器, 镜像为Ubuntu 16.04  直接运行 apt-get install nginx 出错   根据提示运行 apt-get upda ...

  7. 阿里云ubuntu 16.04搭建odoo11服务器

    ubuntu 16.04 具体如何搭建odoo11网站的具体步骤可以参考这一篇文章 按上面的文章配置环境后,自己网站的启动具体步骤如下: 1.登录阿里云 [远程连接],进入命令行界面1 2.cd到目录 ...

  8. 阿里云ubuntu 16.04 搭建pptpd 第二版

    前言:1.我常用的服务器在国内,但我又有某方面的需求,所以想要搭建一个pptpd的服务器    2.但我又不常用,所以感觉阿里云包年包月的不划算,所以准备采用阿里云按量付费的实例来搭建pptpd,并形 ...

  9. 阿里云Ubuntu 18.04安装图形界面

    #!/bin/bash #更新软件库 apt-get update #升级软件 apt-get upgrade #安装ubuntu桌面系统 apt-get install ubuntu-desktop

随机推荐

  1. canvas二三事之签名板与视频绘制

    今天,不知道怎么的就点开了语雀,然后就看到了<HTML5 Canvas 教程>,开始了canvas的研究(学习)之旅. 首先,想到的第一个东西就是签名板,上代码: <canvas i ...

  2. [转]Ribbon界面介绍(1)

    小弟最近在学习VS2010中Ribbon界面的介绍,相比与C#的界面设计的强大,C++的界面实在太难做了,但没办法,项目需求,又不得不做,遍查网络上的资料,发现有用的基本上就是MSDN的帮助,又是全英 ...

  3. svn .externals 属性

    问:如下自定下载关联模块呢? 答:第一步: 编辑svn.externals文本,如下所示 dir/moduel_name URL/module dir/moduel_name URL/module 第 ...

  4. nvme ioctl解密

    对于Nvme SSD,我们有的时候会用到ioctl系统调用,该调用的流程是怎样的呢? 首先,在注册nvme设备的时候,会初始化该设备的注册了file operations: static const ...

  5. 排列组合:01转换法之lua实现

    c++ 版连接 https://blog.csdn.net/canguanxihu/article/details/46363375 因为项目用的是lua脚本,看了C++版后自己写了一个lua版本的, ...

  6. Maven插件的简介,安装及在eclipse中配置

    1.Maven简介 1.Maven介绍 Maven是一个基于项目对象模型(POM:project object model)的概念的纯java开发的开源的项目管理工具.Maven把我们的工程抽像一个对 ...

  7. Python编程Message: CGI script is not executable ('/cgi-bin/xxxxx.py')

    Message: CGI script is not executable ('/cgi-bin/xxxxx.py'). 今天在练习python服务器端编程时遇到了这个错误,查阅一番最终解决 系统为l ...

  8. 面试被问到SPI总结

    SPI驱动框架 枚举过程 drivers/spi/spi.c: spi_register_board_info /* 对于每一个spi_master,调用spi_match_master_to_boa ...

  9. celery知多少

    Celery 1.什么是Celery Celery是一个简单.灵活且可靠的,处理大量消息的分布式系统 专注于实时处理的异步任务队列 同时也支持任务调度 Celery架构 Celery的架构由三部分组成 ...

  10. 课程 python 文件操作复习

    # 文件处理 # 打开文件 #open('路径','打开方式','指定编码方式') # 打开方式 r w a r+ w+ a+ b #r+ 打开文件直接写 和读完再写 # 编码方式 —— utf-8 ...