clearlinux / micro-config-drive

An alternative and small cloud-init implementation in C
Other
46 stars 17 forks source link

UCD does not work with configurable cloud VM #26

Open markdryan opened 6 years ago

markdryan commented 6 years ago

ccloudvm is a tool for building VM based development environments from cloud images, such as clear linux. Unfortunately, I'm having some issues getting it to work with Clearlinux.

Most of the issues are related to the bugs below

https://github.com/clearlinux/micro-config-drive/issues/24 https://github.com/clearlinux/micro-config-drive/issues/25 https://github.com/clearlinux/micro-config-drive/issues/27 https://github.com/clearlinux/micro-config-drive/issues/28 https://github.com/clearlinux/micro-config-drive/issues/29 https://github.com/clearlinux/micro-config-drive/issues/30

I'm adding this issue as a meta bug to track everything. It's also a good place to keep the instructions needed to reproduce the issues. And here they are.

Download and install Go

Go 1.8 or above should work. If you don't have Go installed run the following commands.

  1. wget https://dl.google.com/go/go1.10.linux-amd64.tar.gz
  2. sudo tar -C /usr/local -xzf go1.10.linux-amd64.tar.gz
  3. export PATH=$PATH:/usr/local/go/bin
  4. export PATH=$PATH:$(go env GOPATH)/bin

Build the ccloudvm branch that supports clearlinux

  1. go get -d github.com/intel/ccloudvm/...
  2. cd $(go env GOPATH)/src/github.com/intel/ccloudvm
  3. git checkout -b markdryan-clear master
  4. git pull https://github.com/markdryan/ccloudvm.git clear
  5. go install ./...
  6. ccloudvm setup

Create a clearlinux instance

  1. ccloudvm create --debug clear-20910

Note that the command will never complete. This is because the cloud-init file is not processed correctly. However, if you follow the on screen instructions you should see a command that will allow you to connect to the instance, i.e., you should see something like this.

Booting VM with 1024 MiB RAM and 1 cpus
To connect to the instance during its creation type

    ssh -q -F /dev/null -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -o IdentitiesOnly=yes -i /home/user/.ccloudvm/id_rsa 127.3.232.1 -p 10022

Copy and paste that command into a new terminal and you should be able to connect to the instance. You may need to wait 10 seconds or so before the instance boots. Once connected to the instance you can check the ucd errors using journalctl.