JosiahSiegel / azurerm_file_share_sftp

Minimal Terraform module to stand up a public sftp server on Azure.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

azurerm_file_share_sftp

Minimal Terraform module to stand up a public sftp server on Azure. This module uses Azure Files and Container instance.

input parameters

  • location

    azure region name.

    Run az account list-locations -o table to see a list of locations.

  • prefix

    prefix to use for new resources created by this module

  • sftp_user_name

    sftp user name

  • sftp_folder

    directory name to which upload and download files.

    this directory is mounted on the ftp user's home directory.

    azure file share is mounted on this folder.

    This is the only directory user can write to.

  • sftp_password

outputs

  • fqdn - FQDN of the sftp server
  • ip_address - IP address of the sftp server.

Example

examples folder a sample deployment that uses this module.

pre requeisites to run the example:

You would need your azure subscription_id, a service account (client_id, client_secret and tenant_id)

Check terraform docs for more information on how to setup the service account.

Run the example

$ cd examples
$ terraform init
$ terraform plan # to preview the changes.
$ terraform apply # to create the resources

Run the example

$ terraform plan -destory # to preview the changes
$ terraform destory # to clean up the resources.

About

Minimal Terraform module to stand up a public sftp server on Azure.


Languages

Language:HCL 100.0%