On Wed, Jan 27, 2010 at 9:24 AM, Michal Fojtik mfojtik@redhat.com wrote:
Hi,
Just addded support for additional parameters for deltacloudd with some basic validation. So now you could do:
./bin/deltacloudd ec2 -p3030
server/bin/deltacloudd | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/server/bin/deltacloudd b/server/bin/deltacloudd index 33f7108..70da01b 100755 --- a/server/bin/deltacloudd +++ b/server/bin/deltacloudd @@ -1,6 +1,6 @@ #!/usr/bin/env ruby
-if ( ARGV.size != 1 ) +if (ARGV.empty? || (!ARGV.empty? && ![:ec2, :rhevm, :mock, :rimu, :rackspace].include?(ARGV[0].to_sym))) puts "Usage: deltacloudd <drivername>" exit 1 end --
This is an improvement over current, but NACK for now. We talked in private about a few ideas to make this more flexible, so lets not push this until the rework. Main changes are: * Don't rely on driver being first param with no flag, we should have a standard flag (and both short (-) and long (--) versions) so we can just look for the presence of the one we care about. * Wrap the script/server (commands/server) code so deltacloudd -h will output our param help along with the standard help