AutoInstall - Cloud-Init setup using nocloud datasource
alex
ubuntu at spottedmouse.com
Wed Jan 13 15:22:12 UTC 2021
Hi Jerry,
Thanks for getting back to me. Here is the auto-install user-data file.
It goes on setting up some further partitions. My thought was to do the
basic setup using auto-install, and then do the remainder of the
configuration using cloud-init on first boot.
#cloud-config
autoinstall:
apt:
geoip: true
preserve_sources_list: false
primary:
- arches: [amd64, i386]
uri: http://au.archive.ubuntu.com/ubuntu
- arches: [default]
uri: http://ports.ubuntu.com/ubuntu-ports
version: 1
refresh-installer:
update: no
identity: {hostname: localhost, password:
$6$6XlVz3AIXnn5wnuu$rmJAexybhEgJRaCrZxg5S/bBx/JwEFGJIylQrS4gbJOy/K.5pj77bC6Be/kb4tKmFSUEaEzZAcDW0hX//UDeW0,
realname: User, username: user}
packages:
- net-tools
- docker.io
- ansible
reporting:
builtin:
type: print
ssh:
allow-pw: true
authorized-keys: []
install-server: true
late-commands:
- sed -ie 's/GRUB_TIMEOUT=.*/GRUB_TIMEOUT=10/'
/target/etc/default/grub
- sed -ie 's/GRUB_TIMEOUT_STYLE=hidden/#GRUB_TIMEOUT_STYLE=hidden/'
/target/etc/default/grub
storage:
swap:
size: 0
config:
- id: disk0
type: disk
ptable: gpt
name: main_disk
preserve: false
path: /dev/sda
wipe: superblock-recursive
grub_device: true
#Boot Partition
- id: disk0-part-boot
type: partition
number: 1
size: 1GB
device: disk0
flag: bios_grub
....
On 2021-01-13 18:40, Jerry Geis wrote:
> Hi Alex can you share your auto install file
> Thanks
>
> Jerry
>
> On Tuesday, January 12, 2021, alex <ubuntu at spottedmouse.com> wrote:
>
>> I am trying to setup a number of new servers on Ubuntu 20.4 LTS. So
>> far I
>> got the auto-install via PXE working.
>>
>> My plan is to use autoinstall for the basic setup to install the OS,
>> partition table and initial user.
>>
>> Once installed I was hoping to use something like clout-init /
>> nocloud to
>> install the customisation need to security and monitoring. Ideally I
>> was
>> just hoping to connect it to chef using cloud-init.
>>
>> However I have not been able to get cloud-init / nocloud-net
>> datasource
>> working.
>>
>> Tried updating /etc/default/grub with the following
>>
>> GRUB_DEFAULT=0
>> #GRUB_TIMEOUT_STYLE=hidden
>> GRUB_TIMEOUT=30
>> GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
>>
> GRUB_CMDLINE_LINUX_DEFAULT="serial=ds=nocloud-net;seedfrom=http://192.168
>> [1].
>> 0.172/ubuntu/config/"
>>
> GRUB_CMDLINE_LINUX="serial=ds=nocloud-net;seedfrom=http://192.168.0.172/ub
>> [2]
>> untu/config/"
>>
>> Any suggestions to get me in the right direction on how to get
>> nocloud-net working?
>>
>> No matter what I try it always reports:
>>
>> root at ubuntu-base:/home/user# cloud-init status --long
>> status: done
>> time: Wed, 06 Jan 2021 09:53:14 +0000
>> detail:
>> DataSourceNone
>>
>> And the httpd host which provides the configuration files is never
>> accessed.
>>
>> Kind regards
>> Alex
>>
>> --
>> ubuntu-users mailing list
>> ubuntu-users at lists.ubuntu.com
>> Modify settings or unsubscribe at:
>> https://lists.ubuntu.com/mailman/listinfo/ubuntu-users [3]
>
>
> Links:
> ------
> [1] http://192.168
> [2] http://192.168.0.172/ub
> [3] https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
More information about the ubuntu-users
mailing list