Monitor celery by using celery -A freightquotes events
Start celery with beats celery -A freightquotes worker -B -E -l INFO --autoscale=2,1
Note:-
-B beats - to execute schedule tasks
-l log-level (INFO/DEBUG)
-E --task-events
var gulp = require("gulp"), | |
fastSass = require("gulp-sass"), | |
autoprefixer = require('gulp-autoprefixer'), | |
sourcemaps = require('gulp-sourcemaps'), | |
rename = require("gulp-rename"), | |
imagemin = require('gulp-imagemin'), | |
iconfont = require('gulp-iconfont'), | |
iconfontCss = require('gulp-iconfont-css'), | |
jshint = require('gulp-jshint'), | |
concat = require('gulp-concat-util'), |
from django import forms | |
class ContactForm(forms.ModelForm): | |
message = forms.CharField(label='Message', | |
required=True, | |
widget=forms.Textarea(attrs={'placeholder': 'First name'}), | |
error_messages={'required': 'Please enter your message.'}) |
cd /opt | |
yum -y update | |
yum -y install libstdc++ autoconf automake libtool autoconf-archive pkg-config gcc gcc-c++ make libjpeg-devel libpng-devel libtiff-devel zlib-devel | |
#Install AutoConf-Archive | |
wget ftp://mirror.switch.ch/pool/4/mirror/epel/7/ppc64/a/autoconf-archive-2016.09.16-1.el7.noarch.rpm | |
rpm -i autoconf-archive-2016.09.16-1.el7.noarch.rpm | |
#Install Leptonica from Source |
{% block content %} | |
<div class="row"> | |
<div class="col-xs-12"> | |
<div class="box box-info"> | |
<div class="box-header with-border"> | |
<h3 class="box-title">Credit Card</h3> | |
</div> | |
<form action="" method="post" id="payment-form"> | |
<div class="box-body"> | |
{% csrf_token %} |
# download https://nodejs.org/en/ | |
sudo chown -R $(whoami) $(npm config get prefix)/{lib/node_modules,bin,share} | |
npm init -y | |
npm set init.author.email "[email protected]" | |
npm set init.author.name "Lorne" | |
npm set init.license "MIT" | |
npm install express-generator -g |
# 1. update openssl | |
brew install openssl | |
brew link openssl --force | |
# 2.reinstall python | |
brew install python --with-brewed-openssl | |
# 3.re-create virtualenv | |
rm -rf env/ | |
virtualenv env --python=/usr/local/Cellar/python/2.7.14/bin/python |
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>KeepAlive</key> | |
<true/> | |
<key>Label</key> | |
<string>com.mysql.mysqld</string> | |
<key>ProgramArguments</key> | |
<array> |
# open Pycharm settings->Build,Execution,Deployment->Console->Django Console | |
# 1.add env var: DJANGO_SETTINGS_MODULE -> settings.settings | |
# 2.copy below into Starting script | |
# open preferences->keymap->search `Python Console`->create new shortcut `cmd + 3` | |
from pprint import pprint | |
from django_extensions.management.shells import import_objects | |
from django.core.management.color import no_style | |
from datetime import datetime |
openssl version | |
cd /home/install | |
wget https://www.openssl.org/source/openssl-1.0.2m.tar.gz | |
tar -zxf openssl-1.0.2m.tar.gz | |
cd openssl-1.0.2m/ | |
./config | |
make | |
make test | |
make install |