Merge pull request #68 from lowescott/containerd-runc

Made final adjustments to containerd-runc environment
This commit is contained in:
Scott S. Lowe 2016-12-10 21:35:11 -07:00 committed by GitHub
commit 867be7a138
3 changed files with 23 additions and 53 deletions

View file

@ -64,9 +64,11 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
vb.cpus = machine['vcpu']
override.vm.box = machine['box']['vb']
end # srv.vm.provider 'virtualbox'
# Provision the VMs
srv.vm.provision 'shell', path: 'provision.sh', privileged: true
end # config.vm.define
end # machines.each
# Provision the VM(s) with Ansible
config.vm.provision 'ansible' do |ansible|
ansible.playbook = 'provision.yml'
end # config.vm.provision
end # Vagrant.configure

View file

@ -1,50 +0,0 @@
#!/bin/bash
# Install curl if needed
if [[ ! -e /usr/bin/curl ]]; then
sudo apt-get -yqq install curl
fi
# Download containerd, if it isn't already present on the system
if [[ ! -e /usr/local/bin/containerd ]]; then
# Download containerd from GitHub
curl -kLO https://github.com/docker/containerd/releases/download/0.0.5/containerd
# Move the downloaded binary to /usr/local/bin
sudo mv containerd /usr/local/bin/containerd
sudo chmod a+x /usr/local/bin/containerd
fi
# Download containerd-shim, if it isn't already present on the system
if [[ ! -e /usr/local/bin/containerd-shim ]]; then
# Download containerd-shim from GitHub
curl -kLO https://github.com/docker/containerd/releases/download/0.0.5/containerd-shim
# Move the downloaded binary to /usr/local/bin
sudo mv containerd-shim /usr/local/bin/containerd-shim
sudo chmod a+x /usr/local/bin/containerd-shim
fi
# Download ctr, if it isn't already present on the system
if [[ ! -e /usr/local/bin/ctr ]]; then
# Download ctr from GitHub
curl -kLO https://github.com/docker/containerd/releases/download/0.0.5/ctr
# Move the downloaded binary to /usr/local/bin
sudo mv ctr /usr/local/bin/ctr
sudo chmod a+x /usr/local/bin/ctr
fi
# Download runc, if it isn't already present on the system
if [[ ! -e /usr/local/bin/runc ]]; then
# Download runc from GitHub
curl -kLO https://github.com/docker/containerd/releases/download/0.0.5/runc
# Move the downloaded binary to /usr/local/bin
sudo mv runc /usr/local/bin/runc
sudo chmod a+x /usr/local/bin/runc
fi

View file

@ -0,0 +1,18 @@
---
- hosts: "all"
become: "yes"
remote_user: "vagrant"
tasks:
- name: "Download containerd/runc binaries"
get_url:
url: "{{ item }}"
dest: "/usr/local/bin/"
mode: "0755"
with_items:
- "https://github.com/docker/containerd/releases/download/0.0.5/containerd-shim"
- "https://github.com/docker/containerd/releases/download/0.0.5/ctr"
- "https://github.com/docker/containerd/releases/download/0.0.5/containerd"
- "https://github.com/docker/containerd/releases/download/0.0.5/runc"
tags:
- packages