This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
try{ | |
$amazon = new AmazonEc2(); | |
$result = $amazon->createEc2(); | |
if($result){ | |
$crawlerSpawned = true; | |
} | |
}catch(\Aws\Ec2\Exception\Ec2Exception $e){ | |
echo "Exception Thrown. \n"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package worker; | |
import java.io.IOException; | |
import org.gearman.Gearman; | |
import org.gearman.GearmanFunction; | |
import org.gearman.GearmanServer; | |
import org.gearman.GearmanWorker; | |
import org.gearman.impl.GearmanImpl; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package crawler_worker; | |
import java.io.IOException; | |
import org.gearman.*; | |
import org.gearman.impl.*; | |
import crawler_worker.WorkerClient; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php namespace App\Models; | |
class GeneralModel{ | |
public function getGUID(){ | |
mt_srand((double)microtime()*15000);//optional for php 4.2.0 and up. | |
$charid = strtoupper(md5(uniqid(rand(), true))); | |
$uuid = substr($charid, 0, 8) | |
.substr($charid, 8, 4) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$data['email'] = $email; | |
$this->setConfirmationLink( $this->general->getGUID() ); | |
$data['email_confirmation_code'] = $this->getConfirmationLink(); | |
if( DB::insert('insert into leads (email, email_confirmation_code, created_date) | |
values (?, ?, now())', [$data['email'], $data['email_confirmation_code']]) ){ | |
return true; | |
}else{ | |
return false; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE TABLE `uconomyvehicleshop` ( | |
`id` int(11) NOT NULL, | |
`vehiclename` varchar(255) DEFAULT NULL, | |
`cost` decimal(10,0) DEFAULT NULL, | |
PRIMARY KEY (`id`) | |
) ENGINE=InnoDB DEFAULT CHARSET=latin1; | |
INSERT INTO `uconomyvehicleshop` (`id`, `vehiclename`, `cost`) | |
VALUES |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE TABLE `uconomyitemshop` ( | |
`id` int(11) NOT NULL, | |
`itemname` varchar(255) DEFAULT NULL, | |
`cost` decimal(10,0) DEFAULT NULL, | |
`buyback` decimal(10,0) DEFAULT NULL, | |
PRIMARY KEY (`id`) | |
) ENGINE=InnoDB DEFAULT CHARSET=latin1; | |
INSERT INTO `uconomyitemshop` (`id`, `itemname`, `cost`, `buyback`) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Libraries; | |
use Aws; | |
use Ec2Client; | |
use App\Models\ProjectsModel; | |
class AmazonEc2{ | |
protected $client; | |
protected $imageId; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Vue from 'vue' | |
import Router from 'vue-router' | |
Vue.use(Router) | |
export default new Router({ | |
routes: [ | |
{ | |
path: '/', | |
name: 'homescreen', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#find /web/ -maxdepth 1 -type d > domainlist.csv | |
find /web/ -maxdepth 1 -type d | sed 's/\/web\///g' > domainlist.csv | |
apachelogdir=/var/log/apache2/ | |
if [ "$(whoami)" != 'root' ]; then | |
echo "You have to execute this script as root user" | |
exit 1; | |
fi |
OlderNewer