src-d / terraform-provider-online

Terraform provider for Online.net
Mozilla Public License 2.0
19 stars 13 forks source link

Provider does not detect missing online token #33

Closed rporres closed 6 years ago

rporres commented 6 years ago

The problem is in https://github.com/src-d/terraform-provider-online-net/blob/master/provider/provider.go#L24 as it is setting the token to "" and it is not detected as missing. It should be something like:

DefaultFunc: schema.EnvDefaultFunc(TokenEnvVar, nil),
denwwer commented 6 years ago

Hi, I can take care of this

rporres commented 6 years ago

Great! Thx, @denwwer. You will need to take care of the unit tests which will break once you set the default value to nil

meyskens commented 6 years ago

Fixed in #35