munkireport / munkireport-php Goto Github PK
View Code? Open in Web Editor NEWA reporting tool for munki
License: MIT License
A reporting tool for munki
License: MIT License
If a client is not able to connect to the munki server, the postflight script does not run. That means that munkireport only receives machine- and report data updates. It would be nice to receive all updates on preflight as well.
In addition to SQLite and MySQL I would like to see full support for MS SQL (including database migrations)
Remote IP address is reported but not the MAC address. Would be nice to see the IP and MAC addresses of en0 and en1.
Would there be a way we could add the ability to edit the manifest associated with the client like MunkiWebAdmin?
When clicking on the Directory Services listing I get the following error as a pop up.
DataTables warning (table id = 'DataTables_Table_0'): DataTables warning: JSON data from server could not be parsed. This is caused by a JSON formatting error.
The network listing page shows an incorrect total count of entries.
It would be useful to have a webpage that checks all requirements (php version, xml-lib, pdo). Troubleshooting will be easier.
Currently the pending updates table is the only table that allows empty spaces between search words and searches across all columns.
This feature was in mr-phpv1 and it was quite helpful to filter
Like firewall, firmware password, automatic login, antivirus installed...
The file located at app/modules/filevault_status/scripts/filevaultstatus has a space before the #!/bin/bash on the first line which causes munkireport to error on the preflight run and while running the install.
Log of the output below:
report_broken_client now reports to a non-existent controller
In MR1, there were options to show 25, 100, and "ALL" records per page. In MR2 there are only options 10, 25, 50, 100 records per page. Is there a way to add the "ALL" records per page back to MR2? I frequently used this to sort different data in different ways.
Thanks!!!
Scott
When running the installer command (/bin/bash -c "$curl -s http://example/index.php?/install) The installer fails at the install Network report step. Line 184 has a slash before index.php which leads to a URL with a double slash (i.e.: http://example.com//index.php?/module/network/get_script/networkinfo.sh)
The installer fails at this point. Editing the installer script and running manually works fine.
EDIT: bug is actually on line 6 of app/modules/network/scripts/install.sh Line 184 is when it dumped the install to >/tmp/install.sh via the curl command above.
Have you ever considered adding the gem Facter to your project as a means of data collection? It could be added to the pkginfo as a pkg install along with the collection scripts.
Add the possibility to disable modules which collect data that I am not interested in.
Improve performance of MunkiReport's "Listings" views. The "Clients" view, in particular, takes a long time to load (20-70 seconds for a MySQL db with 2800 clients).
The pkinfo file downloaded from /index.php?/install/plist only includes an empty file inside the installs key. If a script somehow gets deleted from the preflight.d folder there will be no way to know and munki will not self-heal the installation.
As suggested by @natewalck it would be interesting to include the scripts in the installs key.
I tried to implement this myself but couldn't get the $install_scripts array to the plist without doing a very a hacky solution.
cat ./munkireport-php/app/views/install/install_plist.php
...
<key>installs</key>
<array>
<dict>
<key>path</key>
<string>/usr/local/munki/munkireport-<?php echo $version; ?></string>
<key>type</key>
<string>file</string>
</dict>
<?php
foreach($install_scripts AS $scriptname){
echo '<dict>
<key>path</key>
<string>/usr/local/munki/postflight.d/' . $scriptname . '</string>
<key>type</key>
<string>file</string>
</dict>
';
}
?>
</array>
...
MR1 had the option to add a column under the Client view on the Reports Page to show the local admin accounts for each machine. Is it possible to add this back to MR2?
Thanks,
Scott
We would like the ability to use authentication from the Munki client for posting reports. Munki itself can optionally send a username/password to authenticate to the web repo, and we'd like the ability to do the same with the reporting.
I am testing the new version of Munkitools on a few of our systems. If I install the new version of the tools before installing munkireport, it reports the correct version in the web interface. If I update the tools after installing munkireport, the web interface continues to show the old version of Munki.
disk_report is requested in the postflight script but does not populate disk statistics when MunkiReport is using a MySQL 5.6 database. Downgrading MySQL to 5.5.35 resolves the issue.
Hi
On the page detailing all the information about an individual host the warranty information does not get filled in until i have click the "Check warranty Status" is there a way to a) do this automatically or b) run it for all machine in one go
Thanks
The purchase date gets incorrectly set when the computer in question is covered by a 4 Year AppleCare plan. The calculation for the date in the warranty_helper.php just subtracts 3 years from the warranty end. This also results in an Age graph that is not accurate.
Hi
After pulling the latest updates ( inc the directory services one) i get the following error when running managedsoftwareupdate
Fatal error: Call to a member function bindValue() on a non-object in /opt/munkiweb/system/kissmvc_core.php on line 472
Done.
Any help would be great
Hi
The memory widget is showing that i have a machine with 12GB of RAM, when i click on the link to go to the hardware page it is empty and no machine are listed, and if i show all on the hardware page and then sort by memory the 12GB is at the top of the page even though i have machine with 16+GB of RAM
Would like to have the ability to remove clients from munkireport-php without going into the database. Ideally, both sqlite3 and mysql methods should be supported.
docs/configure.md should have a nice writeup about all the configuration items of munkireport.
I have a few misbehaving clients that are sending back blank or empty data from some of the modules. I need to look at these clients more carefully and determine what is going wrong (it looks like one of the grep lines in the filevault check is not returning any output) but in the meantime some of the summary tables in the dashboard display are rendered incorrectly - they are partially cut off.
Is there a way to remove the login, so it automatically logs in?
So I tried to disable the built-in authentication($conf['auth']['auth_noauth'] = array();
) in favor of using ldap on the site itself (through an apache2 vhost), and (admittedly, I should have predicted this) I am now getting this result when running managedsoftwareupdate:
http://munkibusiness.onehealth.com/index.php?/report/hash_check We failed to reach a server. Reason: Authorization Required
I know you added in the ability to use external auth like AD and LDAP, my question is how do you actually implement this?
And group based access while you're at it!
A school district I'm working for has some (many) machines still running 10.5.8. MunkiReport works great except for the disk info, from what I have seen.
This is what shows on the client detail page for all 10.5.8 machines:
Disk size -2.00 GB
Used 0.00 B
Free -2.00 GB
SMART Status Verified
Here is the output from diskutil info -plist /
on one of our 10.5.8 machines:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Bootable</key>
<true/>
<key>BusProtocol</key>
<string>SATA</string>
<key>CanBeMadeBootable</key>
<false/>
<key>CanBeMadeBootableRequiresDestroy</key>
<false/>
<key>Content</key>
<string>Apple_HFS</string>
<key>DeviceIdentifier</key>
<string>disk0s2</string>
<key>DeviceNode</key>
<string>disk0s2</string>
<key>DeviceTreePath</key>
<string>/PCI0/SATA@1F,2/PRT0@0/PMP@0/@0:2</string>
<key>Ejectable</key>
<false/>
<key>FilesystemName</key>
<string>Journaled HFS+</string>
<key>FreeSpace</key>
<integer>253546201088</integer>
<key>GlobalPermissionsEnabled</key>
<true/>
<key>Internal</key>
<true/>
<key>JournalOffset</key>
<integer>91222016</integer>
<key>JournalSize</key>
<integer>25165824</integer>
<key>MediaName</key>
<string>Untitled</string>
<key>MediaType</key>
<string>Generic</string>
<key>MountPoint</key>
<string>/</string>
<key>ParentWholeDisk</key>
<string>disk0</string>
<key>RAIDMaster</key>
<false/>
<key>RAIDSlice</key>
<false/>
<key>SMARTStatus</key>
<string>Verified</string>
<key>SupportsGlobalPermissionsDisable</key>
<true/>
<key>SystemImage</key>
<false/>
<key>TotalSize</key>
<integer>296812326912</integer>
<key>VolumeName</key>
<string>Macintosh HD</string>
<key>VolumeUUID</key>
<string>3A7C7955-DF2A-36C2-8FE4-47264A9CC7E4</string>
<key>WholeDisk</key>
<false/>
<key>Writable</key>
<true/>
</dict>
</plist>
Love the project! Hopefully we will get these machines upgraded before 10.5 support in Munki is dropped...
The ARD info fields are often populated with useful unique data specific to each org. Some populate the fields with an asset number or image version number. It would be useful if MunkiReport reported on the fields in the client details page.
Currently when modifying a module to include more data or remove existing, the create_table() function is not able to accommodate the changes if the table exists.
The current if(isset()) should be modified to check existing columns vs. provided columns, and create when needed. Unused columns should probably be preserved to keep their data
Munkireport has a lot of hardcoded strings that should be converted to a localisable string.
Here's a list of views (checked views are done)
Migrating MR 2.0.4 to 2.0.5 results in migration errors:
• Migration error: no migrations found in /Library/WebServer/Documents/reposado/html/munkireport//app/migrations/machine_model
• Migration error: Failed: SQLSTATE[HY000]: General error: 1 duplicate column name: adforest
By default the installation does not work correctly on our server because it attempts to load the 'Disk_report/Disk_report_model.php' when the distribution actually contains 'disk_report/disk_report_model.php'.
Enabling the debug config mode spews out the error:
Fatal error: require_once(): Failed opening required '/opt/munkiweb//app/modules/Disk_report/Disk_report_model.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/munkiweb/app/helpers/site_helper.php on line 72
Once we symlinked the case sensitive versions across, things started to work again. I'm guessing this will be a case on all case-sensitive filesystems, as used on Linux (i.e. this will not be evident on Mac OS X as it uses a case-preserving but case-insensitive filesystem)
For now a quick fix for that part seems to be symlinking, or updating the app/helpers/site_helper.php#__autoload to
require_once( APP_PATH.'modules/'.strtolower($module).'/'.strtolower($module).'_model'.EXT );
However, the client details page remains broken as that then spews out another error for 'models/Inventoryitem.php' when the file is actually named 'InventoryItem.php':
Fatal error: require_once(): Failed opening required '/opt/munkiweb//app/models/Inventoryitem.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/munkiweb/app/helpers/site_helper.php on line 76
Again, fixed by symlinking the two together.
Looking through the files of this app there appears to be a tonne of differing case conventions going on, which will not be flagged when developing on OS X but will explode the code on Linux servers.
Just wanted to see if there a version of the directoryservice.sh command that will account for OpenDirectory or LDAPv3 connections. Right now the code only appears to check for AD attributes.
It would be great to have a settings page where to change MR2 settings. All from minor things like site name and company logo, to more important like user permissions and database settings. All from a gui
When clicking on any of the tabs on a client detail page the url updates with the respective # suffix (e.g. /clients/detail/C07XXXXXXXXX#apple-software) but does not update the tab content.
I've tested this across firefox, chrome and safari. I'm assuming it's something wrong with my config? Can you advise on any possible troubleshooting?
cheers
Matt
It would be nice to have the dashboard update automatically (every minute or so)
If the reporting server is unavailable, the script should exit nicely and allow Munki to run. Currently, it returns an error and managedsoftwareupdate will not run.
user and password are sent in clear text. Maybe we should add support for self-signed ssl or similar
Edit: my bad. this is more than likely possible already. I'd like to document the method then
Include support in the main configuration file to increment the time before a session is disconnected. Should avoid having to login multiple times in a day.
Consider secure option. Documentation
Hello. Please check this code for accuracy as I have used your code to make the postflight script execute postflight scripts in the postflight.d folder. I am performing this as I would still like to report to use MunkiWebAdmin for the time being.
PostFlight (MunkiReport-PHP)
http://pastebin.com/jEzR6Tm8
submit.postflight (/usr/local/munki/postflight.d)
http://pastebin.com/sLZGBueL
If these are correct feel free to add them to your repository to allow postflight scripts in /usr/local/munki/postflight.d
Thank you!
Enable Model and warranty lookups through a Proxy Server, if the munkireport-Server is behind one.
There are some legacy models that should be moved to the correct module:
This is somewhat disruptive as the clients need to be re-configured to use the correct names. I want to add this to the 2.0.5 release.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.