Keith,
Thanks for the review.
John
On 01/14/11 09:50 AM, Keith Mitchell wrote:
Hi John,
In the interest of considering similar version relevant changes in the
future, would it make more sense to have "check_image_version" in
setup-image.sh return one of three results:
0 - image version matches host version
<0 - image version is older than host server
>0 - image version is newer than host server
I'll think about which way makes more sense.
Alternatively (and perhaps better) check-server-setup could print the
version number to stdout. Ideally, this is an easily parseable number.
And the installadm code could then potentially have 'if' blocks or
'case' switches such as the below pseudo-code:
if version == 0:
handle_version_0()
elif version > 0 and version <= 5:
handle_versions_1_to_5()
else:
handle_version_gt_5()
pre_pkg_img_mod.py:
254-255: Catching the exception in this fashion means DC will continue
as if nothing is wrong. I would expect DC to abort if it can't record
necessary version information into the image, so I suggest removing
the try/except here.
Sounds good.
ai_get_manifest.py:
607-616: The use of 'find' is generally unnecessary in Python. For
example, this whole block could be:
for line in data.splitlines():
key, match, value = line.partition("=")
if match and key == "IMAGE_VERSION": # 'match' will be an empty
string unless the line had an '='
return value
return '1.0'
I seem to always be learning in this language. Thanks!!
- Keith
On 01/13/11 07:24 PM, John Fischer wrote:
All,
I have updated the webrev to match the current discussion and
testing.
The significant change is that there is now an impact on DC.
Essentially I introduce a version file into the auto-install
common package. This version file is copied into the generated
ISO .image_file without the comments from the file. This was
needed so that we could tell if the ISO being used for a service
was old or new and act accordingly when setting up a new
service.
The new webrev is available at:
http://cr.opensolaris.org/~johnfisc/webserver/webserver-design-4/
http://cr.opensolaris.org/~johnfisc/webserver/webserver-design-orig-4-diff/
The webrev that tracks the differences between review round 3 and
round 4 is located at:
http://cr.opensolaris.org/~johnfisc/webserver/webserver-design-diff-3-4/
Thanks,
John
_______________________________________________
caiman-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/caiman-discuss
_______________________________________________
caiman-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/caiman-discuss