Freebox Provider
A terraform
provider to interact with the Freebox modem from the French internet service provider Free and built on top of free-go
.
Credentials
Generating credentials
The provider binary is equipped with an addional flag that toggles a special behavior. After a series of prompts to build the request the application will contact your Freebox to configure credentials and log them in your terminal.
First, head to the release page and download the latest provider according to your platform.
Then, decompress the archive and run the binary with the authorize
argument, for example:
terraform-provider-freebox_v1.0.0 authorize
ℹ️ You might need to make the binary executable depending on your OS.
Then follow the prompts and you should get yourself a valid token to interact with your Freebox.
Configuring permissions
At the time of this writing, the managment of permissions can not be done via the API. It must be done manually through the freebox OS web UI.
If you need to change the default set of permissions, first head to http://mafreebox.freebox.fr and log in.
Then open the Paramètres de la Freebox
menu, double click on Gestion des accès
and switch to the Applications
tab.
You should see the application you just registered earlier ; click on the Editer
icon 🖉
.
Finally, pick the permissions your application requires. For a basic usage the following ones are good enough:
Accès au gestionnaire de téléchargements
Accès aux fichiers de la Freebox
Modification des réglages de la Freebox
Contrôle de la VM
Example
terraform {
required_providers {
freebox = {
source = "registry.terraform.io/nikolalohinski/freebox"
}
}
}
provider "freebox" {
endpoint = "http://mafreebox.freebox.fr"
api_version = "v10"
}
Schema
Optional
api_version
(String) The version of the API to use (env:FREEBOX_VERSION
) (default:"latest"
)app_id
(String, Sensitive) The ID of the application you created to authenticate to the Freebox (see the login documentation) (env:FREEBOX_APP_ID
)endpoint
(String) The address of the Freebox (env:FREEBOX_ENDPOINT
) (default:"http://mafreebox.freebox.fr"
)token
(String, Sensitive) The private token to authenticate to the Freebox (see the login documentation) (env:FREEBOX_TOKEN
)