.. ========================================================================== = = File: build_ubuntu_packaging.rst = Date: 10-May-2010 = Author: Hugh Secker-Walker = Description: Dynamic steps updating and installing packages on an Ubuntu system = = This file is part of Onyx http://onyxtools.sourceforge.net = = Copyright 2010 The Johns Hopkins University = = Licensed under the Apache License, Version 2.0 (the "License"). = You may not use this file except in compliance with the License. = You may obtain a copy of the License at = http://www.apache.org/licenses/LICENSE-2.0 = = Unless required by applicable law or agreed to in writing, software = distributed under the License is distributed on an "AS IS" BASIS, = WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or = implied. See the License for the specific language governing = permissions and limitations under the License. = ========================================================================== Packaging the Ubuntu Appliance ============================== Once the Ubuntu system is configured, it needs to be packaged up in a ZIP file. Verify system access -------------------- Make sure the Ubuntu system can boot and you know the password of the adminstrative account. If it's running, shut it down:: root@OnyxUbuntu32:~# shutdown -h now In the VMware player the status of the OnyxUbuntu32 system should be *Powered off*. Double click the system to boot it up. Once the login prompt displays, along with the system IP, go to a terminal and SSH to the system:: $ ssh onyxadm@172.16.166.133 onyxadm@172.16.166.133's password: Make sure you remember the password; it will have to be provided along with the ZIP file so that users can administer the system. Cleanup just in case there's unwanted cruft lying around:: onyxadm@OnyxUbuntu32:~$ sudo apt-get clean [sudo] password for onyxadm: onyxadm@OnyxUbuntu32:~$ sudo apt-get autoremove Reading package lists... Done Building dependency tree Reading state information... Done 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Shut down:: onyxadm@OnyxUbuntu32:~$ sudo shutdown -h now Verify VMware Settings ---------------------- Now is a good time to double check all the **Settings** for the system. In particular: **Sharing** Folders are **not** shared. Applications are **not** shared. **Processor & RAM** Set these as you see fit. On a modern machine, 2 virtual processors and 768 MB of RAM is reasonable. **Hard Disks** Run the *Clean Up Disk* action to shrink the size of the appliance. **CDs & DVDs** Make sure the device is *Connected* and configured to *Automatically detect CD/DVD drive* Create ZIP file --------------- Be sure to quit the VMware player application, and wait for it to finish writing files (can happen even after the UI is gone). On a Mac, navigate to the folder where the Ubuntu system is saved, e.g. ``~/Documents/Virtual Machines/OnyxUbuntu32.vmwarevm``. Its size should be about 1.7 GB. Right-click on the folder and choose the *Compress "OnyxUbuntu32.vmwarevm"* item. It will take at least couple of minutes. If you're lucky the ZIP file will be about 610 MB. That's it. The ZIP file, the password for the onyxadm account, and the installation instructions for the :ref:`ubuntu-appliance-for-vmware` are all that someone needs to start using this appliance.