xml/xsd revamp complete
This commit is contained in:
@@ -1,183 +0,0 @@
|
||||
{
|
||||
"boot": {
|
||||
"bootloader": "grub",
|
||||
"efi": true,
|
||||
"target": "/boot"
|
||||
},
|
||||
"disks": {
|
||||
"/dev/sda": {
|
||||
"fmt": "gpt",
|
||||
"parts": {
|
||||
"1": {
|
||||
"fstype": "8300",
|
||||
"start": "0%",
|
||||
"stop": "95%"
|
||||
},
|
||||
"2": {
|
||||
"fstype": "ef00",
|
||||
"start": "95%",
|
||||
"stop": "100%"
|
||||
}
|
||||
}
|
||||
},
|
||||
"/dev/sdb": {
|
||||
"fmt": "gpt",
|
||||
"parts": {
|
||||
"1": {
|
||||
"fstype": "8300",
|
||||
"start": "0%",
|
||||
"stop": "47%"
|
||||
},
|
||||
"2": {
|
||||
"fstype": "8300",
|
||||
"start": "47%",
|
||||
"stop": "95%"
|
||||
},
|
||||
"3": {
|
||||
"fstype": "8200",
|
||||
"start": "95%",
|
||||
"stop": "100%"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"mounts": {
|
||||
"1": {
|
||||
"device": "/dev/sda1",
|
||||
"fstype": "ext4",
|
||||
"opts": "defaults",
|
||||
"target": "/mnt/aif"
|
||||
},
|
||||
"2": {
|
||||
"device": "/dev/sda2",
|
||||
"fstype": "vfat",
|
||||
"opts": "rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro",
|
||||
"target": "/mnt/aif/boot"
|
||||
},
|
||||
"3": {
|
||||
"device": "/dev/sdb1",
|
||||
"fstype": "ext4",
|
||||
"opts": "defaults",
|
||||
"target": "/mnt/aif/home"
|
||||
},
|
||||
"4": {
|
||||
"device": "/dev/sdb2",
|
||||
"fstype": "ext4",
|
||||
"opts": "defaults",
|
||||
"target": "/mnt/aif/mnt/data"
|
||||
},
|
||||
"5": {
|
||||
"device": "/dev/sdb3",
|
||||
"fstype": false,
|
||||
"opts": false,
|
||||
"target": "swap"
|
||||
}
|
||||
},
|
||||
"network": {
|
||||
"hostname": "aif.loc.lan",
|
||||
"ifaces": {
|
||||
"ens3": {
|
||||
"address": "auto",
|
||||
"gw": false,
|
||||
"proto": "ipv4",
|
||||
"resolvers": false
|
||||
},
|
||||
"ens4": {
|
||||
"address": "192.168.1.2/24",
|
||||
"gw": "192.168.1.1",
|
||||
"proto": "ipv4",
|
||||
"resolvers": [
|
||||
"4.2.2.1",
|
||||
"4.2.2.2"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"scripts": {
|
||||
"pkg": false,
|
||||
"post": {
|
||||
"1": {
|
||||
"auth": "digest",
|
||||
"password": "password",
|
||||
"realm": "realmname",
|
||||
"uri": "https://aif.square-r00t.net/sample-scripts/post/first.sh",
|
||||
"user": "test"
|
||||
}
|
||||
},
|
||||
"pre": false
|
||||
},
|
||||
"software": {
|
||||
"mirrors": [
|
||||
"http://mirrors.advancedhosters.com/archlinux/$repo/os/$arch",
|
||||
"http://mirror.us.leaseweb.net/archlinux/$repo/os/$arch",
|
||||
"http://arch.mirror.constant.com/$repo/os/$arch",
|
||||
"http://mirror.vtti.vt.edu/archlinux/$repo/os/$arch",
|
||||
"http://arch.mirrors.pair.com/$repo/os/$arch",
|
||||
"http://mirror.yellowfiber.net/archlinux/$repo/os/$arch"
|
||||
],
|
||||
"packages": {
|
||||
"openssh": "None"
|
||||
},
|
||||
"pkgr": false,
|
||||
"repos": {
|
||||
"community": {
|
||||
"enabled": true,
|
||||
"mirror": "file:///etc/pacman.d/mirrorlist",
|
||||
"siglevel": "default"
|
||||
},
|
||||
"community-testing": {
|
||||
"enabled": false,
|
||||
"mirror": "file:///etc/pacman.d/mirrorlist",
|
||||
"siglevel": "default"
|
||||
},
|
||||
"core": {
|
||||
"enabled": true,
|
||||
"mirror": "file:///etc/pacman.d/mirrorlist",
|
||||
"siglevel": "default"
|
||||
},
|
||||
"extra": {
|
||||
"enabled": true,
|
||||
"mirror": "file:///etc/pacman.d/mirrorlist",
|
||||
"siglevel": "default"
|
||||
},
|
||||
"multilib": {
|
||||
"enabled": true,
|
||||
"mirror": "file:///etc/pacman.d/mirrorlist",
|
||||
"siglevel": "default"
|
||||
},
|
||||
"multilib-testing": {
|
||||
"enabled": false,
|
||||
"mirror": "file:///etc/pacman.d/mirrorlist",
|
||||
"siglevel": "default"
|
||||
}
|
||||
}
|
||||
},
|
||||
"system": {
|
||||
"chrootpath": "/mnt/aif",
|
||||
"kbd": "US",
|
||||
"locale": "en_US.UTF-8",
|
||||
"reboot": true,
|
||||
"rootpass": "$6$aIK0xvxLa/9BTEDu$xFskR0cQcEi273I8dgUtyO7WjjhHUZOfyS6NemelPgfMJORxbjgI6QCW6wEcCh7NVA1qGDpS0Lyg9vDCaRnA9/",
|
||||
"services": {
|
||||
"sshd": true
|
||||
},
|
||||
"timezone": "UTC",
|
||||
"users": {
|
||||
"aifusr": {
|
||||
"comment": "A Test User",
|
||||
"gid": false,
|
||||
"group": false,
|
||||
"home": false,
|
||||
"password": "$6$arRyKn/VsusyJNQo$huX4aa1aJPzRMyyqeEw6IxC1KC1EKKJ8RXdQp6W68Yt7SVdHjwU/fEDvPb3xD3lUHOQ6ysLKWLkEXFNYxLpMf1",
|
||||
"sudo": true,
|
||||
"uid": false,
|
||||
"xgroups": {
|
||||
"users": {
|
||||
"create": false,
|
||||
"gid": false
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,96 +0,0 @@
|
||||
{'boot': {'bootloader': 'grub', 'efi': True, 'target': '/boot'},
|
||||
'disks': {'/dev/sda': {'fmt': 'gpt',
|
||||
'parts': {1: {'fstype': '8300',
|
||||
'start': '0%',
|
||||
'stop': '95%'},
|
||||
2: {'fstype': 'ef00',
|
||||
'start': '95%',
|
||||
'stop': '100%'}}},
|
||||
'/dev/sdb': {'fmt': 'gpt',
|
||||
'parts': {1: {'fstype': '8300',
|
||||
'start': '0%',
|
||||
'stop': '47%'},
|
||||
2: {'fstype': '8300',
|
||||
'start': '47%',
|
||||
'stop': '95%'},
|
||||
3: {'fstype': '8200',
|
||||
'start': '95%',
|
||||
'stop': '100%'}}}},
|
||||
'mounts': {1: {'device': '/dev/sda1',
|
||||
'fstype': 'ext4',
|
||||
'opts': 'defaults',
|
||||
'target': '/mnt/aif'},
|
||||
2: {'device': '/dev/sda2',
|
||||
'fstype': 'vfat',
|
||||
'opts': 'rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro',
|
||||
'target': '/mnt/aif/boot'},
|
||||
3: {'device': '/dev/sdb1',
|
||||
'fstype': 'ext4',
|
||||
'opts': 'defaults',
|
||||
'target': '/mnt/aif/home'},
|
||||
4: {'device': '/dev/sdb2',
|
||||
'fstype': 'ext4',
|
||||
'opts': 'defaults',
|
||||
'target': '/mnt/aif/mnt/data'},
|
||||
5: {'device': '/dev/sdb3',
|
||||
'fstype': False,
|
||||
'opts': False,
|
||||
'target': 'swap'}},
|
||||
'network': {'hostname': 'aif.loc.lan',
|
||||
'ifaces': {'ens3': {'address': 'auto',
|
||||
'gw': False,
|
||||
'proto': 'ipv4',
|
||||
'resolvers': False},
|
||||
'ens4': {'address': '192.168.1.2/24',
|
||||
'gw': '192.168.1.1',
|
||||
'proto': 'ipv4',
|
||||
'resolvers': ['4.2.2.1', '4.2.2.2']}}},
|
||||
'scripts': {'pkg': False,
|
||||
'post': {1: {'auth': 'digest',
|
||||
'password': 'password',
|
||||
'realm': 'realmname',
|
||||
'uri': 'https://aif.square-r00t.net/sample-scripts/post/first.sh',
|
||||
'user': 'test'}},
|
||||
'pre': False},
|
||||
'software': {'mirrors': ['http://mirrors.advancedhosters.com/archlinux/$repo/os/$arch',
|
||||
'http://mirror.us.leaseweb.net/archlinux/$repo/os/$arch',
|
||||
'http://arch.mirror.constant.com/$repo/os/$arch',
|
||||
'http://mirror.vtti.vt.edu/archlinux/$repo/os/$arch',
|
||||
'http://arch.mirrors.pair.com/$repo/os/$arch',
|
||||
'http://mirror.yellowfiber.net/archlinux/$repo/os/$arch'],
|
||||
'packages': {'openssh': None},
|
||||
'pkgr': False,
|
||||
'repos': {'community': {'enabled': True,
|
||||
'mirror': 'file:///etc/pacman.d/mirrorlist',
|
||||
'siglevel': 'default'},
|
||||
'community-testing': {'enabled': False,
|
||||
'mirror': 'file:///etc/pacman.d/mirrorlist',
|
||||
'siglevel': 'default'},
|
||||
'core': {'enabled': True,
|
||||
'mirror': 'file:///etc/pacman.d/mirrorlist',
|
||||
'siglevel': 'default'},
|
||||
'extra': {'enabled': True,
|
||||
'mirror': 'file:///etc/pacman.d/mirrorlist',
|
||||
'siglevel': 'default'},
|
||||
'multilib': {'enabled': True,
|
||||
'mirror': 'file:///etc/pacman.d/mirrorlist',
|
||||
'siglevel': 'default'},
|
||||
'multilib-testing': {'enabled': False,
|
||||
'mirror': 'file:///etc/pacman.d/mirrorlist',
|
||||
'siglevel': 'default'}}},
|
||||
'system': {'chrootpath': '/mnt/aif',
|
||||
'kbd': 'US',
|
||||
'locale': 'en_US.UTF-8',
|
||||
'reboot': True,
|
||||
'rootpass': '$6$aIK0xvxLa/9BTEDu$xFskR0cQcEi273I8dgUtyO7WjjhHUZOfyS6NemelPgfMJORxbjgI6QCW6wEcCh7NVA1qGDpS0Lyg9vDCaRnA9/',
|
||||
'services': {'sshd': True},
|
||||
'timezone': 'UTC',
|
||||
'users': {'aifusr': {'comment': 'A Test User',
|
||||
'gid': False,
|
||||
'group': False,
|
||||
'home': False,
|
||||
'password': '$6$arRyKn/VsusyJNQo$huX4aa1aJPzRMyyqeEw6IxC1KC1EKKJ8RXdQp6W68Yt7SVdHjwU/fEDvPb3xD3lUHOQ6ysLKWLkEXFNYxLpMf1',
|
||||
'sudo': True,
|
||||
'uid': False,
|
||||
'xgroups': {'users': {'create': False,
|
||||
'gid': False}}}}}}
|
||||
@@ -1,62 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<aif xmlns:aif="http://aif.square-r00t.net/"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://aif.square-r00t.net aif.xsd">
|
||||
<storage>
|
||||
<disk device="/dev/sda" diskfmt="gpt">
|
||||
<part num="1" start="0%" stop="10%" fstype="ef00" />
|
||||
<part num="2" start="10%" stop="100%" fstype="8300" />
|
||||
</disk>
|
||||
<mount source="/dev/sda2" target="/mnt/aif" order="1" />
|
||||
<mount source="/dev/sda1" target="/mnt/aif/boot" order="2" />
|
||||
</storage>
|
||||
<network hostname="aiftest.square-r00t.net">
|
||||
<iface device="auto" address="auto" netproto="ipv4" />
|
||||
</network>
|
||||
<system timezone="EST5EDT" locale="en_US.UTF-8" chrootpath="/mnt/aif" reboot="1">
|
||||
<users rootpass="!" />
|
||||
<service name="sshd" status="1" />
|
||||
<service name="cronie" status="1" />
|
||||
<service name="haveged" status="1" />
|
||||
</system>
|
||||
<pacman command="apacman -S">
|
||||
<repos>
|
||||
<repo name="core" enabled="true" siglevel="default" mirror="file:///etc/pacman.d/mirrorlist" />
|
||||
<repo name="extra" enabled="true" siglevel="default" mirror="file:///etc/pacman.d/mirrorlist" />
|
||||
<repo name="community" enabled="true" siglevel="default" mirror="file:///etc/pacman.d/mirrorlist" />
|
||||
<repo name="multilib" enabled="true" siglevel="default" mirror="file:///etc/pacman.d/mirrorlist" />
|
||||
<repo name="testing" enabled="false" siglevel="default" mirror="file:///etc/pacman.d/mirrorlist" />
|
||||
<repo name="multilib-testing" enabled="false" siglevel="default" mirror="file:///etc/pacman.d/mirrorlist" />
|
||||
<repo name="archlinuxfr" enabled="false" siglevel="Optional TrustedOnly" mirror="http://repo.archlinux.fr/$arch" />
|
||||
</repos>
|
||||
<mirrorlist>
|
||||
<mirror>http://mirror.us.leaseweb.net/archlinux/$repo/os/$arch</mirror>
|
||||
<mirror>http://mirrors.advancedhosters.com/archlinux/$repo/os/$arch</mirror>
|
||||
<mirror>http://ftp.osuosl.org/pub/archlinux/$repo/os/$arch</mirror>
|
||||
<mirror>http://arch.mirrors.ionfish.org/$repo/os/$arch</mirror>
|
||||
<mirror>http://mirrors.gigenet.com/archlinux/$repo/os/$arch</mirror>
|
||||
<mirror>http://mirror.jmu.edu/pub/archlinux/$repo/os/$arch</mirror>
|
||||
</mirrorlist>
|
||||
<software>
|
||||
<package name="sed" repo="core" />
|
||||
<package name="python" />
|
||||
<package name="openssh" />
|
||||
<package name="vim" />
|
||||
<package name="vim-plugins" />
|
||||
<package name="haveged" />
|
||||
<package name="byobu" />
|
||||
<package name="etc-update" />
|
||||
<package name="cronie" />
|
||||
<package name="mlocate" />
|
||||
<package name="mtree-git" />
|
||||
</software>
|
||||
</pacman>
|
||||
<bootloader type="grub" target="/boot" efi="true" />
|
||||
<scripts>
|
||||
<script uri="https://aif.square-r00t.net/cfgs/scripts/pkg/python.sh" order="1" execution="pkg" />
|
||||
<script uri="https://aif.square-r00t.net/cfgs/scripts/pkg/apacman.py" order="2" execution="pkg" />
|
||||
<script uri="https://aif.square-r00t.net/cfgs/scripts/post/sshsecure.py" order="1" execution="post" />
|
||||
<script uri="https://aif.square-r00t.net/cfgs/scripts/post/sshkeys.py" order="2" execution="post" />
|
||||
<script uri="https://aif.square-r00t.net/cfgs/scripts/post/configs.py" order="3" execution="post" />
|
||||
</scripts>
|
||||
</aif>
|
||||
@@ -1,21 +1,26 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<aif xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns="http://aif-ng.io/"
|
||||
xsi:schemaLocation="http://aif-ng.io/aif.xsd">
|
||||
xsi:schemaLocation="http://aif-ng.io/aif.xsd"
|
||||
version="0.2.0">
|
||||
<storage>
|
||||
<disk device="/dev/sda" diskFormat="gpt">
|
||||
<!-- Partitions are numbered *in the order they are specified*. -->
|
||||
<part id="boot" name="BOOT" label="/boot" start="0%" stop="10%"
|
||||
fsType="fat32"/><!-- e.g. this would be /dev/sda1 -->
|
||||
<part id="secrets1" name="crypted" label="shh" start="10%" stop="20%" fsType="ext4"/>
|
||||
<part id="lvm_member1" name="jbod" label="dynamic" start="20%" stop="30%" fsType="ext4"/>
|
||||
<part id="raid1_d1" start="30%" stop="55%" fsType="ext4"/>
|
||||
<part id="raid1_d2" start="55%" stop="80%" fsType="ext4"/>
|
||||
<part id="swap" start="80%" stop="100%" fsType="linux-swap(v1)"/>
|
||||
</disk>
|
||||
<blockDevices>
|
||||
<disk device="/dev/sda" diskFormat="gpt">
|
||||
<!-- Partitions are numbered *in the order they are specified*. -->
|
||||
<part id="boot" name="BOOT" label="/boot" start="0%" stop="10%"
|
||||
fsType="fat32"/><!-- e.g. this would be /dev/sda1 -->
|
||||
<part id="secrets1" name="crypted" label="shh" start="10%" stop="20%" fsType="ext4"/>
|
||||
<part id="lvm_member1" name="jbod" label="dynamic" start="20%" stop="30%" fsType="ext4"/>
|
||||
<part id="raid1_d1" start="30%" stop="55%" fsType="ext4"/>
|
||||
<part id="raid1_d2" start="55%" stop="80%" fsType="ext4"/>
|
||||
<part id="swap" start="80%" stop="100%" fsType="linux-swap(v1)"/>
|
||||
</disk>
|
||||
</blockDevices>
|
||||
<!-- "Special" devices are processed *in the order they are specified*. This is important if you wish to
|
||||
e.g. layer LUKS on top of LVM - you would specify <lvm> before <luks> and reference the
|
||||
<luksDev id="SOMETHING" ... > as <lvmLogical source="SOMETHING" ... />. -->
|
||||
<luksDev id="SOMETHING" ... > as <lvmLogical source="SOMETHING" ... />.
|
||||
Of course, a limitation of this is you cannot e.g. first assemble a LUKS volume, then an LVM
|
||||
group, and then another LUKS volume - so plan accordingly and/or perform this in a <post> script. -->
|
||||
<luks>
|
||||
<luksDev id="luks_secrets" name="secrets" source="secrets1">
|
||||
<!-- You can assign multiple secrets (or "keys") to a LUKS volume. -->
|
||||
@@ -93,22 +98,31 @@
|
||||
</iface>
|
||||
</network>
|
||||
<system timezone="EST5EDT" chrootPath="/mnt/aif" reboot="0">
|
||||
<rootPassword>
|
||||
<passwordPlain>1ns3cur3p4ssw0rd</passwordPlain>
|
||||
</rootPassword>
|
||||
<locales>
|
||||
<locale name="LANG">en_US.UTF-8</locale>
|
||||
</locales>
|
||||
<!-- note: all password hashes below are "test"; don't waste your time trying to crack. :) -->
|
||||
<users rootPass="$6$3YPpiS.l3SQC6ELe$NQ4qMvcDpv5j1cCM6AGNc5Hyg.rsvtzCt2VWlSbuZXCGg2GB21CMUN8TMGS35tdUezZ/n9y3UFGlmLRVWXvZR.">
|
||||
<!-- Note: The password hashe below is "test"; don't waste your time trying to crack. :) -->
|
||||
<users>
|
||||
<user name="aifusr"
|
||||
home="/opt/aifusr"
|
||||
sudo="true"
|
||||
password="$6$WtxZKOyaahvvWQRG$TUys60kQhF0ffBdnDSJVTA.PovwCOajjMz8HEHL2H0ZMi0bFpDTQvKA7BqzM3nA.ZMAUxNjpJP1dG/eA78Zgw0"
|
||||
comment="A test user for AIF.">
|
||||
<password>
|
||||
<passwordHash hashType="(detect)">
|
||||
$6$WtxZKOyaahvvWQRG$TUys60kQhF0ffBdnDSJVTA.PovwCOajjMz8HEHL2H0ZMi0bFpDTQvKA7BqzM3nA.ZMAUxNjpJP1dG/eA78Zgw0
|
||||
</passwordHash>
|
||||
</password>
|
||||
<xGroup name="admins" create="true"/>
|
||||
<xGroup name="wheel"/>
|
||||
<xGroup name="users"/>
|
||||
</user>
|
||||
</users>
|
||||
<service name="sshd" status="0"/>
|
||||
<services>
|
||||
<service status="1">sshd</service>
|
||||
</services>
|
||||
</system>
|
||||
<pacman>
|
||||
<repos>
|
||||
@@ -130,17 +144,21 @@
|
||||
<mirror>http://mirror.jmu.edu/pub/archlinux/$repo/os/$arch</mirror>
|
||||
</mirrorList>
|
||||
<software>
|
||||
<package name="sed" repo="core"/>
|
||||
<package name="python"/>
|
||||
<package name="perl"/>
|
||||
<package name="openssh"/>
|
||||
<package repo="core">sed</package>
|
||||
<package>python</package>
|
||||
<package>perl</package>
|
||||
<package>openssh</package>
|
||||
</software>
|
||||
</pacman>
|
||||
<bootloader type="grub" target="/boot" efi="true"/>
|
||||
<scripts>
|
||||
<script uri="https://aif.square-r00t.net/sample-scripts/post/first.sh" order="1" execution="post"/>
|
||||
<script uri="https://aif.square-r00t.net/sample-scripts/pre/second.pl" order="2" execution="pre"/>
|
||||
<script uri="https://aif.square-r00t.net/sample-scripts/pre/first.sh" order="1" execution="pre"/>
|
||||
<script uri="https://aif.square-r00t.net/sample-scripts/post/second.py" order="2" execution="post"/>
|
||||
<pre>
|
||||
<script>https://aif.square-r00t.net/sample-scripts/pre/first.sh</script>
|
||||
<script>https://aif.square-r00t.net/sample-scripts/pre/second.pl</script>
|
||||
</pre>
|
||||
<post>
|
||||
<script>https://aif.square-r00t.net/sample-scripts/post/first.sh</script>
|
||||
<script>https://aif.square-r00t.net/sample-scripts/post/second.py</script>
|
||||
</post>
|
||||
</scripts>
|
||||
</aif>
|
||||
|
||||
Reference in New Issue
Block a user