# Docker container 常用軟體安裝

更新 apt-get

```shell
#更新apt-update
apt-get update
```

#### vim

```shell
sudo apt-get install -y vim
```

#### ip

```shell
sudo apt-get install -y iproute2
```

#### ping

```shell
sudo apt-get install -y iputils-ping
```

#### ifconfig, netestat

```shell
sudo apt-get install -y net-tools
```

##### nc (netcat)

```shell
sudo apt-get install -y netcat
```

#### maven

```shell
FROM jenkins/jenkins:lts
RUN apt-get update && apt-get install -y maven
```

---

### apt-get 使用proxy

```shell

#apt_proxy.conf 設定 proxy
Acquire::http::proxy "http://127.0.0.1:8000/";
Acquire::ftp::proxy "ftp://127.0.0.1:8000/";
Acquire::https::proxy "https://127.0.0.1:8000/";

#可以用“-c”選項來指定使用配置檔案
sudo apt-get -c ~/apt_proxy.conf update
#apt-get也有一個“-o”選項，直接跟apt-get的設定變數，就不用指定配置檔案了，比如
sudo apt-get -o Acquire::http::proxy="http://127.0.0.1:8000/" update

```