forked from magepow/magento-2-programmatically
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathaddSchemaModule.php
More file actions
23 lines (19 loc) · 807 Bytes
/
addSchemaModule.php
File metadata and controls
23 lines (19 loc) · 807 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
<?php
require dirname(__FILE__) . '/app/bootstrap.php';
$bootstrap = \Magento\Framework\App\Bootstrap::create(BP, $_SERVER);
class Outslide extends \Magento\Framework\App\Http
implements \Magento\Framework\AppInterface {
public function launch()
{
$installSchema = $this->_objectManager->create('\Magepow\ModuleName\Setup\InstallSchema');
$context = $this->_objectManager->create('\Magento\Setup\Model\ModuleContext', ['version' => '1.0.0']);
$setup = $this->_objectManager->create('\Magento\Setup\Module\Setup');
$installSchema->install($setup, $context);
echo 'Done!';
//the method must end with this line
return $this->_response;
}
}
/** @var \Magento\Framework\App\Http $app */
$app = $bootstrap->createApplication('Outslide');
$bootstrap->run($app);