码迷,mamicode.com
首页 > Web开发 > 详细

saltstack之webtatic rpm安装

时间:2015-03-02 19:23:17      阅读:171      评论:0      收藏:0      [点我收藏+]

标签:saltstack

webtatic:主要供应最新LAMP等软件源(官网:https://www.webtatic.com/)

今天,我用saltstack来安装其软件,也就是扩展一个yum仓库.以方便安装/更新lamp相关软件.


不废话,直接贴配置yum/init.sls:

clean_yum_cache:
  cmd.wait:
    - name: yum clean all

webatic_rpm:
  file.managed:
    - name: /soft/latest.rpm
    - source: salt://yum/files/latest.rpm
    - mode: 644
    - unless: test -e /soft/latest.rpm

webatic_yum:
  cmd.run:
    - cwd: /soft/
    - names:
      - rpm -ivh latest.rpm
    - unless: rpm -q webtatic-release
    - require:
      - file: webatic_rpm
    - watch_in:
      - cmd: clean_yum_cache


供其参考!

本文出自 “坏男孩” 博客,请务必保留此出处http://5ydycm.blog.51cto.com/115934/1616528

saltstack之webtatic rpm安装

标签:saltstack

原文地址:http://5ydycm.blog.51cto.com/115934/1616528

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!