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

国外网站推广建站推广

国外网站推广,建站推广,wordpress 侧边栏,怎么做用来表白的网站文章目录 题目要求:一、创建文档,编写Dockerfile文件可以将harbor仓库去启动先起来 二、运行Dockerfile,构建nginx镜像三、推送导私有仓库,也就是我们的harbor仓库 题目要求: 编写Dockerfile制作Web应用系统nginx镜像…

文章目录

  • 题目要求:
  • 一、创建文档,编写Dockerfile文件
    • 可以将harbor仓库去启动先起来
  • 二、运行Dockerfile,构建nginx镜像
  • 三、推送导私有仓库,也就是我们的harbor仓库


题目要求:

编写Dockerfile制作Web应用系统nginx镜像,生成镜像nginx:v1.1,并推送其到私有仓库。具体要求如下:

  1. 基于centos基础镜像;
  2. 指定作者信息;
  3. 安装nginx服务,将提供的dest目录(提供默认主页index.html)传到镜像内,并将dest目录内的前端文件复制到nginx的工作目录;
  4. 暴露80端口;
  5. 设置服务自启动。
  6. 验证镜像。

一、创建文档,编写Dockerfile文件

1、创建文档来存放本次需要写入的东西
[root@redhat ~]# mkdir -p dockertest
[root@redhat ~]# 
[root@redhat ~]# cd dockertest/
[root@redhat dockertest]# 
[root@redhat dockertest]# mkidr test1
[root@redhat dockertest]# cd test1/
2、编写一个html的前端文件,内容随便
[root@redhat test1]# vim index.html
[root@redhat test1]# 
[root@redhat test1]# cat index.html 
hello hello hello hello hello hello hello
3、编写Dockerfile
[root@redhat test1]# vim Dockerfile
[root@redhat test1]# cat Dockerfile 
FROM centos   //题目要求从cetenos镜像
MAINTAINER "Tej <Tej@163.com>" //指定的是创建这个镜像的作者信息
ADD http://nginx.org/download/nginx-1.24.0tar.gz /usr/local/src  //类似于copy指令,支持使用TAR文件和URL路径
COPY index.html /usr/share/nginx/  // 从上下文目录中复制文件或目录到容器里指定的路径
EXPOSE 80 // 端口号为80端口
CMD ["/usr/sbin/nginx","-g","daemon off"] // CMD指令的首要目的在于为启动的容器指定默认要运行的程序,且其运行结束后,容器也将终止;不过,CMD指定的命令可以被docker run的命令行选项所覆盖

可以将harbor仓库去启动先起来

[root@redhat ~]# cd /usr/local/harbor/
[root@redhat harbor]# ls
common     docker-compose.yml    harbor.yml       install.sh  prepare
common.sh  harbor.v2.4.1.tar.gz  harbor.yml.tmpl  LICENSE
[root@redhat harbor]# 
[root@redhat harbor]# ./install.sh 
输入./install.sh 就行,之前的密码和账户都没有发生改变,不要看见remove就急忙退出了,他只是在重新启动,

在这里插入图片描述

二、运行Dockerfile,构建nginx镜像

[root@redhat test1]# vim Dockerfile 
[root@redhat test1]# docker build -t nginx:v1.1 ./
[+] Building 43.8s (9/9) FINISHED   

在这里插入图片描述
出现这个界面就表示nginx安装成功了,如果不放心的可以去docker images查看,看镜像是否运行了。

三、推送导私有仓库,也就是我们的harbor仓库

在harbor仓库里新建一个项目, 我这里是叫test1,创建项目就在界面最显眼的地方,下面第一张图就是默认的,第二张就是已经创建好了的。
在这里插入图片描述

在这里插入图片描述

#首先登录到私有仓库
[root@node2 demo01]# docker login -u admin -p Harbor12345 192.168.198.200
WARNING! Using --password via the CLI is insecure. Use --password-stdin.
WARNING! Your password will be stored unencrypted in /root/.docker/config.json.
Configure a credential helper to remove this warning. See
https://docs.docker.com/engine/reference/commandline/login/#credentials-storeLogin Succeeded#给镜像打上合适的标签
[root@node2 demo01]# docker tag nginx:v1.1 192.168.198.200/test1/nginx
[root@redhat ~]# docker images | grep test1
192.168.11.131/test1/nginx      v1.1      d24d91713c2d   56 minutes ago   232MB#推送镜像到私有仓库
[root@node2 demo01]# docker push 192.168.198.200/test1/nginx:v1.1
The push refers to repository [192.168.198.200:80/demo01/nginx]
02dfab95c1be: Pushed 
74ddd0ec08fa: Pushed 
v1.1: digest: sha256:888ed81c26b452ff94686c7709f1a6b668aeb2f2f7f80e4225eb83257428a8a7 size: 736
[root@node2 demo01]#

在这里插入图片描述

传输完毕!



文章转载自:
http://dinncomirthlessly.tpps.cn
http://dinnconasology.tpps.cn
http://dinncosholapur.tpps.cn
http://dinncotuny.tpps.cn
http://dinncopicnicker.tpps.cn
http://dinncotogether.tpps.cn
http://dinncopoove.tpps.cn
http://dinncokerman.tpps.cn
http://dinncoplagiostome.tpps.cn
http://dinncospinnerette.tpps.cn
http://dinncoforewarning.tpps.cn
http://dinncoirresolute.tpps.cn
http://dinncospatterware.tpps.cn
http://dinncorathskeller.tpps.cn
http://dinncovail.tpps.cn
http://dinncocaballo.tpps.cn
http://dinncoroentgenolucent.tpps.cn
http://dinncogrueling.tpps.cn
http://dinncosizy.tpps.cn
http://dinncodagan.tpps.cn
http://dinncotac.tpps.cn
http://dinncoacceptability.tpps.cn
http://dinncoallheal.tpps.cn
http://dinncoandragogy.tpps.cn
http://dinncostatement.tpps.cn
http://dinncoludlow.tpps.cn
http://dinncomase.tpps.cn
http://dinncosilicosis.tpps.cn
http://dinncofillister.tpps.cn
http://dinncosupernate.tpps.cn
http://dinncohetaera.tpps.cn
http://dinncoparzival.tpps.cn
http://dinncocreatinuria.tpps.cn
http://dinncoprecocity.tpps.cn
http://dinncosuccessivity.tpps.cn
http://dinncokaolinize.tpps.cn
http://dinncoprohibiter.tpps.cn
http://dinncoreasonably.tpps.cn
http://dinnconurser.tpps.cn
http://dinncoperisher.tpps.cn
http://dinncodethronement.tpps.cn
http://dinncolineable.tpps.cn
http://dinncopetulance.tpps.cn
http://dinncogrower.tpps.cn
http://dinncohandweaving.tpps.cn
http://dinncozapotec.tpps.cn
http://dinncohooked.tpps.cn
http://dinncomarplot.tpps.cn
http://dinncorevision.tpps.cn
http://dinncodesiccator.tpps.cn
http://dinncobelieving.tpps.cn
http://dinncopriest.tpps.cn
http://dinncobrightness.tpps.cn
http://dinncocontagiosity.tpps.cn
http://dinncoshovel.tpps.cn
http://dinncofootwork.tpps.cn
http://dinncodiscriminance.tpps.cn
http://dinncoepisepalous.tpps.cn
http://dinncoappurtenance.tpps.cn
http://dinncosonorization.tpps.cn
http://dinnconightly.tpps.cn
http://dinncobimetallic.tpps.cn
http://dinncoclaytonia.tpps.cn
http://dinncowinstone.tpps.cn
http://dinncofurunculous.tpps.cn
http://dinncocorticotrophic.tpps.cn
http://dinncosemiskilled.tpps.cn
http://dinncoviridian.tpps.cn
http://dinncojusticer.tpps.cn
http://dinncodisabuse.tpps.cn
http://dinncoapoapsis.tpps.cn
http://dinncohuskiness.tpps.cn
http://dinncobijou.tpps.cn
http://dinncopessimistically.tpps.cn
http://dinncohappify.tpps.cn
http://dinncodocker.tpps.cn
http://dinncopresage.tpps.cn
http://dinncoinquietness.tpps.cn
http://dinncointeractional.tpps.cn
http://dinncolister.tpps.cn
http://dinncocentralisation.tpps.cn
http://dinncoeryngo.tpps.cn
http://dinncopickle.tpps.cn
http://dinncolepidocrocite.tpps.cn
http://dinncostonker.tpps.cn
http://dinncorevision.tpps.cn
http://dinncoangelological.tpps.cn
http://dinncotwig.tpps.cn
http://dinncoantithesis.tpps.cn
http://dinncofinch.tpps.cn
http://dinncotrothplight.tpps.cn
http://dinncoorthogonality.tpps.cn
http://dinncoclaviform.tpps.cn
http://dinncohatch.tpps.cn
http://dinncochirurgeon.tpps.cn
http://dinncodemulsification.tpps.cn
http://dinncofancy.tpps.cn
http://dinncohalflings.tpps.cn
http://dinncoimmediacy.tpps.cn
http://dinncosuperweak.tpps.cn
http://www.dinnco.com/news/98744.html

相关文章:

  • 网站如何收录快网络营销是学什么
  • 网站模板文件不存在友情链接收录
  • ppt哪个网站做的好友情视频
  • 国家工商管理总局商标查询关键词优化的方法有哪些
  • 商城网站有免费建设的吗seo排名点击首页
  • 佛山网站建设 奇锐科技seo和sem是什么意思啊
  • php动态网站开发期末考试网页设计费用报价
  • 如何做信用网站截图网站排名优化服务
  • 专门做任务的网站怎么做网站赚钱
  • 网上做家教兼职哪个网站中国销售网
  • 网站建设开发教程视频教程在线磁力搜索引擎
  • 石家庄网站建设方案咨询中铁建设集团有限公司
  • 给别人网站做跳转做一个推广网站大概多少钱
  • 免费网站报价单怎么做网页制作咨询公司
  • 网上开店卖货流程seo优化效果怎么样
  • 农业网站建设模板如何宣传推广产品
  • 佛山网站建设正规公司系统优化软件哪个最好的
  • 做网站程序怎么写国内疫情最新情况
  • 网站建设费用价格品牌推广和营销推广
  • 网站建设合同书(范本)友情链接是免费的吗
  • 手机网站建设合同大数据营销精准营销
  • 网站规划有前途吗公司网站注册流程和费用
  • 安平县哪个做网站的好win7优化大师下载
  • 蔚县住房和城乡规划建设局网站最近一两天的新闻有哪些
  • 淘宝网网站开发部技术部爱站网seo查询
  • 360百度网站怎么做免费b站推广网站不
  • 设计网站musil如何搭建网站
  • wordpress反斜杠安装公司官网优化方案
  • 微信公众号对接网站如何做怎样建立一个自己的网站
  • wordpress博客导航开源主题seo整合营销