mirrors: "192.168.50.119": endpoint: -"http://192.168.50.119" "docker.io": endpoint: -"https://7bezldxe.mirror.aliyuncs.com" -"https://registry-1.docker.io" configs: "192.168.50.119": auth: username:''# this is the registry username password:''# this is the registry password tls: cert_file:''# path to the cert file used in the registry key_file:''# path to the key file used in the registry ca_file:''# path to the ca file used in the registry "docker.io": auth: username:''# this is the registry username password:''# this is the registry password tls: cert_file:''# path to the cert file used in the registry key_file:''# path to the key file used in the registry ca_file:''# path to the ca file used in the registry
mirrors: "35.182.134.80": endpoint: -"http://35.182.134.80" configs: "35.182.134.80": auth: username:admin# this is the registry username password:Harbor12345# this is the registry password
安全(https)私有仓库配置
使用授信 ssl 证书
1 2 3 4 5 6 7 8 9
mirrors: "harbor.kingsd.top": endpoint: -"https://harbor.kingsd.top" configs: "harbor.kingsd.top": auth: username:admin# this is the registry username password:Harbor12345# this is the registry password
使用自签 ssl 证书
如果后端仓库使用的是自签名的 ssl 证书,那么需要配置 CA 证书 用于 ssl 证书的校验。
1 2 3 4 5 6 7 8 9 10 11
mirrors: "harbor-ksd.kingsd.top": endpoint: -"https://harbor-ksd.kingsd.top" configs: "harbor-ksd.kingsd.top": auth: username:admin# this is the registry username password:Harbor12345# this is the registry password tls: ca_file:/opt/certs/ca.crt
mirrors: "harbor-ksd.kingsd.top": endpoint: -"https://harbor-ksd.kingsd.top" configs: "harbor-ksd.kingsd.top": auth: username:admin# this is the registry username password:Harbor12345# this is the registry password tls: ca_file:/opt/certs/ca.crt# path to the ca file used in the registry cert_file:/opt/certs/harbor-ksd.kingsd.top.cert# path to the cert file used in the registry key_file:/opt/certs/harbor-ksd.kingsd.top.key# path to the key file used in the registry
mkdir /mnt/gentoo mount /dev/sdx? /mnt/gentoo mkdir /mnt/gentoo/home mount /dev/sdx? /mnt/gentoo/home mkdir /mnt/gentoo/boot mount /dev/sdx? /mnt/gentoo/boot mkdir /mnt/gentoo/boot/efi mount /dev/sdx? /mnt/gentoo/boot/efi
# These settings were set by the catalyst build script that automatically # built this stage. # Please consult /usr/share/portage/config/make.conf.example for a more # detailed example. # GCC编译配置 -O3代表优化级别,如果采用更高的-Ofast可能会导致部分软件包编译错误, # -march=native代表为本机cpu进行编译,如果是交叉编译需要去掉 COMMON_FLAGS="-march=skylake -O2 -pipe" CFLAGS="${COMMON_FLAGS}" CXXFLAGS="${COMMON_FLAGS}" FCFLAGS="${COMMON_FLAGS}" FFLAGS="${COMMON_FLAGS}"
Device Drivers ---> Generic Driver Options ---> [*] Maintain a devtmpfs filesystem to mount at /dev [*] Automount devtmpfs at /dev, after the kernel mounted the rootfs
SCSI磁盘支持。
1 2 3
Device Drivers ---> SCSI device support ---> <*> SCSI disk support
File systems ---> < > Second extended fs support < > The Extended 3 (ext3) filesystem <*> The Extended 4 (ext4) filesystem < > Reiserfs support < > JFS filesystem support < > XFS filesystem support < > Btrfs filesystem support DOS/FAT/NT Filesystems ---> <*> MSDOS fs support <*> VFAT (Windows-95) fs support Pseudo Filesystems ---> [*] /proc file system support [*] Tmpfs virtual memory file system support (former shm fs)
如果处理器是多核的,还需要开启SMP(对称多处理器支持)。
1 2
Processor type and features ---> [*] Symmetric multi-processing support
USB也必须启用
1 2 3 4 5 6 7 8 9 10 11
Device Drivers ---> HID support ---> -*- HID bus support <*> Generic HID driver [*] Battery level reporting for HID devices USB HID support ---> <*> USB HID transport layer [*] USB support ---> <*> xHCI HCD (USB 3.0) support <*> EHCI HCD (USB 2.0) support <*> OHCI HCD (USB 1.1) support
Processor type and features ---> [*] Machine Check / overheating reporting [*] Intel MCE Features [*] AMD MCE Features Processor family (AMD-Opteron/Athlon64) ---> ( ) Opteron/Athlon64/Hammer/K8 ( ) Intel P4 / older Netburst based Xeon ( ) Core 2/newer Xeon ( ) Intel Atom (*) Generic-x86-64 Binary Emulations ---> [*] IA32 Emulation
启用GPT支持,因为前面我用的GPT分区表,EFI启动方式,所以这两项也必须启用。
1 2 3 4
-*- Enable the block layer ---> Partition Types ---> [*] Advanced partition selection [*] EFI GUID Partition support
EFI的支持。
1 2 3 4 5 6 7 8
Processor type and features ---> [*] EFI runtime service support [*] EFI stub support [*] EFI mixed-mode support Firmware Drivers ---> EFI (Extensible Firmware Interface) Support ---> <*> EFI Variable Support via sysfs
1 2 3 4
# 编译内核 make -j12 #(CPU核心数根据机器cpu调整) make modules_install make install