Beispiel #1
0
 private function getConnectionOptions()
 {
     return array('key' => $this->config->getAccessKey(), 'secret' => $this->config->getSecretKey(), 'region' => $this->config->getRegion());
 }
Beispiel #2
0
 private function getAlarmActions()
 {
     return array('arn:aws:automate:' . $this->config->getRegion() . ':ec2:terminate', 'arn:aws:sns:' . $this->config->getRegion() . ':682510200394:TerminateInstanceBecauseIdle');
 }
 private function launchInstance(OutputInterface $output, $useOneInstancePerTestSuite, Config $awsConfig, $testSuite)
 {
     $awsInstance = new Instance($awsConfig, $testSuite);
     if ($useOneInstancePerTestSuite) {
         $awsInstance->enableUseOneInstancePerTestSuite();
     }
     $launcher = new InstanceLauncher($awsInstance);
     $host = $launcher->launchOrResumeInstance();
     $output->writeln(sprintf("Access instance using <comment>ssh -i %s ubuntu@%s</comment>", $awsConfig->getPemFile(), $host));
     $output->writeln("You can log in to Piwik via root:secure at <comment>http://{$host}</comment>");
     $output->writeln("You can access database via root:secure (<comment>mysql -uroot -psecure</comment>)");
     $output->writeln("Files are located in <comment>~/www/piwik</comment>");
     $output->writeln(' ');
     return $host;
 }