Difference between revisions of "Deployment Platform/XO reference distribution"
Line 1: | Line 1: | ||
== Summary == | == Summary == | ||
− | This is [[Harmonic_Distribution/Deployment|one of possible]] reference implementations of [[Harmonic Distribution]] based solutions. The goal is creating Sugar based downstream distribution to run on OLPC XO laptops by end-users. | + | This is [[Harmonic_Distribution/Deployment|one of the possible]] reference implementations of [[Harmonic Distribution]] based solutions. The goal is creating a Sugar based downstream distribution to run on OLPC XO laptops by end-users. The created reference implementation is intended to be a template for final deployment distributions. |
== Overview == | == Overview == | ||
− | The task is | + | The task is to create an XO image capable of further support. |
− | + | The image will be composed using the [http://wiki.laptop.org/go/OSBuilder olpc-os-builder] utility and will be populated with the following content: | |
'''System packages''' | '''System packages''' | ||
− | : | + | :Packages will be installed from the following sources: |
:* stock Fedora repositories, | :* stock Fedora repositories, | ||
:* [http://mock.laptop.org/cgit/ stable OLPC repositories], | :* [http://mock.laptop.org/cgit/ stable OLPC repositories], | ||
− | :* one of [[Template:Sweets_Distribution_Linkbar|Sweets Distribution]] repositories (for now, | + | :* one of the [[Template:Sweets_Distribution_Linkbar|Sweets Distribution]] repositories (for now, only the [[Platform_Team/Sweets_Distribution/Factory|Factory]] repository is available), |
− | :* [[#Deployment_repository|deployment repository]] to keep packages specific | + | :* the [[#Deployment_repository|deployment repository]] to keep packages specific to a particular deployment. |
'''Initial Sugar Activities''' | '''Initial Sugar Activities''' | ||
− | :[[Harmonic Distribution]] based | + | :[[Harmonic Distribution]] based solutions are based on [[Sugar Network]], which makes all Sugar Activities accessible from a local school server or an Internet located one. Nonetheless, it is useful to have some first-time activities already included with the image. |
− | : Activities will be downloaded from the Sugar Network and placed | + | : Activities will be downloaded from the Sugar Network and placed in the {{Code|~/Activities}} directory in the image. |
'''Deployment configuration''' | '''Deployment configuration''' | ||
− | :This is how final systems will be initially configured and supported afterwards. All deployment configuration is placed | + | :This is how final systems will be initially configured and supported afterwards. All deployment configuration is placed in a [[#Deployment_package|meta package]] in the [[#Deployment_repository|deployment repository]]. This meta package contains dependencies and configuration files for all other packages needing to be installed on final systems. Further, if there is a need to change configuration on already installed systems, the meta package will be updated and spread among users. |
== Start new implementation == | == Start new implementation == | ||
− | These are step-by-step instruction how to create new deployment distribution | + | These are step-by-step instruction on how to create a new deployment distribution based on this reference implementation. |
=== Deployment repository === | === Deployment repository === | ||
− | Make sure you have Fedora repository accessible from building host and end-users. If you are looking for building and hosting environment, try [[Platform_Team/Open_Build_System|packages.sugarlabs.org]] which is an instance of [http://www.open-build-service.org/ Open Build Service]. | + | Make sure you have the Fedora repository accessible from building host and end-users. If you are looking for a building and hosting environment, try [[Platform_Team/Open_Build_System|packages.sugarlabs.org]], which is an instance of [http://www.open-build-service.org/ Open Build Service]. |
− | If you are using [[Platform_Team/Open_Build_System|packages.sugarlabs.org]], create new project and add Fedora | + | If you are using [[Platform_Team/Open_Build_System|packages.sugarlabs.org]], create a new project and add the Fedora 14 repository from the [[Sweets Distribution]] project your implementation is based on. For example, there is [https://packages.sugarlabs.org/project/show?project=SweetsDistribution%3AFactory%3AReferenceXO reference project] based on [https://packages.sugarlabs.org/project/show?project=SweetsDistribution%3AFactory SweetsDistribution:Factory] repositories. |
=== Deployment package === | === Deployment package === |
Revision as of 17:40, 18 August 2012
Summary
This is one of the possible reference implementations of Harmonic Distribution based solutions. The goal is creating a Sugar based downstream distribution to run on OLPC XO laptops by end-users. The created reference implementation is intended to be a template for final deployment distributions.
Overview
The task is to create an XO image capable of further support.
The image will be composed using the olpc-os-builder utility and will be populated with the following content:
System packages
- Packages will be installed from the following sources:
- stock Fedora repositories,
- stable OLPC repositories,
- one of the Sweets Distribution repositories (for now, only the Factory repository is available),
- the deployment repository to keep packages specific to a particular deployment.
Initial Sugar Activities
- Harmonic Distribution based solutions are based on Sugar Network, which makes all Sugar Activities accessible from a local school server or an Internet located one. Nonetheless, it is useful to have some first-time activities already included with the image.
- Activities will be downloaded from the Sugar Network and placed in the
~/Activities
directory in the image.
Deployment configuration
- This is how final systems will be initially configured and supported afterwards. All deployment configuration is placed in a meta package in the deployment repository. This meta package contains dependencies and configuration files for all other packages needing to be installed on final systems. Further, if there is a need to change configuration on already installed systems, the meta package will be updated and spread among users.
Start new implementation
These are step-by-step instruction on how to create a new deployment distribution based on this reference implementation.
Deployment repository
Make sure you have the Fedora repository accessible from building host and end-users. If you are looking for a building and hosting environment, try packages.sugarlabs.org, which is an instance of Open Build Service.
If you are using packages.sugarlabs.org, create a new project and add the Fedora 14 repository from the Sweets Distribution project your implementation is based on. For example, there is reference project based on SweetsDistribution:Factory repositories.
Deployment package
Use reference package as a template. Copy its source and tune for local needs. Look for comments for better understanding.
Structure of reference package is:
etc/
These files will be copied as-is. Place here all configuration files you need to support afterwards.post.d/*.sh
These files will be executed right after installing package. Place here routines that can't be represent by configuration files.image/
olpc-os-builder files to create XO images.Makefile
Handy makefile to create sources tarball.deployment.spec
RPM spec file to create package.
This is the only package that will be installed implicitly after including sweets
olpc-os-builder module. Thus, add to deployment.spec
all dependencies final systems require. Note that there is no need in installing Sugar Activities or its dependencies, these routines will be handled automatically after setting offline_activities
option in olpc-os-builder configuration file.
Put sources to the new git project and commit them.
To create package tarball, call the command:
make dist
If you are using packages.sugarlabs.org, call osc utility to upload newly create sources tarball and spec file to OBS.
Create images
First of all, attach proper Sweets Distribution repository and install olpc-os-builder
package from there. This package is different from upstream, it contains additional modules (see image/*.ini
files for details).
Then, go to image/
directory and call one the the following commands to create images:
olpc-os-builder --additional-defaults common.ini xo-1.ini olpc-os-builder --additional-defaults common.ini xo-1.5.ini
Consult olpc-os-builder's home page for more information.
Post-install support
Post installation supporting is all about update packages in deployment repository, e.g., update configuration in deployment package. Then, using one of deployment scenarios, spread package updates among users.
Try reference implementation
To try reference implementation on an XO laptop, download one of prebuilt images and proceed below instructions to flash it. Note that images were built using recent development version of software. So, images might be used to easily test recent changes.
XO-1
- First, ensure that your laptop is unlocked.
- Download os.img and os.crc files to the root directory of a USB stick or SD card.
- Drop to the "ok" prompt by pressing (Esc) repeatedly during boot.
- Type the command:
copy-nand u:\xo.img
for a USB stick orcopy-nand sd:\xo.img
for a SD card followed by (enter). - Wait for the display to fill in with color and the "ok" prompt to return
- Type the command
reboot
followed by (enter) - The XO will reboot, finish writing, reboot itself, and take you to the naming and color choice process
- During the reboots, keep the charger connected to allow OFW to self-update
XO-1.5
- First, ensure that your laptop is unlocked.
- Download os.zd to the root directory of a USB stick
- Drop to the "ok" prompt by pressing (Esc) repeatedly during boot
- Type the command:
fs-update u:\xo.zd
followed by (enter) - Wait for the display to fill in with color and the "ok" prompt to return
- Type the command
reboot
followed by (enter) - The XO will reboot and take you to the naming and color choice process
Downstreams
The list of solutions based on this reference implementation: