#Installation de varnish sur Debian Wheezy
- Vérifier que la version 3.* de varnish sera installée :
apt-cache show varnish
- Installer varnish
apt-get update
#Installation de varnish sur Debian Wheezy
apt-cache show varnish
apt-get update
iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1')) | |
choco install MsSqlServer2012ExpressAdv -force | |
sqlcmd -S VAGRANT-2012-R2 -E -Q "CREATE DATABASE {{YOUR_DATABASE_NAME}};" | |
sqlcmd -S VAGRANT-2012-R2 -E -Q "USE {{YOUR_DATABASE_NAME}};CREATE LOGIN {{YOUR_DATABASE_USER}} WITH PASSWORD = '{{YOUR_DATABASE_PASSWORD}}'" | |
sqlcmd -S VAGRANT-2012-R2 -E -Q "USE {{YOUR_DATABASE_NAME}};CREATE USE {{YOUR_DATABASE_USER}} FOR LOGIN {{YOUR_DATABASE_USER}};" | |
sqlcmd -S VAGRANT-2012-R2 -E -Q "USE {{YOUR_DATABASE_NAME}};GRANT ALTER To {{YOUR_DATABASE_NAME}};" | |
sqlcmd -S VAGRANT-2012-R2 -E -Q "USE {{YOUR_DATABASE_NAME}};GRANT CONTROL To {{YOUR_DATABASE_NAME}};" | |
sqlcmd -S VAGRANT-2012-R2 -E -Q "USE {{YOUR_DATABASE_NAME}};EXEC sp_addrolemember 'db_owner', '{{YOUR_DATABASE_USER}}'" | |
sqlcmd -S VAGRANT-2012-R2 -E -Q "USE {{YOUR_DATABASE_NAME}};EXEC xp_instance_regwrite N'HKEY_LOCAL_MACHINE', N'Software\Microsoft\MSSQLServer\MSSQLServer', N'LoginMode', REG_DWORD, 2" |
#!/bin/bash | |
# include config | |
# config example below: | |
# | |
# | |
# Example deploy_config.sh | |
# | |
# dev_env() { |
$frenchHTTPCodes = array ( | |
"100" => "Attente de la suite de la requête", | |
"101" => "Acceptation du changement de protocole", | |
"102" => "WebDAV : Traitement en cours (évite que le client dépasse le temps d’attente limite).", | |
"118" => "Délai imparti à l'opération dépassé", | |
"200" => "Requête traitée avec succès", | |
"201" => "Requête traitée avec succès avec création d’un document", | |
"202" => "Requête traitée mais sans garantie de résultat", | |
"203" => "Information retournée mais générée par une source non certifiée", | |
"204" => "Requête traitée avec succès mais pas d’information à renvoyer", |
#!/bin/sh | |
# Fichier "lamp.sh" | |
apt-get update | |
apt-get -y install apache2 php5 mysql-server git vim | |
a2enmod rewrite php5 | |
service apache2 restart | |
apt-get -y install php-apc php5-gd php5-curl php5-mysql php5-xdebug php5-intl | |
apt-get -y install phpmyadmin | |
apt-get -y install curl | |
apt-get -y install iptables |
<?php | |
// src/ACSEO/AdminBundle/Admin/ProductAdmin.php | |
// ... | |
protected function configureFormFields(FormMapper $formMapper) | |
{ | |
// ... | |
$formMapper | |
->add('codes', 'sonata_type_model_autocomplete', array( |
#!/bin/bash | |
# The URL you want to check | |
url="HTTP_MY_AWESOME_URL" | |
status_code=$(curl -o /dev/null --silent --head --write-out '%{http_code}\n' $url) | |
date=`date` | |
# The channel or user you want to notify | |
channel="MY_CHANNEL" | |
# The displayed bot username |
# Dirty command line used to scan each gitlab repository and extract some stats | |
# in this case : foreach commit > 2014-01-01 get the number of commmits, number of line added, deleted grouped by users | |
rm /tmp/stats2014.csv; find /home/git/repositories -name .git -prune -o -name '*.git' -print | while read directory; do cd $directory; git log --after="2014-01-01" --format='%aN' |sort -u | while read name; do echo -en "Project\t$directory\t" >> /tmp/stats2014.csv; echo -en "Author\t$name\t" >> /tmp/stats2014.csv; git log --after="2014-01-01" --after="2014-01-01" --author="$name" --pretty=format:%ae | gawk -- '{ ++c; } END { printf "Number of commits\t%s\t",c; }' >> /tmp/stats2014.csv; git log --author="$name" --pretty=tformat: --numstat | awk '{ add += $1; subs += $2; loc += $1 - $2 } END { printf "Added lines\t%s\tRemoved lines\t%s\tTotal lines\t%s\n", add, subs, loc }' >> /tmp/stats2014.csv; done; done; | |
# Install git fame | |
gem install git_fame | |
# Install all vendors with source | |
rm -rf vendor/* | |
composer update --prefer-source | |
# Do the calculations. This might take 30 minutes to complete. | |
rm output.txt | |
find ./vendor -type d -depth 2 ! -path "./vendor/composer" -exec echo {} \; -exec git fame --sort=loc --hide-progressbar --repository={} \; >> output.txt |
#!/bin/sh | |
### BEGIN INIT INFO | |
# Provides: firewall | |
# Required-Start: $remote_fs $syslog | |
# Required-Stop: $remote_fs $syslog | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: Démarre les règles iptables | |
# Description: Charge la configuration du pare-feu iptables | |
### END INIT INFO |