0%

install_isulad

ubuntu19.10使用iSulad

安装依赖包

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// build tools
sudo apt install -y libtool automake autoconf cmake

// iSulad requires
sudo apt install -y libyajl-dev zlib1g-dev
sudo apt install -y libseccomp-dev libcap-dev libwebsockets-dev
sudo apt install -y libsystemd-dev libhttp-parser-dev libcurl4-gnutls-dev openssl
sudo apt install -y libprotoc-dev libprotobuf-dev protobuf-compiler protobuf-compiler-grpc
sudo apt install -y libgrpc++-dev libgrpc-dev libgrpc++-dev

// iSulad-img requires
sudo apt install -y libdevmapper-dev

// clibcni requires
sudo apt install -y libgtest-dev

安装lxc

1
2
3
4
5
6
7
8
git clone https://gitee.com/src-openeuler/lxc.git
cd lxc
tar -zxf lxc-3.0.3.tar.gz
./apply-patches
./autogen.sh
./configure
make -j
sudo make install

安装clibcni

1
2
3
4
5
6
7
git clone https://gitee.com/openeuler/clibcni.git
cd clibcni
mkdir build
cd build
cmake ..
make -j
sudo make install

安装iSulad-img

1
2
3
4
5
6
7
8
9
10
// 安装golang
// 下载最新的golang包:https://golang.google.cn/doc/install?download=go1.14.2.linux-amd64.tar.gz
tar -C /usr/local -xzf go1.14.2.linux-amd64.tar.gz
export PATH=$PATH:/usr/local/go/bin

git clone https://gitee.com/openeuler/iSulad-img.git
// 编译
cd iSulad-img
make
sudo make install

安装lcr

1
2
3
4
5
6
7
git clone https://gitee.com/openeuler/lcr.git
cd lcr
mkdir build
cd build
cmake ..
make -j
sudo make install

安装iSulad

1
2
3
4
5
6
7
git clone https://gitee.com/openeuler/iSulad.git
cd iSulad
mkdir build
cd build
cmake ..
make -j
sudo make install

使用iSulad

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// 使用root权限
su

// 添加镜像仓库地址 /etc/isulad/daemon.json
"registry-mirrors": [
"https://hub-mirror.c.163.com"
],

// 启动服务进程
isulad &

// 下载busybox镜像
isula pull busybox
// 启动容器
isula run -tid busybox
// 获取容器列表
isula ps -a