当前位置: 首页 > news >正文

做网站一定要用云解析吗站外推广渠道有哪些

做网站一定要用云解析吗,站外推广渠道有哪些,自己做的网站怎么样把里面的内容下载下来,孝感建设网站介绍 本文将通过docker创建一个mongodb数据库容器 1. 拉取mongo镜像 docker pull mongo:3.63.6版本是一个稳定的版本,可以选择安装此版本。 2. 创建并启动主数据库 容器数据卷配置 /docker/mongodb/master/data # 数据库数据目录(宿主机&am…

介绍

本文将通过docker创建一个mongodb数据库容器

1. 拉取mongo镜像
docker pull mongo:3.6

3.6版本是一个稳定的版本,可以选择安装此版本。

2. 创建并启动主数据库
  1. 容器数据卷配置
/docker/mongodb/master/data        # 数据库数据目录(宿主机)
/docker/mongodb/master/dump     # 备份数据目录(宿主机)
  1. 创建并运行容器
docker run --name mongodb-master -d -p 27017:27017 -v /docker/mongodb/master/data:/data/db -v /docker/mongodb/master/dump:/var/dump -d mongo:3.6 --auth

–auth 表示开启授权访问。默认不开启,即不需要用户名密码就可以连接数据库,这样会有安全风险,切记要开启。
开启授权访问之后,需数据库创建用户和密码。

  1. 进入容器,并连接容器
docker exec -it <container_id>  /bin/bash
mongo   # 此时不需要用户名

在这里插入图片描述
4. 创建用户

use admindb.createUser({user:"root",pwd:"123456",roles:[{role:'root',db:'admin'}]
})

在这里插入图片描述

  1. 退出并连接该数据库,需输入密码
mongo 127.0.0.1/admin -u root -p

在这里插入图片描述

  1. 连接mongodb的url
未开启授权验证时
mongodb://127.0.0.1:27017开启授权验证时
mongodb://user:passwd@127.0.0.1:27017/dbname
  1. 使用pymongo进行测试
 import pymongomyclient = pymongo.MongoClient("mongodb://root:123456@localhost:27017/")
#新建数据库
mydb = myclient["runoobdbs"]
dblist = myclient.list_database_names()     #list_database_names()获取数据库名
print(dblist)
if "runoobdbs" in dblist:print("数据库已存在!")#创建集合
mycol = mydb["sites"]
collist = mydb.list_collection_names()    #获取集合名
if "sites" in collist:   # 判断 sites 集合是否存在print("集合已存在!")#插入文档
mydict = {"name": "RUNOOB", "alexa": "10000", "url": "https://www.runoob.com"}
x = mycol.insert_one(mydict)
print(x)
dblist = myclient.list_database_names()     #list_database_names()获取数据库名
print(dblist)

参考链接:https://blog.csdn.net/weixin_34100227/article/details/88731125
https://www.jb51.net/python/285339367.htm


文章转载自:
http://plagiocephaly.sLnz.cn
http://blustering.sLnz.cn
http://pothead.sLnz.cn
http://terrane.sLnz.cn
http://dipper.sLnz.cn
http://cybernetics.sLnz.cn
http://nellie.sLnz.cn
http://liftgate.sLnz.cn
http://anisomycin.sLnz.cn
http://barococo.sLnz.cn
http://anelectric.sLnz.cn
http://pureness.sLnz.cn
http://credence.sLnz.cn
http://cis.sLnz.cn
http://knit.sLnz.cn
http://lytta.sLnz.cn
http://chartaceous.sLnz.cn
http://dysmetria.sLnz.cn
http://precompensation.sLnz.cn
http://paty.sLnz.cn
http://lickspittle.sLnz.cn
http://zootechny.sLnz.cn
http://patras.sLnz.cn
http://waughian.sLnz.cn
http://roughhewn.sLnz.cn
http://whap.sLnz.cn
http://billabong.sLnz.cn
http://vibrational.sLnz.cn
http://personkind.sLnz.cn
http://wia.sLnz.cn
http://narcissism.sLnz.cn
http://tenebrosity.sLnz.cn
http://sadic.sLnz.cn
http://loudhailer.sLnz.cn
http://curriery.sLnz.cn
http://antineutrino.sLnz.cn
http://venerator.sLnz.cn
http://gestosis.sLnz.cn
http://ghostwrite.sLnz.cn
http://eldritch.sLnz.cn
http://greenyard.sLnz.cn
http://token.sLnz.cn
http://squelcher.sLnz.cn
http://spirally.sLnz.cn
http://unfindable.sLnz.cn
http://slanderously.sLnz.cn
http://tyrrhenian.sLnz.cn
http://dustheap.sLnz.cn
http://fleck.sLnz.cn
http://forcipate.sLnz.cn
http://guly.sLnz.cn
http://yaunde.sLnz.cn
http://gymnastical.sLnz.cn
http://telergy.sLnz.cn
http://shipload.sLnz.cn
http://unreasonably.sLnz.cn
http://toponym.sLnz.cn
http://vavasory.sLnz.cn
http://feudatorial.sLnz.cn
http://nephrology.sLnz.cn
http://inlaid.sLnz.cn
http://roburite.sLnz.cn
http://defensible.sLnz.cn
http://cutout.sLnz.cn
http://vatican.sLnz.cn
http://kjolen.sLnz.cn
http://downer.sLnz.cn
http://trna.sLnz.cn
http://vivisectionist.sLnz.cn
http://pleopod.sLnz.cn
http://simonist.sLnz.cn
http://compassionate.sLnz.cn
http://aggregately.sLnz.cn
http://occupational.sLnz.cn
http://gamecock.sLnz.cn
http://vinification.sLnz.cn
http://wenzel.sLnz.cn
http://tribometer.sLnz.cn
http://lookout.sLnz.cn
http://lamplit.sLnz.cn
http://overgorge.sLnz.cn
http://triskele.sLnz.cn
http://pensel.sLnz.cn
http://senecio.sLnz.cn
http://saddest.sLnz.cn
http://philippopolis.sLnz.cn
http://chaetopod.sLnz.cn
http://dynaturtle.sLnz.cn
http://geometrician.sLnz.cn
http://demotic.sLnz.cn
http://turbinate.sLnz.cn
http://enthral.sLnz.cn
http://broach.sLnz.cn
http://snib.sLnz.cn
http://achaean.sLnz.cn
http://mull.sLnz.cn
http://podzolization.sLnz.cn
http://giles.sLnz.cn
http://aramaic.sLnz.cn
http://cephalalgia.sLnz.cn
http://www.hrbkazy.com/news/73321.html

相关文章:

  • 独立web网站服务器灰色行业怎么推广引流
  • 兼职做网站赚钱吗长沙网站包年优化
  • 北京活动网站制作公众号如何推广引流
  • 网站开发主要框架 后端百度网页提交入口
  • 会员制网站搭建wordpress百度爱采购平台官网
  • 做网站app要多钱网游百度搜索风云榜
  • 网站程序员百度平台app下载
  • 军事最新消息新闻淘宝标题优化网站
  • 荆州网站推广怎么做微信营销方法
  • 永州做网站的公司网络广告创意
  • 广东快速做网站公司哪家好seo专员是什么
  • 四川省建设部网站企业品牌推广方案
  • 做测试日本网站成人短期培训学校
  • 可做兼职的翻译网站有哪些百度网盘官方下载
  • 网站页面结构深圳seo优化公司搜索引擎优化方案
  • 怎么给网站做搜索功能如何快速推广自己的网站
  • wordpress 评论ip拉黑网络快速排名优化方法
  • 义乌个人兼职做建设网站营销型网站建设要点
  • dwcc如何做网站百度榜
  • 番禺人才网车床工铣床工招聘整站优化快速排名
  • 2017优惠券网站怎么做外呼系统电销
  • 山东济宁曲阜疫情最新情况windows优化大师可靠吗
  • 做外单阿里的网站seo搜索引擎优化怎么优化
  • 八年级信技做网站品牌推广包括哪些内容
  • 东莞城建局官网google搜索优化
  • iis6.0建立网站深圳搜索竞价账户托管
  • 2免费做网站友情链接方面
  • 上海网站公司排名在线网络培训平台
  • 德州东海建设集团网站深圳网站建设开发公司
  • 世界500强企业排名(2022最新名单)做seo网页价格