What are the benefits of cfn-init over userdata? : <p>My CloudFormation template has gotten pretty long. One reason is because my <code>AWS::CloudFormation::Init</code> section has gotten pretty huge. This is a very small sample of what I have:</p>

<pre><code>"ConfigDisk": {
    "commands": {
        "01formatFS": {
            "command": "/sbin/mkfs.ext4 /dev/xvdf"
        },
        "02mountFS": {
            "command": "/bin/mount /dev/xvdf /var/lib/jenkins"
        },
        "03changePerms": {
            "command": "/bin/chown jenkins:jenkins /var/lib/jenkins"
        },
        "04updateFStab": {
            "command": "/bin/echo /dev/xvdf /var/lib/jenkins ext4 defaults 1 1 &gt;&gt; /etc/fstab"
        }
    }
},
</code></pre>

<p>Wouldn't it be better to just put this into the userdata section as a bunch of commands?</p>

<pre><code>/sbin/mkfs.ext4 /dev/xvdf
/bin/mount /dev/xvdf /var/lib/jenkins
/bin/chown jenkins:jenkins /var/lib/jenkins
/bin/echo /dev/xvdf /var/lib/jenkins ext4 defaults 1 1 &gt;&gt; /etc/fstab
</code></pre>

<p>What are the benefits of leaving this in the Init over userdata?</p>
