Giter Club home page Giter Club logo

falconstats's People

Contributors

darookee avatar dsigmund avatar heholord avatar hermannbjorgvin avatar j-tt avatar n1ghtshade avatar stevesbrain avatar technologyclassroom avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

falconstats's Issues

JSON configuration options

A config.json file is now in the root directory of the repository

Reading it from Javascript isn't an issue and scripts can be easily reconfigured to use values from that in the code. Bash scripts however will need some utility like JQ to read from the json file.

I timed the scripts in the repo last night and bash came ahead consistantly around 5-10 times faster than nodejs scripts. I think we should aim to keep the runtime down as much as possible to avoid too much bloat. We could also cache nodejs scripts at a specific interval for scripts that aren't very quick to change anyway.

What do people think is the best way to do this? I feel like this project would be better if you could edit a config file for appearance, key values, and so on.

Symlink incorrect folder?

In the instructions it says:

"ln -s falcon-motd /etc/update-motd/falconstats"

However on Ubuntu Server 18.04 the directory is "/etc/update-motd.d/"

Unless there's something I'm missing or doing wrong?

Problem when running "node init.js"

I get the following error output when running "node init.js" as shown in the directions:

module.js:549
    throw err;
    ^

Error: Cannot find module 'chalk'
    at Function.Module._resolveFilename (module.js:547:15)
    at Function.Module._load (module.js:474:25)
    at Module.require (module.js:596:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (/home/abdulhakeem/FalconStats/init.js:1:83)
    at Module._compile (module.js:652:30)
    at Object.Module._extensions..js (module.js:663:10)
    at Module.load (module.js:565:32)
    at tryModuleLoad (module.js:505:12)
    at Function.Module._load (module.js:497:3)

No license

I noticed this project doesn't have a license associated with it.
By the Free Software Foundation's definition, software without a license is not free. It looks like the intent is to have this be a free software project, based on the fact that you have been accepting code from a few contributors.

I suggest you add a suitable license to this repository, to clarify that the code is free software. Choosealicense.com is a good resource for selecting a suitable license.

I personally recommend the GNU GPL v3.

Syntax error: "(" unexpected in services.sh

Hi, Today I tested out FalconStats and something doesn't work.

I've got error:
Error

Platform: Debian 9 ~ i686
My config: diskspace, hddtemp, service (minimal)
I use only: smbd, ufw (both exists in services.sh - file not modified, looks well)

Scripts converted to bash

I'm not sure if I should create a pull request, so I thought I just create an issue and let you guys decide if you are interested.
I converted the ssl, discspace and hddtemp script from nodejs to bash, which lightens this whole thing as nodejs would not be required to run this and still get a beautifull MOTD output.
The hddtemp script currently does not display the temperatures in columns, but this could probably implemented.
You can find the scripts here.

What is missing is a simple configuration wizzard, but I added all the configuration options to ./scripts/config.sh which is included by the scripts when they run.

Better Instructions

  1. Is this hosted on npmjs.com? If not, add git clone command
  2. Where should i clone this repo to?
  3. How do I install this to the motd? link the scripts?
  4. How can i test if it works (without logging out and in again)?

Just some suggestions, really like the effort here :-)

Installation Process - Symlink Doesn't Work

FalconStats installation notes

OS: Ubuntu 20.04 LTS x86_64
Kernel: 5.4.0-40-generic

git clone https://github.com/Heholord/FalconStats
cd FalconStats/

Cloned repo, cd'd to folder

sudo apt install nodejs npm
sudo npm install -g

Had to install nodejs and npm packages, weren't already installed

ln -s falcon-motd /etc/update-motd.d/falconstats
sudo ln -s falcon-motd /etc/update-motd.d/falconstats
ls

The directions seem to imply that there will be a 'falcon-motd' file/folder created, but this folder does not seem to exist anywhere. Tried searching with locate/mlocate but 'falcon-motd' doesn't seem to exist anywhere. So what is supposed to be symlinked?

Maybe the 'falcon-motd' folder is actually supposed to be the 'scripts' folder?

sudo node init.js

Completed the initial config

Drives:
/dev/sda,/dev/sdb,/dev/sdc,/dev/sdd,/dev/sde,/dev/sdf,/dev/sdg

Services:
FAHClient,apache2,cups,lvm2,mysql,named,nmbd,openvpn,rsync,smbd,ssh,transmission-daemon,ufw,virtualbox,webmin

falcon-motd

'falcon-motd' does actually run the test, so it must be an executable somewhere right? So maybe that symlink from before will actually do something

got the problem with the services.sh script, but fixed with #21

Now falcon-motd executable seems to be working, but hddtemp not working because of sudo

sudo chmod u+s /usr/sbin/hddtemp

hddtemp still not working, although I confirmed I can run it as my user without sudo. Will have to revisit issue, not a problem with FalconStats.

Attempting symlink to see if falcon-motd will work upon logout/login

sudo ln -s falcon-motd /etc/update-motd.d/falconstats

After doing the symlink, /etc/update-motd.d/ shows the falconstats -> falcon-motd symlink but it's red w/ black background indicating a broken link, so something is going wrong at this point

So how to actually get the scripts to work with the update-motd.d directory? What exactly is running when falcon-motd is executed? I'm not sure what I'm missing here but the point of failure seems to be this symlink thing.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.