How I work with IPS repos from the slim_source gate

Oh, how I knew System V packages...

Back in the bad old days before ON and slim_source had moved to building only IPS packages, one could pkgadd -d <location> SUNW<package> and easily drop their test code on a machine. Now with the move to IPS packages getting the test code to a machine can be much easier but set up is a bit more complicated. There is a tool to do this automatically for ON called onu (see it in action here). However, for slim_source it is pretty easy to do manually -- once you know what you need to do.

Let's pretend everything's happy what do I do?

  1. Make a backup boot environment: beadm create <new_BE_name>
  2. Set your system-free -- uninstall the entire incorporation: pkg uninstall entire
  3. Add your new repository: pkg set-publisher -P -g file:///path/to/slim_source/pacakge/<architecture>/repo.redist install-nightly
  4. Install the new install consolidation incorporation: pkg install pkg://install-nightly/consolidation/install/install-incorporation
  5. Install you new package! pkg install pkg://install-nightly/install/installadm

Okay, let's not pretend everything's happy...

Okay, so the above is a pretty simple recipe and usually things will just work. However there are some cases were stuff gets a bit twisted up.

What if I have a test system not running the latest build?

With the change to IPS packages a new file was introduced in slim_source to tie the repository nightly(1) builds to a build number. If you are not running at least that build, you'll get a constraint error from IPS. You can change the build number in that file; or you can back-publish an install-incorporation to support the build(s) you need. To back-publish do the following: echo "" | pkgsend -s file:///path/to/slim_source/pacakge/<architecture>/repo.redist publish consolidation/install/install-incorporation-AT-0.5-DOT-11,5.11-<build#>

Then on the client may end up with a bit of funkiness. I've had to then use the full FMRI of the install-incorporation I want (e.g. pkg install pkg://install-nightly/consolidation/install/install-incorporation-AT-0.5.11.5-DOT-11,5.11-142:20100714T165848Z) and do manual dependency installation (i.e. IPS would say no package found for pkg://install-nightly/system/library/install and again I would have to install that package by full FMRI).

What if I don't want to use file:// paths?

You can stand-up these nightly(1) generated repositories just the same as any other. If you do not have NFS access on your test system this might work well. All one needs to do is the following: /usr/lib/pkg.depotd -d /path/to/slim_source/pacakge/<architecture>/repo.redist then you'll be running the repo. on port 8080 of your localhost; this is a great way to view the catalog too if you need the whole package FMRI.

P.S.
A big thanks to Rich Lowe for help understanding some of this, as it's certainly a new world out there!

Comments:

Well, some out there might call it "the good old days"...

:-)

Posted by Volker A. Brandt on August 07, 2010 at 04:12 AM MDT #

Post a Comment:
Comments are closed for this entry.
About

clayb

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today