Smart Repository Setup: Difference between revisions

From Yocto Project
Jump to navigationJump to search
(Add page about smart repo setup)
 
(Replace with link to appropriate dev manual section)
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
{| style="color:black; background-color:#ffcccc" width="100%" cellpadding="10" class="wikitable"
{| style="color:black; background-color:#ffffcc" width="100%" cellpadding="10" class="wikitable"
|'''NOTE:''' smart replaces zypper for the upcoming 1.4 version. For 1.3 and older, please see [[Zypper Repository Setup]].
|'''NOTE:''' smart replaces zypper with Yocto Project 1.4 and newer. For 1.3 and older, please see [[Zypper Repository Setup]].
|}
|}


== Requirements ==
Please see the '''[http://www.yoctoproject.org/docs/current/dev-manual/dev-manual.html#setting-up-runtime-package-management Setting Up Runtime Package Management]''' section of the Development Manual.
 
Setting up a zypper repository from the rpm files created during a Poky build is fairly straightforward. You will need:
 
* Apache 2 installed and configured (may not need too much configuration); other http servers are available
* createrepo installed
 
== Steps ==
 
1. Add the directory to your apache config (/etc/httpd/conf/httpd.conf):
<VirtualHost *:80>
  ....
    Alias /rpm /path/to/tmp/deploy/rpm
    <Directory "/path/to/tmp/deploy/rpm/">
      Options +Indexes
    </Directory>
</VirtualHost>
 
2. Reload apache configuration (<code>service httpd reload</code> as root on Fedora)
 
3. cd to the tmp/deploy/rpm directory
cd /path/to/tmp/deploy/rpm/
 
4. Create the repository data (if you're updating, add --update to save time)
createrepo .
 
5. If you're using SELinux you need to label the files accessible via apache:
chcon -R -h -t httpd_sys_content_t .
 
6. On the target machine add the repo to smart (where somealias is a local alias for the repo):
<nowiki>smart channel --add somealias type=rpm-md baseurl=http://server.name/rpm</nowiki>
 
7. Fetch the repository information:
smart update

Latest revision as of 10:07, 1 October 2013

NOTE: smart replaces zypper with Yocto Project 1.4 and newer. For 1.3 and older, please see Zypper Repository Setup.

Please see the Setting Up Runtime Package Management section of the Development Manual.