Sha256: c496577378d7d0448926645c148b41f5451f394679c3b026627f692df6d9fa3b

Contents?: true

Size: 1.16 KB

Versions: 21

Compression:

Stored size: 1.16 KB

Contents

-# coding: utf-8
- info_procs = (Facter.value :processorcount).to_i
- info_load = Sys::CPU.load_avg.first.to_f
- info_norm = info_procs.zero? ? "N/A" : (100 * info_load / info_procs).round(1)
- info_trans = RestFtpDaemon::Counters.instance.get :data, :transferred
- info_processed = RestFtpDaemon::Counters.instance.get :jobs, :processed
- mem = GetProcessMem.new


.navbar-header

  %h1
    = Conf.app_name
    %small
      = "v#{Conf.app_ver} [#{Conf.app_env}]"


.header-indicators.indicators.navbar-header.pull-right

  .btn-group.btn-group-sm.disabled
    .btn.btn-default.btn-warning.disabled Load
    .btn.btn-default.disabled= info_load.round(1)

  .btn-group.btn-group-sm
    .btn.btn-default.btn-warning.disabled  CPU
    .btn.btn-default.disabled= "#{info_norm} %"

  .btn-group.btn-group-sm
    .btn.btn-default.btn-warning.disabled  Mem
    .btn.btn-default.disabled= format_bytes(mem.bytes, "B")

  .btn-group.btn-group-sm
    .btn.btn-default.btn-success.disabled  Processed
    .btn.btn-default.disabled= info_processed.to_i

  .btn-group.btn-group-sm
    .btn.btn-default.btn-success.disabled  Transferred
    .btn.btn-default.disabled= format_bytes(info_trans, "B", 1)

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
rest-ftp-daemon-1.1.1 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.1.0 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.15 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.14 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.13 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.12 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.11 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.10 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.9 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.8 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.7 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.6 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.5 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.4 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.3 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.2 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-1.0.1 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-0.502.2 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-0.502.1 lib/rest-ftp-daemon/views/dashboard_header.haml
rest-ftp-daemon-0.502.0 lib/rest-ftp-daemon/views/dashboard_header.haml