-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'hashicorp:main' into 25803
- Loading branch information
Showing
3 changed files
with
33 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -38,20 +38,21 @@ If you wish to work on the provider, you'll first need [Go](https://go.dev/) ins | |
First clone the repository to: `$GOPATH/src/github.com/hashicorp/terraform-provider-azurerm` | ||
|
||
```sh | ||
$ mkdir -p $GOPATH/src/github.com/hashicorp; cd $GOPATH/src/github.com/hashicorp | ||
$ git clone [email protected]:hashicorp/terraform-provider-azurerm | ||
$ cd $GOPATH/src/github.com/hashicorp/terraform-provider-azurerm | ||
mkdir -p $GOPATH/src/github.com/hashicorp; cd $GOPATH/src/github.com/hashicorp | ||
git clone [email protected]:hashicorp/terraform-provider-azurerm | ||
cd $GOPATH/src/github.com/hashicorp/terraform-provider-azurerm | ||
``` | ||
|
||
Once inside the provider directory, you can run `make tools` to install the dependent tooling required to compile the provider. | ||
|
||
At this point you can compile the provider by running `make build`, which will build the provider and put the provider binary in the `$GOPATH/bin` directory. | ||
|
||
```sh | ||
$ make build | ||
... | ||
$ $GOPATH/bin/terraform-provider-azurerm | ||
... | ||
make build | ||
# ... make output omitted ... | ||
# The provider binary will be output to: | ||
# $GOPATH/bin/terraform-provider-azurerm | ||
# ... | ||
``` | ||
|
||
You can also cross-compile if necessary: | ||
|
@@ -63,7 +64,7 @@ GOOS=windows GOARCH=amd64 make build | |
In order to run the `Unit Tests` for the provider, you can run: | ||
|
||
```sh | ||
$ make test | ||
make test | ||
``` | ||
|
||
The majority of tests in the provider are `Acceptance Tests` - which provisions real resources in Azure. It's possible to run the entire acceptance test suite by running `make testacc` - however it's likely you'll want to run a subset, which you can do using a prefix, by running: | ||
|
@@ -140,11 +141,11 @@ When `make generate` is run, this will then generate the following for this Reso | |
You can scaffold the documentation for a Data Source by running: | ||
|
||
```sh | ||
$ make scaffold-website BRAND_NAME="Resource Group" RESOURCE_NAME="azurerm_resource_group" RESOURCE_TYPE="data" | ||
make scaffold-website BRAND_NAME="Resource Group" RESOURCE_NAME="azurerm_resource_group" RESOURCE_TYPE="data" | ||
``` | ||
|
||
You can scaffold the documentation for a Resource by running: | ||
|
||
```sh | ||
$ make scaffold-website BRAND_NAME="Resource Group" RESOURCE_NAME="azurerm_resource_group" RESOURCE_TYPE="resource" RESOURCE_ID="/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1" | ||
make scaffold-website BRAND_NAME="Resource Group" RESOURCE_NAME="azurerm_resource_group" RESOURCE_TYPE="resource" RESOURCE_ID="/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1" | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters