This web is sample how to use Azure Blob Storage using Yii2 PHP Framework and was published here to fulfill the submission on Dicoding MACD. Please use this app for studying only.
Make sure you have PHP and composer installed on your machine, to Install required Vendors run this command:
composer install
OR
php composer.phar install
To configure Azure Blob Storage, open config/params.php
and fill up with your Azure credential
<?php
return [
'adminEmail' => 'admin@example.com',
'azureStorageAccountName' => '<your account name>',
'azureStorageAccountKey' => '<your key>',
'azureStorageContainerName' => '<your container>',
];
You can change azureStorageContainerName
later like this:
$azure = new AzureClient();
$azure->containerName = 'abc123';
To configure Azure Cognitive, open config/params.php
and put your Azure Cognitive Key:
'azureCognitiveKey' => '<your Azure Cognitive key>'
To run the app, execute command on your root directory:
On Unix
./yii serve
On Windows
yii serve