Bug 766256

Summary: skynet client: .ini file name should not be hardcoded
Product: [Community] PressGang CCMS Reporter: Joshua Wulf <jwulf>
Component: CSProcessorAssignee: Lee Newson <lnewson>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 1.xCC: jwulf, lcarlon
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 0.16.0 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-03-20 01:43:55 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Joshua Wulf 2011-12-11 11:00:29 UTC
[jwulf@gaura csprocessor-data.sql]$ skynet push --config ~/.config/skynet-skynet.ini -c -n ~/Work/EDS/EDS\ GSG-spec
Skynet client version: 0.15.0
Loading configuration from /home/jwulf/.config/skynet-skynet.ini/skynet.ini

Error: skynet.ini does not exist in the specified location!


Kind of defeats the purpose of having the ability to specify the configuration file name. 

It should accept a fully qualified filename, not just an alternate directory path.

Comment 1 Joshua Wulf 2011-12-11 11:16:51 UTC
So if the path ends in .ini then the skynet client should assume it's a full file path and filename. If it ends in something other than .ini, then it can do this:

1. If the config argument ends in ".ini" then use it as is.
2. If the config argument ends in "/" then append skynet.ini and use that.
3. If the filepath does not ends in "/" or ".ini" then:
  stat the config argument to see if a file with that path/name exists, if it does, use that file.
  If no file exists, then add "/skynet.ini" to the config argument and use that.

Comment 2 Lee Newson 2012-01-31 05:52:36 UTC
Fixed in client version 0.16.0.

The client used to enforce the use of the name skynet.ini and as such custom file names or different configurations were harder to use. Now the client will accept any file that follows the above 4 rules.