• CentOS6.5 安装snorby


    如果下列任何组件之一已经被安装,请酌情忽略

    1.Snort

    参照 CentOS6.5 安装snort

    2.GIT

    系统自带

    3.Ruby 版本限制> 1.9.2

    系统自带版本过低首先卸载掉,注意 必须是1.9.*版本

    yum erase ruby ruby-libs ruby-mode ruby-rdoc ruby-irb ruby-ri ruby-docs

    然后去ruby官网下载1.9.3版本Ruby 1.9.3-p547 http://ruby.taobao.org/mirrors/ruby/

    在此之前请安装yaml

    yum list libyaml*

    安装ruby

    tar -zxvf ruby-1.9.3-p547.tar.gz
    cd ruby-1.9.3-p547
    ./configure
    make 
    make install

    4.Rails 版本限制> 3.0.0

    gem install rails -V

     5.ImageMagick 版本限制> 6.6.4

      安装之前卸载系统原有版本

    yum erase ImageMagick

      安装基础库

    yum install bzip2-devel freetype-devel libjpeg-devel libpng-devel libtiff-devel giflib-devel zlib-devel ghostscript-devel djvulibre-devel libwmf-devel jasper-devel libtool-ltdl-devel libX11-devel libXext-devel libXt-devel lcms-devel libxml2-devel librsvg2-devel OpenEXR-devel
    yum --enablerepo=epel install jasper jasper-libs jasper-devel

       由于rpm安装ImageMagick会出现各种各样的问题,缺少n多依赖包,现以源码安装ImageMagick,下载http://www.imagemagick.org/script/install-source.php#unix最新源码包并安装

    tar xvzf ImageMagick.tar.gz
    cd ImageMagick-6.8.9-7
    ./configure
    make
    make install
    ldconfig /usr/local/lib

    6.安装Wkhtmltopdf

      去官网http://wkhtmltopdf.org下载最新版wkhtmltox-0.12.1_linux-centos6-amd64.rpm 

    rpm -ivh wkhtmltox-0.12.1_linux-centos6-amd64.rpm

    7.进入正题,安装snorby

    git clone git://github.com/Snorby/snorby.git
    cd snorby
    gem install bundler
    bundle install

    8.配置

    vim config/database.yml

    根据需求更改

    # Snorby Database Configuration
    #
    # Please set your database password/user below
    #
    snorby: &snorby
      adapter: mysql
      username: root
      password: 123123
      host: localhost
    
    development:
      database: snorby
      <<: *snorby
    
    test:
      database: snorby
      <<: *snorby
    
    production:
      database: snorby
      <<: *snorby

     配置snorby_config.yml


    vi snorby_config.yml
    development:
      domain: localhost:3000
      wkhtmltopdf:/usr/local/bin/wkhtmltopdf
      mailer_sender: 'snorby@snorby.org'
      rules:
        - "/etc/snort/rules"
        - "/etc/snort/so_rules"
    
    test:
      domain: localhost:3000
      wkhtmltopdf: /usr/local/bin/wkhtmltopdf
      mailer_sender: 'snorby@snorby.org'
    
    # Change the production configuration
    # for your environment.
    production:
      domain: 'demo.snorby.org'
      wkhtmltopdf: /usr/local/bin/wkhtmltopdf
      mailer_sender: 'snorby@snorby.org'
      rules:
        - "/etc/snort/rules/folder"
        - "/etc/snort/so_rules/folder"
    vi script/rails
    #!/usr/bin/env ruby  替换为
    #!/usr/local/bin/ruby

    卸载掉一个i18n gem(版本号大的那个)

    gem uninstall i18n

    安装

    bundle exec rake snorby:setup

    运行

    bundle exec rails server -e production
  • 相关阅读:
    [leetcode]40. Combination Sum II
    二分法查找,如果找到就返回索引,找不到就返回插入该数后的坐标
    [leetcode]39combinationsum回溯法找几个数的和为目标值
    [leetcode33Search in Rotated Sorted Array]在排序旋转后序列中找目标值
    leetcode Add to List 31. Next Permutation找到数组在它的全排列中的下一个
    3sum
    Security and Risk Management(5)
    Lawrence HDU
    Print Article HDU
    Batch Scheduling POJ
  • 原文地址:https://www.cnblogs.com/tswcypy/p/3932035.html
Copyright © 2020-2023  润新知