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

load values from ~/.config/equinix/metal.yaml #66

Merged
merged 3 commits into from
Sep 14, 2021
Merged

Conversation

displague
Copy link
Member

@displague displague commented Aug 4, 2021

Relates to #63

Loads ~/.config/equinix/metal.yaml (as configured by the metal-cli) as an initial config value source. METAL_CONFIG can be set in the environment to supply an alternate config file.

This makes the following fields configurable via file:

	Token     string `json:"token,omitempty"`
	AuthToken string `json:"auth-token,omitempty"`
	Facility  string `json:"facility,omitempty"`
	Metro     string `json:"metro,omitempty"`
	OS        string `json:"operating-system,omitempty"`
	Plan      string `json:"plan,omitempty"`
	ProjectID string `json:"project-id,omitempty"`

token is preferred to auth-token. Either field will set --metal-api-key.

The field names in the file match what the metal-cli expects (in 0.6.0-alpha3, these names could change before final release).

With the metal-cli configuration and the existing docker-machine-driver defaults, no arguments need to be provided to create a node.

Signed-off-by: Marques Johansson <mjohansson@equinix.com>
Signed-off-by: Marques Johansson <mjohansson@equinix.com>
Signed-off-by: Marques Johansson <mjohansson@equinix.com>
@displague displague merged commit a00bb7e into main Sep 14, 2021
@displague displague deleted the config-file branch September 14, 2021 17:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant