User:GDubuc (WMF)/Notes

These are just some development-related notes. Things that are useful and which I can't ever remember on the top of my head.

Servers

Update limn data: stat1003.wikimedia.org

Check beta uploads: deployment-upload.eqiad.wmflabs

eval.php etc.: mwmaint1001.eqiad.wmnet (was terbium)

Beta logs:deployment-fluorine.eqiad.wmflabs /srv/mw-log

Production logs: fluorine.eqiad.wmnet /a/mw-log

Testwiki: mw1017.eqiad.wmnet

Image scaler: mw1153.eqiad.wmnet

Beta Varnish: deployment-cache-upload04.eqiad.wmflabs

Beta Swift: deployment-ms-fe01.eqiad.wmflabs

Production Swift proxy server: ms-fe1005.eqiad.wmnet

Beta Puppet: deployment-puppetmaster.eqiad.wmflabs

Templates

in an image description to request its deletion on enwiki

Extensions

Nuke lets one remove content from a wiki without having to manually delete or recreate the VM

Analytics

fab multimedia deploy.only_data --user gilles

Raw eventlogging

stat1002:/a/eventlogging/archive

Exiftool

ICC profile name: exiftool -DeviceModelDesc -S -T 1.jpg

Assign new ICC profile: exiftool "-icc_profile<=tinyrgb.icc" 5.jpg

Delete empty directories

find. -type d -empty -exec rmdir {} \;

ImageMagick from source

Dependencies: apt-get install libmagickwand-dev

Creating new repo

ssh -p 29418 gerrit.wikimedia.org gerrit create-project --require-change-id --owner=performance --parent=thumbor --description='"Foo"' thumbor/bar

Create a new cowbuilder image

sudo cowbuilder --create

Backporting a package

dpkg-source -x foo.dsc

dch --bpo

pdebuild --pbuilder cowbuilder

debuild -b -uc -us

dpkg-buildpackage -us -uc -F

Builing a package with pybuild

dh $@ --with python2,python3 --buildsystem=pybuild

Pybuild options

export PYBUILD_NAME=statsd

export PYBUILD_TEST_PYTEST=1

export PYBUILD_BEFORE_TEST=cp -R {dir}/partd/tests {build_dir}/partd/

export PYBUILD_AFTER_TEST=rm -fR {build_dir}/partd/tests

export PYBUILD_TEST_ARGS=partd

export PYBUILD_TEST_NOSE=1

export PYBUILD_TEST_ARGS=--with-doctest

Grab the watch file to use here

http://pypi.debian.net/should_dsl/watch

Check that the debian/watch file is fine

uscan --no-download --verbose

Run this twice to check that the clean rules are correct

DIST=sid dpkg-buildpackage -us -uc -F

Build in isolation for sid

sudo DIST=sid pbuilder build *.dsc

Deliverables end up here

/var/cache/pbuilder/sid-amd64/result/

Adding a package to the chroot

sudo DIST=sid pbuilder update --extrapackages apt-utils --override-config

sudo DIST=sid pdebuild --pbuilder cowbuilder update --extrapackages apt-utils

Restarting Thumbor in prod

sudo systemctl restart thumbor@*.service

Testing a Puppet change on Beta

!log Cherry-picking on deployment-puppetmaster02

ssh deployment-puppetmaster02.eqiad.wmflabs

sudo -i

cd /var/lib/git/operations/puppet

git fetch https://gerrit.wikimedia.org/r/operations/puppet refs/changes/48/315248/3 && git cherry-pick FETCH_HEAD (Download -> Cherry pick in gerrot)

Then on client puppet machine "puppet agent --test"

Find wikitech userid

https://tools.wmflabs.org/contact/