Installation instructions

Start using packagecloud in minutes

Join thousands of developers using packagecloud to distribute software securely, consistently, and affordably.

Bash Scripts

deb

deb

curl -s https://packagecloud.io/install/repositories/nuclearsandwich/colcon-test/script.deb.sh | sudo bash
      
...
rpm

rpm

curl -s https://packagecloud.io/install/repositories/nuclearsandwich/colcon-test/script.rpm.sh | sudo bash
      
...
node.JS

node

curl -s https://packagecloud.io/install/repositories/nuclearsandwich/colcon-test/script.node.sh | bash
      
...
pip

python

Are you using virtualenv?

curl -s https://packagecloud.io/install/repositories/nuclearsandwich/colcon-test/script.python.sh | bash
      
...
gem

gem

Are you using Bundler?

curl -s https://packagecloud.io/install/repositories/nuclearsandwich/colcon-test/script.gem.sh | bash
      
...

Manual Installation

If you'd prefer to install your repo on your system manually, follow the instructions below. If you feel something is missing or just want more info, don't hesitate to get in touch.

deb

deb

Begin by refreshing your package cache by running

sudo apt-get update

If you are running Debian, install debian-archive-keyring so that official Debian repositories will be verified (Ubuntu users can skip this)

sudo apt-get install debian-archive-keyring

Ensure the required tools (curl, gpg, apt-transport-https) are installed before proceeding:

sudo apt-get install curl gnupg apt-transport-https

In order to install a deb repo, first you need to install the GPG key that used to sign repository metadata. This will change depending on whether or not your apt version is >= v.1.1. You can check this by running:

apt -v

For apt version >= v1.1:

(Equivalent to or later than Debian/Raspbian Stretch, Ubuntu Xenial, Linux Mint Sarah, Elementary OS Loki)

  1. Create the directory to import the GPG key:

  2. From apt v2.4.0, /etc/apt/keyrings/ is the designated directory for administrator imported keys. We will be using that for the following instructions, but you can replace /etc/apt/keyrings/ with any path of your choosing. If you need to create the directory, run:

    mkdir -p /etc/apt/keyrings/
  3. Then add the GPG key:

    curl -fsSL https://packagecloud.io/nuclearsandwich/colcon-test/gpgkey | gpg --dearmor > /etc/apt/keyrings/nuclearsandwich_colcon-test-archive-keyring.gpg
  4. Create a file named /etc/apt/sources.list.d/nuclearsandwich_colcon-test.list that contains the repository configuration below.

    Make sure to replace ubuntu and trusty in the config below with your Linux distribution and version:

        deb [signed-by=/etc/apt/keyrings/nuclearsandwich_colcon-test-archive-keyring.gpg] https://packagecloud.io/nuclearsandwich/colcon-test/ubuntu trusty main
        deb-src [signed-by=/etc/apt/keyrings/nuclearsandwich_colcon-test-archive-keyring.gpg] https://packagecloud.io/nuclearsandwich/colcon-test/ubuntu trusty main

For apt version < v1.1:

(Equivalent to or older than Debian/Raspbian Jessie, Ubuntu Wily, Linux Mint Rosa, Elementary OS Freya)

  1. Add the GPG key:

    curl -fsSL https://packagecloud.io/nuclearsandwich/colcon-test/gpgkey | gpg --dearmor > /etc/apt/trusted.gpg.d/nuclearsandwich_colcon-test.gpg
  2. Create a file named /etc/apt/sources.list.d/nuclearsandwich_colcon-test.list that contains the repository configuration below.

    Make sure to replace ubuntu and trusty in the config below with your Linux distribution and version:

        deb https://packagecloud.io/nuclearsandwich/colcon-test/ubuntu trusty main
        deb-src https://packagecloud.io/nuclearsandwich/colcon-test/ubuntu trusty main

Valid options for os and dist parameters can be found in our support OS list in the docs.

Run this command update your local APT cache:

sudo apt-get update

You can now install packages from your repository.

rpm

rpm

Install pygpgme, a package which allows yum to handle gpg signatures, and a package called yum-utils which contains the tools you need for installing source RPMs.

sudo yum install pygpgme yum-utils

Note: 'pygpgme' package installation is only required for RHEL versions earlier than 8 (< 8).

You may need to install the EPEL repository for your system to install these packages. If you do not install pygpgme, GPG verification will not work.

Create a file named /etc/yum.repos.d/nuclearsandwich_colcon-test.repo that contains the repository configuration below.

Make sure to replace el and 6 in the config below with your Linux distribution and version:

[nuclearsandwich_colcon-test]
name=nuclearsandwich_colcon-test
baseurl=https://packagecloud.io/nuclearsandwich/colcon-test/el/6/$basearch
repo_gpgcheck=1
gpgcheck=0
enabled=1
gpgkey=https://packagecloud.io/nuclearsandwich/colcon-test/gpgkey
sslverify=1
sslcacert=/etc/pki/tls/certs/ca-bundle.crt
metadata_expire=300

[nuclearsandwich_colcon-test-source]
name=nuclearsandwich_colcon-test-source
baseurl=https://packagecloud.io/nuclearsandwich/colcon-test/el/6/SRPMS
repo_gpgcheck=1
gpgcheck=0
enabled=1
gpgkey=https://packagecloud.io/nuclearsandwich/colcon-test/gpgkey
sslverify=1
sslcacert=/etc/pki/tls/certs/ca-bundle.crt
metadata_expire=300

Valid options for os and dist parameters can be found in our supported OS list in the docs.

Update your local yum cache by running

sudo yum -q makecache -y --disablerepo='*' --enablerepo='nuclearsandwich_colcon-test'

You can now install packages from your repository.

node

Node.js

Add the repository as an npm registry

To install node packages from this repository, you'll need to configure it as a registry.

npm config set registry https://packagecloud.io/nuclearsandwich/colcon-test/npm/

Using Yarn?

After a repository is configured as an npm registry it can be used by yarn to resolve packages. Once configured, add packages to a project using yarn add.

Verify a repository is configured correctly by running yarn config list and making sure the registry url is set correctly.

example yarn config list output:
...
info npm config
{ registry: 'https://packagecloud.io/nuclearsandwich/colcon-test/npm/' }

Transparent auto-proxying

When you install a package using npm install, the npm program will automatically attempt to install any dependencies required by the package. If those dependencies are not found in your packagecloud repository, packagecloud will automatically forward requests for those missing dependencies to the official npm public registry.

This is the default behavior and is recommended for most users.

To learn more about this behavior and how to disable it, take a look at our documentation.

zypper

zypper

Create a file named /etc/zypp/repos.d/nuclearsandwich_colcon-test.repo that contains the repository configuration below.

Make sure to replace el and 6 in the config below with your Linux distribution and version:

[nuclearsandwich_colcon-test]
name=nuclearsandwich_colcon-test
baseurl=https://packagecloud.io/nuclearsandwich/colcon-test/opensuse/13.2/$basearch
enabled=1
repo_gpgcheck=1
pkg_gpgcheck=0
gpgkey=https://packagecloud.io/nuclearsandwich/colcon-test/gpgkey
autorefresh=1
type=rpm-md

[nuclearsandwich_colcon-test-source]
name=nuclearsandwich_colcon-test-source
baseurl=https://packagecloud.io/nuclearsandwich/colcon-test/opensuse/13.2/SRPMS
enabled=1
repo_gpgcheck=1
pkg_gpgcheck=0
gpgkey=https://packagecloud.io/nuclearsandwich/colcon-test/gpgkey
autorefresh=1
type=rpm-md

Valid options for os and dist parameters can be found in our supported OS list in the docs.

Update your local zypper cache by running

zypper --gpg-auto-import-keys refresh nuclearsandwich_colcon-test
zypper --gpg-auto-import-keys refresh nuclearsandwich_colcon-test-source

You can now install packages from your repository.

rubygems

rubygems

Add the repository as a source

To install gems from this repository, you'll need to add the repository as a source.

gem source --add https://packagecloud.io/nuclearsandwich/colcon-test/

Using Bundler?

Add the repository to your Gemfile

To install gems from this repository, you'll need to add it as a source to your Gemfile.

Bundler 1.7.0 and above

In newer bundler versions, you can scope specific gems to a source, like so:

# Gemfile

# Note: It's recommended you add the official https://rubygems.org source, unless your
#       packagecloud repository can meet all of the dependency requirements in the Gemfile.

source "https://rubygems.org"
source "https://packagecloud.io/nuclearsandwich/colcon-test" do
  gem "my-gem"
  gem "another-gem"
end

Legacy versions of Bundler

Older versions of Bundler have several bugs around scoping gems to a single source using blocks, so you'll have to add the source globally at the top of the Gemfile.

# Gemfile

source "https://rubygems.org"
source "https://packagecloud.io/nuclearsandwich/colcon-test"
python

python

To install python packages from this repository, you'll need to add the repository as a source to pip.

Add the repository to pip

Add the repository to the [global] section in your ~/.pip/pip.conf

[global]
extra-index-url=https://packagecloud.io/nuclearsandwich/colcon-test/pypi/simple

Note: if you would like pip to use only this repository as a source, replace extra-index-url with index-url

VirtualEnv / requirements.txt

Add the repository to your VirtualEnv

Ensure you are running the latest version of pip inside your virtualenv:

my_virtualenv/bin/pip install --upgrade pip

Add this to the bottom of your requirements.txt

--extra-index-url=https://packagecloud.io/nuclearsandwich/colcon-test/pypi/simple

Note: if you would like pip to use only this repository as a source, replace extra-index-url with index-url

If you're looking for further clarification on anything, don't hesitate to get in touch!

Chef Cookbook

If you use chef to manage your infrastructure, you're in luck! We maintain a cookbook that makes it really easy to get up and running.

Using Berkshelf to manage your cookbooks? Depend on our cookbook like this:

cookbook "packagecloud"

If you're managing your cookbooks some other way, you can get our cookbook from supermarket.chef.io or github.

Once you have our cookbook installed, all you have to do to install this repo is add the following block to one of your recipes:

packagecloud_repo "nuclearsandwich/colcon-test" do
  type "deb" # or "rpm" or "gem"
end

The LWRP in our cookbook will determine what OS/Version you're on and setup the repository correctly for that particular node. It will also contact our installation API to issue a read token, and make sure our gpg key gets installed if necessary.

Puppet Module

If you use puppet to manage your infrastructure, you're in luck! We maintain a module that makes it really easy to get up and running.

You can get our module on Puppet Forge or on GitHub.

To get this repo installed, you just need to add the following to one of your manifests:

include packagecloud

packagecloud::repo { "nuclearsandwich/colcon-test":
  type => 'rpm',  # or "deb" or "gem"
}

The module will determine what OS/Version you're on and setup the repository correctly for that particular node. It will also contact our installation API to issue a read token, and make sure our gpg key gets installed if necessary.

Using Bundler and packagecloud

Add the repository to your Gemfile

To install gems from this repository, you'll need to add it as a source to your Gemfile.

Bundler 1.7.0 and above

In newer bundler versions, you can scope specific gems to a source, like so:

# Gemfile

# Note: It's recommended you add the official https://rubygems.org source, unless your
#       packagecloud repository can meet all of the dependency requirements in the Gemfile.

source "https://rubygems.org"
source "https://packagecloud.io/nuclearsandwich/colcon-test" do
  gem "my-gem"
  gem "another-gem"
end

Legacy versions of Bundler

Older versions of Bundler have several bugs around scoping gems to a single source using blocks, so you'll have to add the source globally at the top of the Gemfile.

# Gemfile

source "https://rubygems.org"
source "https://packagecloud.io/nuclearsandwich/colcon-test"

Using VirtualEnv and packagecloud

Add the repository to your VirtualEnv

Ensure you are running the latest version of pip inside your virtualenv:

my_virtualenv/bin/pip install --upgrade pip

Add this to the bottom of your requirements.txt

--extra-index-url=https://packagecloud.io/nuclearsandwich/colcon-test/pypi/simple

Note: if you would like pip to use only this repository as a source, replace extra-index-url with index-url

Using Maven with Packagecloud

Add the repository to Maven

Add this to the top level of your pom.xml

<repositories>
  <repository>
    <id>nuclearsandwich-colcon-test</id>
    <url>https://packagecloud.io/nuclearsandwich/colcon-test/maven2</url>
    <releases>
      <enabled>true</enabled>
    </releases>
    <snapshots>
      <enabled>true</enabled>
    </snapshots>
  </repository>
</repositories>

Using Leiningen with Packagecloud

Add the repository to Leiningen

Add this entry to the top-level of your project.clj file

:repositories [["snapshots" "https://packagecloud.io/nuclearsandwich/colcon-test/maven2"]
               ["releases" "https://packagecloud.io/nuclearsandwich/colcon-test/maven2"]]

Using SBT with Packagecloud

Add the repository to SBT

For SNAPSHOT support (needs SBT 0.13.8 or above), create or append the following to a project/maven.sbt file in your project:

addMavenResolverPlugin

Then, add this entry anywhere in your build.sbt file:

resolvers += "nuclearsandwich-colcon-test" at "https://packagecloud.io/nuclearsandwich/colcon-test/maven2"

Using Gradle with Packagecloud

Add the repository to Gradle

Add this entry anywhere in your build.gradle file

repositories {
    maven {
        url "https://packagecloud.io/nuclearsandwich/colcon-test/maven2"
    }
}