PaaS 云计算开发运维

2.根据提供的软件包,搭建 rancher 平台。通过 curl 命令查询 Rancher 管理 平台首页,将操作命令及返回结果以文本形式提交到答题框。

 [root@server ~]# curl http://10.0.3.137:8080 
Loading…


3.根据提供的软件包,通过应用商店部署 Gogs,修改网页访问端口为 9093, 通过 curl 命令访问用户列表,将操作命令及返回结果以文本形式提交到答题框

   [root@server ~]# curl http://10.0.3.138:9093/
            
            
            

    
    
    



            
            
            
            
            
            


    

    
    
    
    







    
    


    
    

    Gogs

    
Please enable JavaScript in your browser!
                    

Gogs

A painless self-hosted Git service

            

Easy to install

Simply run the binary for your platform. Or ship Gogs with Docker or Vagrant, or get it packaged.

Cross-platform

Gogs runs anywhere Go can compile for: Windows, Mac OS X, Linux, ARM, etc. Choose the one you love!

Lightweight

Gogs has low minimal requirements and can run on an inexpensive Raspberry Pi. Save your machine energy!

Open Source

It's all on GitHub! Join us by contributing to make this project even better. Don't be shy to be a contributor!

    

4.根据提供的软件包,通过应用商店部署 Elasticsearch 2.x,修改网页访问端 口为 9094,通过 curl 命令访问首页,将操作命令及返回结果以文本形式提交到 答题框。

[root@server ~]# curl http://10.0.3.138:9094

  
  












[root@server ~]#

5根据提供的软件包,通过应用商店部署 Grafana,修改网页访问端口为 9090,通过 curl 命令访问首页,将操作命令及返回结果以文本形式提交到答题框。

  [root@server ~]# curl http://10.0.3.138:9090/graph
Prometheus Time Series Collection and Processing Server


























6.根据提供的软件包,通过应用商店部署 Grafana,访问 3000 端口,使用 curl 命令访问 Grafana 服务的 3000 端口,将操作命令及返回结果以文本形式提交到 答题框。

   [root@server ~]# curl -H "Authorization: Bearer eyJrIjoiaHNjUFZBRkczRzI3Tk84dTZGc25MU0JLOXNjWDdzS0wiLCJuIjoid21tIiwiaWQiOjJ9"    http://10.0.3.138:3000/api/dashboards/home | python -m json.tool
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                             Dload  Upload   Total   Spent    Left  Speed
 100  1452  100  1452    0     0  33759      0 --:--:-- --:--:-- --:--:-- 34571
  {
"dashboard": {
    "annotations": {
        "list": []
    },
    "editable": true,
    "hideControls": true,
    "id": null,
    "links": [],
    "rows": [
        {
            "collapse": false,
            "editable": true,
            "height": "25px",
            "panels": [
                {
                    "content": "
\n Home Dashboard\n
", "editable": true, "id": 1, "links": [], "mode": "html", "span": 12, "style": {}, "title": "", "transparent": true, "type": "text" }, { "id": 123123, "span": 12, "type": "gettingstarted" } ], "title": "Home Dashboard" }, { "collapse": false, "editable": true, "height": "510px", "panels": [ { "headings": true, "id": 3, "limit": 4, "links": [], "query": "", "recent": true, "search": false, "span": 7, "starred": true, "tags": [], "title": "", "transparent": false, "type": "dashlist" }, { "editable": true, "error": false, "id": 4, "isNew": true, "links": [], "span": 5, "title": "", "transparent": false, "type": "pluginlist" } ], "title": "Row" } ], "schemaVersion": 12, "sharedCrosshair": false, "style": "dark", "tags": [], "templating": { "list": [] }, "time": { "from": "now-6h", "to": "now" }, "timepicker": { "enable": false, "refresh_intervals": [ "5s", "10s", "30s", "1m", "5m", "15m", "30m", "1h", "2h", "1d" ], "time_options": [ "5m", "15m", "1h", "6h", "12h", "24h", "2d", "7d", "30d" ], "type": "timepicker" }, "timezone": "browser", "title": "Home", "version": 2 }, "meta": { "canEdit": true, "canSave": false, "canStar": false, "created": "0001-01-01T00:00:00Z", "createdBy": "", "expires": "0001-01-01T00:00:00Z", "isHome": true, "slug": "", "updated": "0001-01-01T00:00:00Z", "updatedBy": "", "version": 0 } } [root@server ~]#

7.在 server 节点,修改配置文件,使仓库指向我们自己创建的 registry 节点, 使用 docker info 命令查看修改后 docker 的仓库指向,将添加配置文件的参数和 执行 docker info 命令的返回结果以文本形式提交到答题框。

  [root@server etc]# cat /etc/sysconfig/docker
   # /etc/sysconfig/docker
 ADD_REGISTRY='--add-registry 10.0.3.137:5000'
   INSECURE_REGISTRY='--insecure-registry 10.0.3.137:5000'
  [root@server etc]# docker info
 Registry: https://10.0.3.137:5000/v1/
 WARNING: bridge-nf-call-iptables is disabled
 WARNING: bridge-nf-call-ip6tables is disabled
 Insecure Registries:
  10.0.3.137:5000
  127.0.0.0/8
 Registries: 10.0.3.137:5000 (insecure), docker.io (secure)
 [root@server etc]#

8.搭建 rancher 平台的时候,需要打开系统的内核转发功能,请把打开内核 转发功能的参数以文本形式提交到答题框。

   net.ipv4.ip_forward=1
  net.ipv4.conf.default.rp_filter=0
  net.ipv4.conf.all.rp_filter=0

9.当要使用 docker api 查询信息的时候,我们需要修改 docker 的配置文件, 添加一条 OPTIONS 来使得 api 功能可以使用,请把添加的 OPTIONS 参数以文 本形式提交到答题框。

  OPTIONS='-H=tcp://0.0.0.0:2375 -H unix:///var/run/docker.sock'
  (在/etc/sysconfig/docker文件后面加入就行了)

10.配置 docker 容器实现 nginx 的负载均衡,需要修改 nginx 的配置文件,请 把定义 tomcat 负载均衡的参数以文本形式提交到答题框。

   //这个是定义Tomcat服务的负载均衡
 upstream wei {

server 10.0.3.137:32768;

server 10.0.3.137:32769;

  }
  server {
listen       80;
server_name  10.0.3.137;//宿主机ip

  #charset koi8-r;
#access_log  /var/log/nginx/host.access.log  main;

 //这个是调用Tomcat服务的负载均衡
location / {
    proxy_pass http://wei;
}

你可能感兴趣的:(Linux,云计算,docker,大数据)