Pure Storage Zero Touch Provisioning API Simulator in Azure Functions

In this post I want to demonstrate how I used Microsoft Azure Functions to build an online Pure Storage FlashArray simulator to test my code against while writing the ZTP tool.

FlashArray array-initial-config

{
"array_name": "tmefa10",
"ct0.eth0":
{
"address": "10.21.1.183",
"netmask": "255.255.255.0",
"gateway": "10.21.1.1"
},
"ct1.eth0":
{
"address": "10.21.1.184",
"netmask": "255.255.255.0",
"gateway": "10.21.1.1"
},
"vir0":
{
"address": "10.21.1.182",
"netmask": "255.255.255.0",
"gateway": "10.21.1.1"
},
"dns":
{
"domain": "dev.purestorage.com",
"nameservers":
[
"10.14.240.240"
]
},
"ntp_servers":
[
"time1.purestorage.com"
],
"timezone": "America/Los_Angeles",
"smtp":
{
"relay_host": "blackhole-smtp2.dev.purestorage.com",
"sender_domain": "purestorage.com"
},
"alert_emails":
[
"amin@purestorage.com"
],
"eula_acceptance":
{
"accepted": true,
"accepted_by":
{
"organization": "Pure Storage",
"full_name": "Syed Amin",
"job_title": "TME"
}
}
}
{
"status": "initializing",
"array_id": "",
"ct0.eth0":
{
"netmask": "255.255.255.0",
"address": "10.21.1.183",
"gateway": "10.21.1.1",
"mac_address": "24:a9:37:00:34:33"
},
"smtp":
{
"relay_host": "blackhole-smtp2.dev.purestorage.com",
"sender_domain": "purestorage.com"
},
"vir0":
{
"netmask": "255.255.255.0",
"address": "10.21.1.182",
"gateway": "10.21.1.1",
"mac_address": ""
},
"alert_emails":
[
"amin@purestorage.com"
],
"ct1.eth0":
{
"netmask": "255.255.255.0",
"gateway": "10.21.1.1",
"address": "10.21.1.184"
},
"ntp_servers":
[
"time1.purestorage.com"
],
"version": "5.2.4",
"eula_acceptance":
{
"accepted_by":
{
"organization": "Pure Storage",
"full_name": "Syed Amin",
"job_title": "TME"
},
"accepted": true
},
"progress": 0.01,
"dns":
{
"nameservers":
[
"10.14.240.240"
],
"domain": "dev.purestorage.com"
},
"timezone": "America/Los_Angeles",
"serial_number": "PCHFL17320104",
"os": "Purity//FA",
"array_name": "tmefa10"
}

--

--

Technology fanatic, leadership enthusiast, and all around decent human being. *The statements and opinions on this site are my own and only my own.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Brandon Showers

Technology fanatic, leadership enthusiast, and all around decent human being. *The statements and opinions on this site are my own and only my own.