Skip to content

Instantly share code, notes, and snippets.

View kingpabel's full-sized avatar

Imtiaz Ahmed kingpabel

View GitHub Profile
{"version":1,"resource":"file:///Users/imtiazpabel/Applications/laravel/vendor/stackkit/laravel-google-cloud-tasks-queue/src/CloudTasksQueue.php","entries":[{"id":"syBB.php","timestamp":1662370014151},{"id":"Vz5m.php","timestamp":1662370034157},{"id":"rT3D.php","timestamp":1662370046245},{"id":"blYJ.php","timestamp":1662370085761},{"id":"E09f.php","timestamp":1662370157532},{"id":"hfSz.php","timestamp":1662370171890},{"id":"Q9Cu.php","timestamp":1662370341745}]}
import VuePagination from 'VuePagination-component.js';
new Vue ({
el : "#userTable",
data : {
users : {
current_page : 1
},
},
export default {
props: {
pagination: {
type: Object,
required: true
},
offset: {
type: Number,
default: 4
}
@kingpabel
kingpabel / ClearBeanstalkdQueue.php
Created December 18, 2016 12:13
Laravel 5.1 compatible command which allows to clear Beanstalkd queue.
<?php
namespace App\Console\Commands;
use Illuminate\Console\Command;
use Illuminate\Queue\Connectors\BeanstalkdConnector;
use Pheanstalk\Pheanstalk;
class ClearBeanstalkdQueue extends Command
{
//install docker
https://docs.docker.com/engine/installation/linux/ubuntulinux/
//install docker compose
https://docs.docker.com/compose/install/
//create a docker compose file which name will be "docker-compose.yml" and put below nginx image
web:
image: nginx:latest
ports:
if (CKEDITOR.instances[‘previous_filed_name’]) {
CKEDITOR.instances[‘previous_filed_name’].destroy(true);
}
CKEDITOR.replace(‘new_filed_name’);
[program:laravel-queue]
process_name=%(program_name)s_%(process_num)02d
command=php /var/www/html/project/artisan queue:work sqs --sleep=3 --tries=3
autostart=true
autorestart=true
user=forge
numprocs=2
redirect_stderr=true
stdout_logfile=/var/www/html/project/storage/logs/supervisor.log
sudo apt-get install apache2 nginx nginx-full php7.0 php7.0-cgi php7.0-cli php7.0-common php7.0-curl php7.0-dev php7.0-fpm php7.0-gd php7.0-imap php7.0-intl php7.0-json php7.0-mcrypt php7.0-mysql php7.0-xmlrpc mysql-client mysql-server mysql-workbench phpmyadmin git nodejs nodejs-dev curl memcached php7.0 libapache2-mod-php7.0
docker pull ubuntu:14.04.4 //for pull image
sudo service docker start //docker start
sudo docker images //list of docker images
sudo docker run -it ubuntu /bin/bash //accessing docker images
sudo docker run -it imtiaz/apache //after commit access another images
sudo docker -d -p 1000:80 imtiaz/apache //run docker from local
<?php
//Email configuration is set in static method,that's why when same request multiple time email configuration changed,it was not work.
//for more details http://laravel.io/forum/07-22-2014-swiftmailer-with-dynamic-mail-configuration
$app = \App::getInstance();
$app['swift.transport'] = $app->share(function ($app) {
return new TransportManager($app);
});