This doesn;t mention the filename that the next command assumes (`./foreman.repo`). Perhaps make this copyable bash like everything else? I.e:

    cat > ./foreman.repo <<EOF
    <repo contents>
    EOF