Commit Graph

605 Commits

Author SHA1 Message Date
Digimer
51c9d2952d * Fixed a bug with caching database handles in the recent database updates causing Database->write to stop working.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-08-16 19:34:37 -04:00
Digimer
fe33fbb239 * Created System->maintenance_mode to add "maintenance mode" support to Striker.
* Continuing work on adding the system update job support to Striker. Untested/Incomplete.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-08-16 02:38:58 -04:00
Digimer
6aa74d3d96 * Updated Database->_test_access() to use the DBD 'ping' method, and attempt a reconnect of failure.
* Updated Database->connect to take a specific UUID to attempt a connection to.
* Renamed some old 'sys::x' variables related to the database to 'sys::database::x' to conform better to coding standards.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-08-15 16:57:57 -04:00
Digimer
d91b50fd63 * Bumped anvil.spec to 3.0-14 and fixed a Requires package name with a stray colon.
* Cleaned up (enough, anyway) the tools/anvil-update-system tool.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-08-15 03:01:13 -04:00
Digimer
dd88051d9b * Finished the initial version of tools/anvil-update-system.
* Updated the RPM to .13 to disable postun's disabling of postgres, which breaks Anvil! software using the database during RPM updates.
* Fixed a logging bug where the number of DB connections was not inserting the number properly.
* Fixed exits in tools/anvil-prep-database.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-08-14 03:45:36 -04:00
Digimer
a63bfb0799 * Added support to reconfigure a Striker system.
* Started adding support for updating the striker (and later, all) systems. This will be handled by the in-progress tools/anvil-update-system program.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-08-13 18:25:48 -04:00
Digimer
28f3aaae43 * Disabled caching and forcing read in Storage->read_config.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-08-13 11:38:59 -04:00
Digimer
252fbf21ef * Fixed a bug where '$anvil->' wasn't referencing '$anvil->data->' when it should have been.
* Got anvil-manage-striker-peers working properly (so far).
* Updated anvil-prep-database to call anvil-manage-striker-peers, but testing still needed.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-08-13 02:22:46 -04:00
Digimer
1106d36e03 * Fixed bugs in tools/anvil-manage-striker-peers, basic testing done.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-08-11 23:20:03 -04:00
Digimer
f9ce6e1154 * Finished, but not yet tested, tools/anvil-manage-striker-peers.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-08-10 00:57:09 -04:00
Digimer
89c06b9f24 * Started work on tools/anvil-manage-striker-peers to do the actual work on managing local and peer databases in anvil.conf.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-08-08 15:10:29 -04:00
Digimer
0fa3c42f2f * Fixed a bug where setting the debug level to 3 caused a deep recursion and a system hang.
* Update Anvil::Tools->new() to access the parameters 'log_level', 'log_secure' and 'debug', streamlining the frequent calls to $anvil->Log->level and ->secure in program startup, and allowing the values to take effect during the ->new constructor.
* Passed 'debug' to child method calls in more places (still more to do though).
* Fixed a bug where 'test_table' wasn't set in the right place, causing the database to try to initialize repeatedly.
* Made Database->archive_database only run if called with root access.
* Now the number of database connections are stored in 'sys::db_connections' instead of checking the returned number, and that is cleared on disconnect.
* Started working more on 'anvil-daemon', including adding support for System->call being taking 'background', 'stderr_file' and 'stdout_file' paramters which, when set, used Proc::Simple to background the process.
* Did some more work on database archiving, though still far from done.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-08-01 02:06:16 -04:00
Digimer
a364141d81 * Added a check/cycle to Remote->call that checks to see if the channel was established and loops up to five times, with a second delay in each try. Also disable the Time::HiRes stuff in this method for now.
* Fixed a bug where "form::error_massage" was default to '&nbsp;' which caused simple checks to thing there was an error when all was fine.
* Got the "add new sync peer" form confirmation box displaying and cleaned up the CSS a bit.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-30 01:53:36 -04:00
Digimer
1f8c27ccfb * Updated Remote->call to use timeout again.
* Deleted test.pl, which shouldn't have been in git anyway.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-25 22:37:38 -04:00
Digimer
839bfc8a2d * Updated Striker to better handle when host.uuid hasn't been generated yet on brand new installs.
* Updated anvil-update-state to add commas to network link speeds.
* Added dmidecode to the spec file

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-25 21:02:48 -04:00
Digimer
9ab242a117 * Decided to move development to Fedora 28 to prepare for the leap to RHEL 8. So this commit is the first where the Anvil! Striker can be installed.
* Updated Get->users_home() to default to return the hore directory for the user running the program.
* Updated Remote->call() to start working on handling timeouts.
* Updated Storage->change_owner(), ->make_directory() and ->write_file() to default the the user and group running the program.
* Fixed a bug in home reporting the MAC address of NICs when confirming configuration of Striker. Also changed showing the domain to the hostname.
* Got more work done on sync peers.
* Updated the RPM spec file to install on Fedora 28.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-25 02:34:47 -04:00
Digimer
b24b20ec89 * Working on saving the new peer. Made progress on, but not yet finished, sanity checking the new peer form values.
* Cleaned up some docs.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-20 03:08:44 -04:00
Digimer
578c23b0a3 * Finished the form for adding peers (but no logic to support it yet, it's just filled and formatted).
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-19 16:40:03 -04:00
Digimer
1ac1bc5ffb * Made more progress on the peer database configuration page.
* Added a switch to tools/anvil-configure-striker to prevent reboots.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-18 18:32:39 -04:00
Digimer
458ef94851 * Fixed a bug where the config page would be shown while a job was pending.
* Fixed a bug in Database->insert_or_update_users() wasn't handling the user's session salt.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-18 01:47:52 -04:00
Digimer
9e8ce6dec4 * Fixed up security handling.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-14 03:05:19 -04:00
Digimer
56045214f2 * Fixed a problem with tools/anvil-prep-database being called from the anvil-striker RPM where the local DB password wasn't making it into the hash in time to set the DB password.
* Disabled searching for 'path::config...' files.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-14 02:51:22 -04:00
Digimer
7e63cfbcc4 * Fixed the schema path.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-13 18:29:28 -04:00
Digimer
2c52f649ba * Fixed the path of anvil.sql
* Set Log->entry to chmod the log file to 666 when the file is opened to ensure apache can write to it.
* Fixed a string replacement variable name.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-13 03:26:53 -04:00
Digimer
eae72ad582 * Rolled back to use stock postgres.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-13 02:24:40 -04:00
Digimer
ee543ab64b * Re-fixed postgresql daemon path.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-12 21:30:13 -04:00
Digimer
b87f6c63e2 * Fixed the postgres service variable.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-12 21:22:15 -04:00
Digimer
8cee9cdcc2 * Updatedb the anvil.spec to be smarter about pre and post (and postun).
* Updated tools/anvil-prep-database to use a daemon name from Tools.pm to more easily support later postgres version upgrades.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-12 21:16:27 -04:00
Digimer
1539ef72a8 * Fixed how passwords are supressed in logs.
* Fixed config step 2 display.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-11 14:07:07 -04:00
Digimer
2d88502f6a * Continued work on the sync page.
* Updated rpm spec to bring in gnome when installing anvil-string.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-11 02:14:21 -04:00
Digimer
ee649ff2dd * Started work on the Striker sync function. It shows (without formatting yet) the ways the local dashboard can be accessed.
* Added another check and better error handling to Template->get() to print a more useful message if a template is found but fails to parse.
* Moved some strings into the words file.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-07 01:31:40 -04:00
Digimer
6e19d45845 * Updated Template->get to print a useful error message of a template is not found in a file.
* Moved templates around different files to clean things up.
* Moved the "back" and "refresh" icons over to the right by the logo, and added a new icon for handling mail, alerts, install targets and manifests.
* Started work on the Striker configuration sub-page.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-06 03:07:45 -04:00
Digimer
19672f8b7c * Started work on the Striker menus, adding mechanisms for "back" and "refresh".
* Fixed a bug where the old style '#!replace!...!#' replacement variables were not being escaped when processing variable insertions into strings.
* Made the body variable be stored in 'form::body' instead of passing around the '$body' variable.
* Created a set of new icons.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-07-04 17:57:25 -04:00
Digimer
f120866fa5 * Fixed merge issues.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-27 18:55:35 -04:00
Digimer
96bda1d329 Merge branch 'master' of github.com:digimer/anvil
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-27 18:51:55 -04:00
Digimer
1079c65687 * Finished working on the log in and log out functions of Striker. Still super basic, but it works!
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-27 18:13:16 -04:00
Digimer
3fce021498 * Making good progress on the internal login/account methods. The user can now log in, though the first reload logs them right back out. Lots still broken.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-27 01:28:13 -04:00
Digimer
a6a5df2496 * Fixed a bug in 'home' not displaying the 'offline' message when it was waiting for a reconfig.
* Cleaned up 'button' CSS class links and submit CSS to match.
* Re-enabled reboot at the end of a tools/anvil-configure-striker run.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-22 17:27:30 -04:00
Digimer
66928edb06 * Added logic to check if Striker is configured and, if so, enter main functions.
* Finished up the configuration logic for Striker.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-22 01:43:43 -04:00
Digimer
2febb09d72 * Updated anvil-configure-striker to handle network configurations in non-bonded configurations and to remove virsh bridges.
* Added error messages to Striker configuration forms.
* Fixed a bug in home->get_network_details() function to handle single IPs in network.xml.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-20 19:50:56 -04:00
Digimer
a3d97e4c92 * Updated anvil-update-states to mark interfaces, bonds, bridges and IP addresses as DELETEd when they disappear.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-18 16:29:27 -04:00
Digimer
c208d676cb * Finished the jquery (for now) to pre-fill the step 2 form.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-18 01:24:19 -04:00
Digimer
2ea506b4d9 * Got the jquery to fill the form IP data is set.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-17 18:25:56 -04:00
Digimer
97441831e6 * Started reworking the jquery to read through the network.json file and parse the form, instead of looping through the form and reading the json file repeatedly.
* Made System->get_ips() smarter; it pulls DNS data from the route interface only.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-16 00:19:39 -04:00
Digimer
0272ba8b80 * Moved the network default values into the main defaults hash.
* Fixed a bug in Database->insert_or_update_network_interfaces where independent interfaces (not under a bridge or a bond) were not being saved.
* Continued working on improving Striker's network config jquery/form functions.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-15 02:17:20 -04:00
Digimer
38f81fd8eb * Started work on using jquery to more intelligently set the config step 2 form.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-13 18:49:23 -04:00
Digimer
86259a4783 * Got the network.xml and network.json files fixed and parsable.
* Moved config JS to config.js.

Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-10 00:27:08 -04:00
Digimer
66b5c815d0 * Finished recording IP address information in network.json/xml.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-09 13:29:51 -04:00
Digimer
12afcb9731 * Started working on adding IP data to network.json (and .xml).
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-08 10:52:31 -04:00
Digimer
1245cfc547 * Re-enabled writing of the network.json and network.xml files.
Signed-off-by: Digimer <digimer@alteeve.ca>
2018-06-07 23:40:38 -04:00