public function mounts()
    {
        $config = yaml_parse(file_get_contents(CONFIG . 'vault.yml'));
        $mounts = $this->Vault->sys()->mounts()->json();

        foreach ($config['secret_backends'] as $backend) {
            $this->out('Backend: ' . $backend['path']);

            if (!array_key_exists($backend['path'] . DS, $mounts)) {
                $this->info('  Creating ...');
                $resp = $this->Vault->sys()->createMount($backend['path'], [
                    'type' => $backend['type'],
                    'description' => isset($backend['description']) ? $backend['description'] : ''
                ]);
            } else {
                $this->success('  Already exist');
            }

            switch ($backend['type']) {
                case 'mysql':
                    $this->_mysqlBackend($backend);
                    break;

                default:
                    $this->_secretBackend($backend);
                    break;
            }

            $this->out('');
        }
    }
public function mounts()
    {
        $config = yaml_parse(file_get_contents(CONFIG . 'vault.yml'));
        $mounts = $this->Vault->sys()->mounts()->json();

        foreach ($config['secret_backends'] as $backend) {
            $this->out('Backend: ' . $backend['path']);

            if (!array_key_exists($backend['path'] . DS, $mounts)) {
                $this->info('  Creating ...');
                $resp = $this->Vault->sys()->createMount($backend['path'], [
                    'type' => $backend['type'],
                    'description' => isset($backend['description']) ? $backend['description'] : ''
                ]);
            } else {
                $this->success('  Already exist');
            }

            switch ($backend['type']) {
                case 'mysql':
                    $this->_mysqlBackend($backend);
                    break;

                default:
                    $this->_secretBackend($backend);
                    break;
            }

            $this->out('');
        }
    }
public function mounts ( ) { $ config = yaml_parse ( file_get_contents ( CONFIG . 'vault.yml' ) ) ; $ mounts = $ this -> Vault -> sys ( ) -> mounts ( ) -> json ( ) ; foreach ( $ config [ 'secret_backends' ] as $ backend ) { $ this -> out ( 'Backend: ' . $ backend [ 'path' ] ) ; if ( ! array_key_exists ( $ backend [ 'path' ] . DS , $ mounts ) ) { $ this -> info ( '  Creating ...' ) ; $ resp = $ this -> Vault -> sys ( ) -> createMount ( $ backend [ 'path' ] , [ 'type' => $ backend [ 'type' ] , 'description' => isset ( $ backend [ 'description' ] ) ? $ backend [ 'description' ] : '' ] ) ; } else { $ this -> success ( '  Already exist' ) ; } switch ( $ backend [ 'type' ] ) { case 'mysql' : $ this -> _mysqlBackend ( $ backend ) ; break ; default : $ this -> _secretBackend ( $ backend ) ; break ; } $ this -> out ( '' ) ; } }
Create the required mount points

@return void
Create the required mount points