Solaris IPS: Image Packaging System

Related tags

solaris
Overview

Solaris Image Packaging System

Introduction

The image packaging system (IPS) is a software delivery system with interaction with a network repository as its primary design goal. Other key ideas are: safe execution for zones and other installation contexts, use of ZFS for efficiency and rollback, preventing the introduction of incorrect or incomplete packages, and efficient use of bandwidth.

Prerequisites

IPS development requires additional external dependencies, which on Solaris 11 are provided by the list of packages found in src/pkg/external_deps.txt.

Build, Testing and Deployment

Once all dependency packages are installed, IPS source can be built by the following command:

  $ cd src; make install

The above will generate a proto directory under the root directory. Inside the proto directory, the build_i386 directory contains Python version-specific builds; root_i386 contains the complete build with the directory structure preserved.

Generally, testing of the new build can be done by the following command:

  $cd src/tests; sudo ./run.py -j 8

The above will run all test cases in 8 parallel processes. Other options are also available by typing ./run.py -h.

Tests running can also be done by using make:

  $cd src; sudo make test

Make targets test-27 and test-34 are available for testing specific Python versions.

IPS applications and libraries can be packaged and published into an IPS repository using:

  $cd src; make packages;

The above command generates IPS related packages and publishes them into packages/i386/repo on an x86-based system.

Usage Examples

  • Example 1 Create an Image With Publisher Configured

    Create a new, full image, with publisher example.com, stored at /aux0/example_root.

    $ pkg image-create -F -p example.com=http://pkg.example.com:10000 \
    /aux0/example_root
  • Example 2 Create an Image With No Publisher Configured

    Create a new, full image with no publishers configured at /aux0/example_root.

    $ pkg image-create -F /aux0/example_root
  • Example 3 Install a Package

    Install the latest version of the widget package in the current image.

    $ pkg install application/widget
    $ pkg set-publisher -g http://www.example.com/repo example.com
  • Example 5 Add and Automatically Configure a Publisher

    Add a new publisher with a repository located at /export/repo using automatic configuration.

    $ pkg set-publisher -p /export/repo

For more examples, please refer to List of References below or man page pkg(1) on Solaris operating system.

How to Contribute

Please refer to CONTRIBUTING for details.

License

The Image Packaging System is primarily distributed under the terms of the CDDL (Common Development and Distribution License), with a few portions covered by BSD-style or MIT-style licenses.

Refer to LICENSE-CDDL, LICENSE-CPIO (applies to src/modules/cpiofile.py), and LICENSE-MINISAT (applies to src/modules/solver/*) for details.

List of References

  1. Packaging and Delivering Software With the Image Packaging System in Oracle© Solaris 11.3

  2. Introducing the Basics of Image Packaging System (IPS) on Oracle Solaris 11

  3. Oracle Solaris 11 Cheatsheet for Image Packaging System

Issues
  • Required dependencies on GNU/Linux

    Required dependencies on GNU/Linux

    What are the dependencies needed to build pkg?

    opened by amreo 0
  • setup.py install fails when building repo cloned from Github

    setup.py install fails when building repo cloned from Github

    Trying to build the IPS repo cloned from Github results in exception in pydates:

    $ python3.7 ./src/setup.py install
    running install
    running build
    running build_py
    Traceback (most recent call last):
      File "/home/vkotal/solaris-ips/src/pydates", line 36, in <module>
        repo = localrepo.instance(myui, cmdutil.findrepo(os.getcwd()), False)
      File "/usr/lib/python2.7/dist-packages/mercurial/localrepo.py", line 2810, in instance
        localpath = util.urllocalpath(path)
      File "/usr/lib/python2.7/dist-packages/mercurial/util.py", line 2947, in urllocalpath
        return url(path, parsequery=False, parsefragment=False).localpath()
      File "/usr/lib/python2.7/dist-packages/mercurial/util.py", line 2726, in __init__
        if hasdriveletter(path) or path.startswith('\\\\'):
    AttributeError: 'NoneType' object has no attribute 'startswith'
    

    This is because it constructs a Mercurial repository object from cmdutil.findrepo(os.getcwd()). Of course, the repo cloned from Github is Git repo and not a Mercurial repo as the findrepo() expects, therefore it returns None.

    opened by vladak 2
  • Traceback in cli.t_pkg_depotd.py TestPkgDepot.test_empty_incorp_depend

    Traceback in cli.t_pkg_depotd.py TestPkgDepot.test_empty_incorp_depend

    Running the test-suite on Solaris 11.4, I see a test failure in TestPkgDepot.test_empty_incorp_depend which was not there before https://github.com/oracle/solaris-ips/commit/729c95dff6f40fc4b8dae84c8381c96db60cc8d1

    The problem is in CatalogInterface.gen_allowed_packages() in that md.get("actions") always returns an empty set and so the loop's else: clause is entered without f ever having been assigned.

    I fixed it with:

    --- a/src/modules/server/api.py
    +++ b/src/modules/server/api.py
    @@ -159,11 +159,8 @@ class CatalogInterface(_Interface):
                             allowed.setdefault(pkg_name, [])
                             for v, entries in cat.entries_by_version(pkg_name,
                                 info_needed=cat_info, pubs=pubs):
    -                                for f, fa in (
    -                                    (f, fa)
    -                                    for f, md in entries
    -                                    for fa in md.get("actions", misc.EmptyI)
    -                                ):
    +                                for f, md in entries:
    +                                    for fa in md.get("actions", misc.EmptyI):
                                             if not fa.startswith("set"):
                                                     continue
    
    @@ -180,7 +177,7 @@ class CatalogInterface(_Interface):
                                                     del a
                                                     break
                                             del a
    -                                else:
    +                                    else:
                                             allowed[pkg_name].append((f, sn))
    
                     sort_ver = itemgetter(0)
    

    However, it does seem that there is a bigger problem here since I can't determine how the set actions that are being checked for could ever be returned with this test (same with the code before this latest commit).

    opened by citrus-it 1
Owner
Oracle
Open Source at Oracle
Oracle
Python dependency management and packaging made easy.

Poetry: Dependency Management for Python Poetry helps you declare, manage and install dependencies of Python projects, ensuring you have the right sta

Poetry 16.8k Oct 22, 2021
Conan - The open-source C/C++ package manager

Conan Decentralized, open-source (MIT), C/C++ package manager. Homepage: https://conan.io/ Github: https://github.com/conan-io/conan Docs: https://doc

Conan.io 5.3k Oct 22, 2021
A set of tools to keep your pinned Python dependencies fresh.

pip-tools = pip-compile + pip-sync A set of command line tools to help you keep your pip-based packages fresh, even when you've pinned them. You do pi

Jazzband 5.3k Oct 22, 2021
Python PyPi staging server and packaging, testing, release tool

devpi: PyPI server and packaging/testing/release tool This repository contains three packages comprising the core devpi system on the server and clien

null 500 Oct 23, 2021
The Python package installer

pip - The Python Package Installer pip is the package installer for Python. You can use pip to install packages from the Python Package Index and othe

Python Packaging Authority 7.5k Oct 23, 2021
Install and Run Python Applications in Isolated Environments

pipx — Install and Run Python Applications in Isolated Environments Documentation: https://pipxproject.github.io/pipx/ Source Code: https://github.com

null 4.2k Oct 22, 2021
A Poetry plugin for dynamically extracting the package version.

Poetry Version Plugin A Poetry plugin for dynamically extracting the package version. It can read the version from a file __init__.py with: # __init__

Sebastián Ramírez 148 Oct 9, 2021
:package: :fire: Python project management. Manage packages: convert between formats, lock, install, resolve, isolate, test, build graph, show outdated, audit. Manage venvs, build package, bump version.

THE PROJECT IS ARCHIVED Forks: https://github.com/orsinium/forks DepHell -- project management for Python. Why it is better than all other tools: Form

DepHell 1.7k Oct 22, 2021
Python Development Workflow for Humans.

Pipenv: Python Development Workflow for Humans [ ~ Dependency Scanning by PyUp.io ~ ] Pipenv is a tool that aims to bring the best of all packaging wo

Python Packaging Authority 22.4k Oct 24, 2021
The Fast Cross-Platform Package Manager

The Fast Cross-Platform Package Manager part of mamba-org Package Manager mamba Package Server quetz Package Builder boa mamba Mamba is a reimplementa

Mamba 2.3k Oct 24, 2021
The Python Package Index

Warehouse Warehouse is the software that powers PyPI. See our development roadmap, documentation, and architectural overview. Getting Started You can

Python Packaging Authority 2.8k Oct 24, 2021
An installation and dependency system for Python

Pyflow Simple is better than complex - The Zen of Python Pyflow streamlines working with Python projects and files. It's an easy-to-use CLI app with a

David O'Connor 904 Oct 19, 2021
A PyPI mirror client according to PEP 381 http://www.python.org/dev/peps/pep-0381/

This is a PyPI mirror client according to PEP 381 + PEP 503 http://www.python.org/dev/peps/pep-0381/. bandersnatch >=4.0 supports Linux, MacOSX + Wind

Python Packaging Authority 263 Oct 17, 2021
A PyPI mirror client according to PEP 381 http://www.python.org/dev/peps/pep-0381/

This is a PyPI mirror client according to PEP 381 + PEP 503 http://www.python.org/dev/peps/pep-0381/. bandersnatch >=4.0 supports Linux, MacOSX + Wind

Python Packaging Authority 262 Oct 11, 2021
local pypi server (custom packages and auto-mirroring of pypi)

localshop A PyPI server which automatically proxies and mirrors PyPI packages based upon packages requested. It has support for multiple indexes and t

Michael van Tellingen 372 Aug 29, 2021
A flexible package manager that supports multiple versions, configurations, platforms, and compilers.

Spack Spack is a multi-platform package manager that builds and installs multiple versions and configurations of software. It works on Linux, macOS, a

Spack 2.3k Oct 25, 2021
A PDM plugin that packs your packages into a zipapp

pdm-packer A PDM plugin that packs your packages into a zipapp Requirements pdm-packer requires Python >=3.7 Installation If you have installed PDM wi

Frost Ming 10 Sep 23, 2021
Easy to use, fast, git sourced based, C/C++ package manager.

Yet Another C/C++ Package Manager Easy to use, fast, git sourced based, C/C++ package manager. Features No need to install a program, just include the

null 25 Oct 26, 2021
pip-run - dynamic dependency loader for Python

pip-run provides on-demand temporary package installation for a single interpreter run. It replaces this series of commands (or their Windows equivale

Jason R. Coombs 61 Oct 2, 2021