pve.md 1.49 KB
Newer Older
Vincent Mazenod's avatar
devops  
Vincent Mazenod committed
1
2
3
# Proxmox

## aka pve
Vincent Mazenod's avatar
Vincent Mazenod committed
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68


## Proxmox

* 10 ans


## interfacer avec le LDAP

# https://forum.proxmox.com/threads/how-to-transfer-large-iso-to-proxmox.455/

iptables -t nat -I PREROUTING -d 37.59.57.58 -p tcp --dport 443 -j DNAT --to-destination 37.59.57.58:8006

apt install iptables-persistent

service iptables save

# https://pve.proxmox.com/wiki/HTTPS_Certificate_Configuration_(Version_4.x,_5.0_and_5.1)

# https://pve.proxmox.com/wiki/Storage:_Directory

vi /etc/pve/storage.cfg

dir: local
        path /var/lib/vz
        vgname pve
        content iso,vztmpl,backup,rootdir,images

service pvestatd restart


# https://pve.proxmox.com/wiki/Cloud-Init_FAQ

Hardware > Add > loudInit Drive

SCSI / 0 / local


# https://pve.proxmox.com/wiki/Cloud-Init_Support

# create local-lvm (https://pve.proxmox.com/wiki/Storage)


# download the image
wget https://cloud-images.ubuntu.com/bionic/current/bionic-server-cloudimg-amd64.img

# create a new VM
qm create 9001 --memory 2048 --net0 virtio,bridge=vmbr0

# import the downloaded disk to local-lvm storage
qm importdisk 9001 bionic-server-cloudimg-amd64.img local

# finally attach the new disk to the VM as scsi drive
qm set 9001 --scsihw virtio-scsi-pci --scsi0 local:vm-9001-disk-0

qm set 9000 --ide2 local:cloudinit
qm set 9000 --boot c --bootdisk scsi0
qm set 9000 --serial0 socket --vga serial0
qm template 9000

Deploying Cloud-Init Templates

qm clone 9000 123 --name isp
qm set 123 --sshkey /root/limosadm.pub
qm set 123 --ipconfig0 ip=10.0.10.123/24,gw=10.0.10.1