forked from vmware/photon-packer-templates
-
Notifications
You must be signed in to change notification settings - Fork 0
/
photon.pkrtpl.hcl
43 lines (43 loc) · 986 Bytes
/
photon.pkrtpl.hcl
1
2
3
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
{
"arch": "x86_64",
"hostname":"photon-${os_packagelist}",
"password":{
"crypted":false,
"text":"${ssh_password}"
},
"disk":"/dev/sda",
"partitions":[
{
"mountpoint":"/",
"size":0,
"filesystem":"ext4"
},
{
"mountpoint":"/boot",
"size":128,
"filesystem":"ext4"
},
{
"mountpoint":"/root",
"size":128,
"filesystem":"ext4"
},
{
"size":128,
"filesystem":"swap"
}
],
"bootmode":"bios",
"network":{
"type":"dhcp"
},
"linux_flavor":"linux",
"packagelist_file":"packages_${os_packagelist}.json",
"postinstall":[
"#!/bin/sh",
"chage -I -1 -m 0 -M 99999 -E -1 ${ssh_username}",
"sed -i 's/PermitRootLogin no/PermitRootLogin yes/g' /etc/ssh/sshd_config",
"sed -i 's/.*MaxAuthTries.*/MaxAuthTries 10/g' /etc/ssh/sshd_config",
"systemctl restart sshd.service"
]
}