Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- echo "> Staging Default Profile ..."
- cat <<EOF > /tmp/lxd-profile-default.yaml
- config:
- user.user-data: |
- #cloud-config
- package_upgrade: true
- packages:
- - jq
- - vim
- - lnav
- - byobu
- - snapd
- - squashfuse
- ssh_import_id: ${ccio_SSH_UNAME}
- users:
- - name: ubuntu
- shell: /bin/bash
- sudo: ['ALL=(ALL) NOPASSWD:ALL']
- ssh_import_id: ${ccio_SSH_SERVICE}:${ccio_SSH_UNAME}
- - name: ${ministack_UNAME}
- shell: /bin/bash
- sudo: ['ALL=(ALL) NOPASSWD:ALL']
- ssh_import_id: ${ccio_SSH_SERVICE}:${ccio_SSH_UNAME}
- runcmd:
- - [apt-get, autoremove, "-y"]
- - [cp, "-f", "/etc/skel/.bashrc", "/root/.bashrc"]
- - [cp, "-f", "/etc/skel/.bashrc", "/home/ubuntu/.bashrc"]
- - [cp, "-f", "/etc/skel/.bashrc", "/home/${ministack_UNAME}/.bashrc"]
- description: Default LXD Profile
- devices:
- eth0:
- name: eth0
- nictype: macvlan
- parent: external
- type: nic
- root:
- path: /
- pool: default
- type: disk
- name: default
- EOF
- echo "> Loading Default Profile ..."
- lxc profile edit default < /tmp/lxd-profile-default.yaml
- echo "> Default Profile is ready to use"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement