2.ansible-playbook基本参数


不错学完了第一课我叫你ansible-playbook的参数
--force-handlers run handlers even if a task fails 强制执行handler
--list-tags list all available tags 列出标签
--list-tasks list all tasks that would be executed 列出要执行的tasks
--skip-tags=SKIP_TAGS
only run plays and tasks whose tags do not match these
values 不执行tag匹配到的task
--start-at-task=START_AT_TASK
start the playbook at the task matching this name 指出从那个task开始执行
--step one-step-at-a-time: confirm each task before running 执行一步需要你确认
-t TAGS, --tags=TAGS only run plays and tasks tagged with these values 只执行标签匹配的内容

总结:
在你使用,例如jenkins和极道等一些发布工具他们由于集成了ansible,你可以使用跳过tags或者执行tags来完成剧本分步。

猜你喜欢

转载自www.cnblogs.com/leleyao/p/8994659.html