Skip to content

Comments

overlay cloudsigma: Set tty to RAW#1280

Merged
krnowak merged 4 commits intoflatcar:mainfrom
dosomder:cloudsigma-set-tty-raw
Oct 19, 2023
Merged

overlay cloudsigma: Set tty to RAW#1280
krnowak merged 4 commits intoflatcar:mainfrom
dosomder:cloudsigma-set-tty-raw

Conversation

@dosomder
Copy link
Contributor

@dosomder dosomder commented Oct 17, 2023

cloudsigma: Set TTY to RAW mode

According to cloudsigma's documentation at https://docs.cloudsigma.com/en/latest/server_context.html#setting-up-the-virtual-serial-port the TTY used to fetch the userdata / metadata should be in mode RAW.

With the flatcar beta 3732.1.0, fetching the data did not work anymore (the returned JSON was missing some bytes), without setting this mode correctly.

How to use

  • Machine on cloudsigma with flatcar image
  • Check output of oem-cloudinit.service if SSH keys and hostname were set -> it will fail
  • Set mode to RAW
  • Run service again -> it should work

Testing done

We tested it on our machines with a custom built image.

  • Changelog entries added in the respective changelog/ directory (user-facing change, bug fix, security fix, update)
  • Inspected CI output for image differences: /boot and /usr size, packages, list files for any missing binaries, kernel modules, config files, kernel modules, etc.

Copy link
Member

@krnowak krnowak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi,

Thanks for the PR!

It looks to me more like a bug somewhere inside coreos-cloudinit. It uses github.com/cloudsigma/cepgo to fetch metadata. This in turn uses github.com/tarm/goserial, so I'd say that the issue is somewhere there. But looking at the packages, they seem to be old/unmaintained/deprecated. Meh.

I suppose we could go with this workaround. Could you then bump the revision of the oem-cloudsigma ebuild from 2 to 3, please? So it's oem-cloudsigma-0.0.3-r3.ebuild. Thanks!

@dosomder
Copy link
Contributor Author

@krnowak To bump the revision, do I simply rename the file? And you probably mean to r4 since it is currently at r3
https://github.com/flatcar/scripts/blob/main/sdk_container/src/third_party/coreos-overlay/coreos-base/oem-cloudsigma/oem-cloudsigma-0.0.3-r3.ebuild

Co-authored-by: Krzesimir Nowak <qdlacz@gmail.com>
@krnowak
Copy link
Member

krnowak commented Oct 18, 2023

@krnowak To bump the revision, do I simply rename the file?

Yep.

And you probably mean to r4 since it is currently at r3 https://github.com/flatcar/scripts/blob/main/sdk_container/src/third_party/coreos-overlay/coreos-base/oem-cloudsigma/oem-cloudsigma-0.0.3-r3.ebuild

Ah, right. Yeah, should be bumped to -r4. Sorry for the confusion.

@github-actions
Copy link

Build action triggered: https://github.com/flatcar/scripts/actions/runs/6561971502

Copy link
Member

@krnowak krnowak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@krnowak krnowak merged commit 9bd49b7 into flatcar:main Oct 19, 2023
@dosomder
Copy link
Contributor Author

Thanks for the fast review @krnowak !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants