Sha256: 83fbe0997413e0100a3d7a0eb31858831bfd8f28088661ca55337196b7d919e1
Contents?: true
Size: 1.87 KB
Versions: 6
Compression:
Stored size: 1.87 KB
Contents
#!/usr/bin/env ruby # # # Fluentd # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # require 'optparse' require 'fluent/diagtool/collectutils' require 'fluent/diagtool/maskutils' require 'fluent/diagtool/validutils' require 'fluent/diagtool/diagutils' include Diagtool params = {} OptionParser.new do |opt| opt.banner = "Usage: #{$0} -o OUTPUT_DIR -m {yes | no} -w {word1,[word2...]} -f {listfile} -s {hash seed}" opt.on('--precheck', 'Run Precheck (Optional)') opt.on('-o','--output DIR', String, 'Output directory (Mandatory)') opt.on('-m','--mask yes|no', String, 'Enable mask function (Optional : Default=no)') opt.on('-w','--word-list word1,word2', Array, 'Provide a list of user-defined words which will to be masked (Optional : Default=None)') opt.on('-f','--word-file list_file', String, 'provide a file which describes a List of user-defined words (Optional : Default=None)') opt.on('-s','--hash-seed seed', String, 'provide a word which will be used when generate the mask (Optional : Default=None)') opt.on('-c','--conf config_file', String, 'provide a full path of td-agent configuration file (Optional : Default=None)') opt.on('-l','--log log_file', String, 'provide a full path of td-agent log file (Optional : Default=None)') end.parse!(into: params) diag = DiagUtils.new(params) if params[:precheck] diag.run_precheck() else diag.run_diagtool() end
Version data entries
6 entries across 6 versions & 1 rubygems