2
0
mirror of https://github.com/xcat2/confluent.git synced 2025-01-17 21:23:18 +00:00

635 Commits

Author SHA1 Message Date
Jarrod Johnson
46d3779774 Connect shellserver to httpapi
Have httpapi recognize the difference and start a shellserver
session when appropriate.  Next step will be to wire up enumeration of
current shellserver sessions, debug ssh.py traceback, delete on remote
close, and auto-delete when no client connected after some interval (e.g.
30 minutes).
2016-01-06 17:03:10 -05:00
Jarrod Johnson
5d73548583 Use a plain incrementing session id
UUIDs when a simple number will do are harder to use.
Change to a simple increment id.  This could cause an issue
with multiple management nodes, but I think the sessions
should be contained to the instance used.
2016-01-06 11:40:31 -05:00
Jarrod Johnson
8ae8b79837 Fix misuse of console log for shell sessions
console logging assumptions are not valid for shell sessions.
Correct by modifying the buffer init code to be conditional
and adding a stub 'log' to the ShellHandler class.
2016-01-06 11:27:11 -05:00
Jarrod Johnson
0df21ddeb0 Amend core to pass shell objects through
For 'handler' plugin definitions, also recognize
the 'console' exception to allow the plugin to pass
through to the shellserver infrastructure.
2016-01-06 10:06:09 -05:00
Jarrod Johnson
0e821a7bfe Refactor socket api terminal handler
The 'terminal' handler code is broken out to get ready
for using 'shell' as well as 'console'
2016-01-05 16:29:21 -05:00
Jarrod Johnson
30ed563810 Retrofit consoleserver and make shellserver
Provide a common 'shellserver' capability cloned off of 'consoleserver'.
This will enable the concept of per-user shells with option for multiple
shells per.  Each user will have their own set of shell sessions rather
than shared across users.  Can revisit in future if sharing between
users is desired.
2016-01-05 15:34:52 -05:00
Jarrod Johnson
dfc1e32546 Merge branch 'sshconsole' of github.com:jjohnson42/confluent into sshconsole 2015-11-03 09:06:59 -05:00
Jarrod Johnson
d03ca6eafe Add internal resource for 'shell' 2015-10-28 10:50:27 -04:00
Jarrod Johnson
4d148751e5 Add a module for ssh 'console' API
Create a module that does ssh and treats it like
a console.  The plan is to have a cliserver.py to
behave in a manner resembling consoleserver.py, but
with option to have multiple distinct sessions per
target.
2015-10-28 10:50:22 -04:00
Jarrod Johnson
d8c3b2f267 Merge pull request #48 from jjohnson42/debugsignals
Add facility to dump trace to log
2015-10-28 10:46:09 -04:00
Jarrod Johnson
f02c74cce0 Add facility to dump trace to log
If confluent gets stuck, provide a debug facility
to sample where it is stuck.  Sending confluent
SIGUSR1 will now cause /var/log/confluent/hangtraces
to get written to.
2015-10-28 10:45:18 -04:00
Jarrod Johnson
36dd493021 Merge branch 'sshconsole' of github.com:jjohnson42/confluent into sshconsole 2015-10-21 16:48:54 -04:00
Jarrod Johnson
a3e5388303 Add a module for ssh 'console' API
Create a module that does ssh and treats it like
a console.  The plan is to have a cliserver.py to
behave in a manner resembling consoleserver.py, but
with option to have multiple distinct sessions per
target.
2015-10-21 16:48:41 -04:00
Jarrod Johnson
5485ef36bf Merge pull request #47 from jjohnson42/amendconsoleapi
Amend console API
2015-10-21 16:46:32 -04:00
Jarrod Johnson
1cf238708f Amend console API
The console API had a 'wait_for_data' which will never be used.
Also change __init__() so that it can be called via super() to
allow working around IDE complaints.
2015-10-21 16:44:09 -04:00
Jarrod Johnson
2ff97b93ef Add a module for ssh 'console' API
Create a module that does ssh and treats it like
a console.  The plan is to have a cliserver.py to
behave in a manner resembling consoleserver.py, but
with option to have multiple distinct sessions per
target.
2015-10-21 13:42:31 -04:00
Jarrod Johnson
80aa2c477a Merge pull request #46 from jjohnson42/handleunicodestringoutput
Handle unicode string from a console plugin
2015-10-21 13:26:32 -04:00
Jarrod Johnson
9868e55958 Handle unicode string from a console plugin
If a console plugin feels like outputting data
in a unicode string, accept that data by encoding
to utf-8.
2015-10-21 13:24:41 -04:00
Jarrod Johnson
7a8fbe7d62 Merge pull request #45 from jjohnson42/fixnullclient
Fixnullclient
2015-10-21 10:33:50 -04:00
Jarrod Johnson
52aaeef506 Have server avoid sending empty data
While the client can handle it now, have the server
avoid needless processing of '' data from a console
provider.  Address it at the deepest level (the
tlvdata implementation) and a place higher up the stack
to avoid hits to log and such.
2015-10-21 10:30:41 -04:00
Jarrod Johnson
be8d82c6c1 Client behavior fix when server sends 0 data
If the server sends zero data, client could hang as it does recv(0).  Fix this by
returning None in that scenario.
2015-10-21 10:22:49 -04:00
Jarrod Johnson
a83583a56d Merge pull request #44 from jjohnson42/master
Merge fixes in prep for 1.2.0 tag
2015-10-19 15:25:11 -04:00
Jarrod Johnson
f906cebca3 Merge remote-tracking branch 'upstream/master' 2015-10-19 15:23:19 -04:00
Jarrod Johnson
e153e8acd0 Correct indentation in nodeeventlog
Mistakes were present in the whitespace for nodeeventlog, apply correct indentation.
2015-10-19 14:27:11 -04:00
Jarrod Johnson
dec0543ce3 Fix nodelist formatting of error
Error needed a newline after message to be clear.
2015-10-19 14:23:02 -04:00
Jarrod Johnson
204f6de7e9 Fix missing 'nodeeventlog' command in packaging
When packaging, nodeeventlog was missed. Fix the setup.py.tmpl
to include the missing script.
2015-10-19 14:14:54 -04:00
Jarrod Johnson
76906c191b Replace '/' in '-' in ipmi names
'/' confuses our '/' delimited namespace.  Use '-'
instead.  '_or_' was considered, but other meanings
could be applied other than '/'.
2015-10-19 14:13:02 -04:00
Jarrod Johnson
61a0a66486 Fix nodelist handling of bad noderange
When attributes were specified with an incorrect noderange
it was failing to report the noderange error.  If that were
specifically addressed, it would then proceed to erroneously
complain about valid attribute names.
2015-10-19 14:09:37 -04:00
Jarrod Johnson
597bc9413f Merge pull request #43 from jjohnson42/master
Change to versioning derivation from git data
2015-10-19 14:07:21 -04:00
Jarrod Johnson
e53a9f83f4 Change to versioning derivation from git data
Rather than manually curate the VERSION, use git tags
and auto-create intermediate builds with unique identifiers.
Identify both number of commits to indicate order and the git
short rev to see which rev matches.
2015-10-19 14:06:59 -04:00
Jarrod Johnson
31a191cb10 Merge pull request #42 from jjohnson42/fixpidfile
Fix pid file behavior on exit
2015-10-15 09:44:35 -04:00
Jarrod Johnson
8d566c1795 Merge pull request #40 from jufm/timeout
Add support for event ack timeout setting.
2015-10-15 09:44:13 -04:00
Jarrod Johnson
2c2884f80f Fix pid file behavior on exit
Previous change failed to correct the sense of the 'doexit'
function.
2015-10-15 09:39:44 -04:00
Allan Vidal
fe4797857d Add support for event ack timeout setting. 2015-10-15 09:41:13 -03:00
Jarrod Johnson
e90204cc4d Merge pull request #41 from jjohnson42/fixpidfile
Fix pid file creation
2015-10-14 15:52:46 -04:00
Jarrod Johnson
d4828b2115 Fix pid file creation
The windows support to 'gracefully' deal with no fcntl
incorrectly broke fcntl usage under linux in main.  Fix
the check to be accurate.
2015-10-14 15:30:43 -04:00
Jarrod Johnson
7b26d2edfb Merge pull request #39 from jjohnson42/fixnodelistnoarg
Fix bad or missing noderange behavior in nodelist
2015-10-14 11:10:34 -04:00
Jarrod Johnson
0bb0368d07 Fix bad or missing noderange behavior in nodelist
nodelist command would show 'help' with no arguments, but
natural expectation is to list all nodes.  Adjust to match
that expectation.  If a noderange was somehow problematic,
the output was not appropriate, this too is addressed.
2015-10-14 11:07:31 -04:00
Jarrod Johnson
1467e1f172 Merge pull request #38 from jufm/rundir
Fix unix socket dir creation
2015-10-14 11:05:21 -04:00
Juliana Motira
06f22e7acb Fix unix socket dir creation 2015-10-14 09:53:14 -03:00
Jarrod Johnson
8779f1c27f Merge pull request #37 from jufm/stringfix
Fix encoded string problem in InputNTPServer
2015-10-13 14:56:55 -04:00
Juliana Motira
2245e53ff1 Fix encoded string problem in InputNTPServer 2015-10-13 15:51:37 -03:00
Jarrod Johnson
99d1edcdef Merge pull request #36 from jjohnson42/versionbump
Bump version to 1.2
2015-10-13 14:16:44 -04:00
Jarrod Johnson
fbca02e262 Bump version to 1.2 2015-10-13 14:16:02 -04:00
Jarrod Johnson
d533321d55 Merge pull request #35 from jjohnson42/addcommands
Add nodeconsole and nodelist commands
2015-10-13 14:14:59 -04:00
Jarrod Johnson
0b7b713f3f Add nodeconsole and nodelist commands
nodeconsole provides a wrapper for confetty offering logical
tab completion for console specifically as well as help
text to explain critical info about using nodeconsole.
nodelist provides functionality analagous to nodels in
xCAT 2.x codebase
2015-10-13 14:12:43 -04:00
Victor Hu
865545b8d1 Merge pull request #34 from jjohnson42/confluentpath
Have confluent client do default path
2015-10-12 21:37:45 -04:00
Jarrod Johnson
258e257939 Have confluent client do default path
When installing package, put a profile.d change
such that confluent is in the default path.
2015-10-12 17:00:40 -04:00
Jarrod Johnson
127fc59195 Merge pull request #33 from jjohnson42/master
Fix valid noderange character
2015-10-09 15:01:36 -04:00
Jarrod Johnson
8c4d33db92 Merge remote-tracking branch 'upstream/master' 2015-10-09 15:00:35 -04:00