会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
LiYi's blog 。◕‿◕。
谦虚,诚实,正直
博客园
首页
新随笔
联系
管理
上一页
1
2
3
4
5
6
7
8
···
15
下一页
2017年7月19日
ansible 列表变量、字典变量
摘要: ansible的变量不仅可以是单个的值,也可以为列表。 输出为: 结合循环 结合循环,这个特性就变得很有用;以参数传递列表给playbook,不用在playbook中固定循环的次数与内容。 输出为: 字典变量 变量也可以为字典:
阅读全文
posted @ 2017-07-19 22:48 clq.lib
阅读(8835)
评论(0)
推荐(1)
2017年7月17日
python模块
摘要: 模块 Python 模块(Module),是一个 Python 文件,以 .py 结尾,包含了 Python 对象定义和Python语句。 模块能定义 函数 , 类 和 变量 ,模块里也能包含可执行的代码。(模块让你能够有逻辑地组织你的 Python 代码段) import module1 来引入模
阅读全文
posted @ 2017-07-17 22:28 clq.lib
阅读(310)
评论(0)
推荐(0)
python函数
摘要: ``` def functionname( parameters ): "函数_文档字符串" function_suite return [expression] ```
阅读全文
posted @ 2017-07-17 21:24 clq.lib
阅读(145)
评论(0)
推荐(0)
2017年6月25日
python数据类型2
摘要: [toc] 1、Python标准数据类型 5个标准数据类型: Numbers(数字) String(字符串) Tuple(元组) List(列表) Dictionary(字典) 1.1 Numbers(数字) Python支持四种不同的数字类型: int(有符号整型) long(长整型[也可以代表八
阅读全文
posted @ 2017-06-25 12:42 clq.lib
阅读(222)
评论(0)
推荐(0)
2017年3月29日
Number Complement
摘要: ```python class Solution(object): def findComplement(self, num): """ :type num: int :rtype: int """ res=0 i=0 while num>0: if nu...
阅读全文
posted @ 2017-03-29 23:21 clq.lib
阅读(154)
评论(0)
推荐(0)
2017年2月22日
ansible配置文件 ansible.cfg的一点说明
摘要: ansible配置文件 ansible.cfg的一点说明 ansible.cfg 配置文件默认为 配置文件里的参数基本上都可以被重新定义在 或者 在 通过参数的形式传递。 ansible在运行的时候会读取配置文件,寻找配置文件的顺序是: 。先找到哪个使用哪个。 大部分的配置默认即可。 少部分需要改动
阅读全文
posted @ 2017-02-22 22:32 clq.lib
阅读(2121)
评论(0)
推荐(0)
2017年2月16日
ansible命令
摘要: Ansible命令 通过ansible命令使用ansible功能。ansible的命令不多,如下: ansible : 用于非固化需求、临时一次性操作 ansible playbook: 执行编写好的剧本playbook,用于复杂、多步骤、经常重复的操作。 ansible doc: 各模块的说明文档
阅读全文
posted @ 2017-02-16 22:35 clq.lib
阅读(320)
评论(0)
推荐(0)
2017年2月15日
inventory file 与hosts patterns (ansible 机器清单 与 主机匹配模式)
摘要: Ansible配置: ansible有两个核心配置文件: ansible.cfg 配置文件和Inventory配置文件 Ansible.cfg配置文件 Inventory机器列表配置 这里介绍 Inventory配置文件 。 Inventory file: Inventory file 机器清单,a
阅读全文
posted @ 2017-02-15 22:48 clq.lib
阅读(4594)
评论(1)
推荐(0)
2017年2月5日
playbook显示task执行结果
只有注册用户登录后才能阅读该文。
阅读全文
posted @ 2017-02-05 22:35 clq.lib
阅读(3)
评论(0)
推荐(0)
文件目录tree显示,python
摘要: ```python #/usr/bin/python import os def travelTree(currentPath, count=0): if not os.path.exists(currentPath): print "no current Path" return if os.path.isfile(currentPath)...
阅读全文
posted @ 2017-02-05 10:28 clq.lib
阅读(506)
评论(0)
推荐(0)
上一页
1
2
3
4
5
6
7
8
···
15
下一页
公告