Contents
  1. 1. 编译环境1
  2. 2. 编译环境2
  3. 3. 编译操作
  4. 4. Vagrant with VirtualBox (vmware/hyper-v also supported)

编译环境1

只有一张网卡工作时 修改配置后应用变更

  • ifconfig -a
  • sudo netplan apply
  • root@kali:# ifconfig enp0s17 up //启用网卡
    root@kali:
    # ifconfig -a //查看IP
    root@kali:~# dhclient enp0s17 // 分配IP
1
2
3
4
5
6
7
8
9
cat /etc/netplan/00-installer-config.yaml
# This is the network config written by 'subiquity'
network:
ethernets:
enp0s3:
dhcp4: true
enp0s8:
dhcp4: true
version: 2
1
2
3
4
5
6
<mirror>
<id>aliyunmaven</id>
<mirrorOf>*</mirrorOf>
<name>阿里云公共仓库</name>
<url>https://maven.aliyun.com/repository/public</url>
</mirror>

编译环境2

  • 安装multipass
  • 挂载目录
    • multipass set local.privileged-mounts=true
    • multipass exec primary mkdir /mnt/e
    • multipass mount E:\ primary:/mnt/e
  • 修改系统更新源
  • 安装mvn
    • sudo apt-get install maven
  • 修改仓库源
    • vi /usr/share/maven/conf/settings.xml
  • 问题
    • 空间不足,需要挂载
    • 挂载后无法管理权限,脚本无法直接执行
1
2
3
4
5
<mirror>
<id>huaweicloud</id>
<mirrorOf>*</mirrorOf>
<url>https://repo.huaweicloud.com/repository/maven/</url>
</mirror>

编译操作

Vagrant with VirtualBox (vmware/hyper-v also supported)

https://zhuanlan.zhihu.com/p/259833884