Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How do you access user_data inside instance? #89

Closed
dcode opened this issue May 4, 2020 · 3 comments
Closed

How do you access user_data inside instance? #89

dcode opened this issue May 4, 2020 · 3 comments
Labels
Milestone

Comments

@dcode
Copy link

dcode commented May 4, 2020

In your example, you show passing a JSON document into the instance:

user_data = file("${module.path}/user_data")

I've looked into cloud-init and ignition, and neither have support for a virtualbox specific interface. Ignition does have an open issue [1] considering using DMI data which can be set using specific virtualbox "extradata" keys.

My specific goal is to be able to locally test projects using terraform + ignition. This provider seems to be the closest option for now since the VIX provider is quite old now.

[1] coreos/ignition#629

@dcode dcode changed the title How How do you access user_data inside instance? May 4, 2020
@VoyTechnology
Copy link
Member

I’ve also noticed this. I’ve been looking for solutions and it seems the only way to do so is by creating an iso file with the config and mounting it. Right now it is being set as extra data in virtual box only, and it doesn’t seem to work.

@Kraktorist
Copy link

Looks like it can be implemented using sharedfolder functionality.

VBoxManage sharedfolder add VM_NAME --name user_data --transient -hostpath /path/VM_NAME_user_data -automount

@VoyTechnology
Copy link
Member

Closing in favour of #150. But will keep the proposed solution in mind.

@VoyTechnology VoyTechnology closed this as not planned Won't fix, can't repro, duplicate, stale Sep 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants