Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Buildout
Search
Radim Novotný
October 25, 2012
Programming
230
1
Share
Buildout
Radim Novotný
October 25, 2012
Other Decks in Programming
See All in Programming
Reactive ❤️ Loom: A Forbidden Love Story
franz1981
2
240
Alternatives to JPA 2026
debop
0
110
Liberating Ruby's Parser from Lexer Hacks
ydah
1
130
PHP で mp3 プレイヤーを実装しよう
m3m0r7
PRO
0
270
10 Tips of AWS ~Gen AI on AWS~
licux
5
380
SREに優しいTerraform構成 modulesとstateの組み方
hiyanger
1
110
Oxlintとeslint-plugin-react-hooks 明日から始められそう?
t6adev
0
250
「速くなった気がする」をデータで疑う
senleaf24
0
170
TiDBのアーキテクチャから学ぶ分散システム入門 〜MySQL互換のNewSQLは何を解決するのか〜 / tidb-architecture-study
dznbk
1
170
의존성 주입과 모듈화
fornewid
0
130
Vibe하게 만드는 Flutter GenUI App With ADK , 박제창, BWAI Incheon 2026
itsmedreamwalker
0
550
書籍「ユーザーストーリーマッピング」が私のバイブル
asumikam
3
290
Featured
See All Featured
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
510
Principles of Awesome APIs and How to Build Them.
keavy
128
17k
The Illustrated Guide to Node.js - THAT Conference 2024
reverentgeek
1
330
A Tale of Four Properties
chriscoyier
163
24k
sira's awesome portfolio website redesign presentation
elsirapls
0
210
Building a Scalable Design System with Sketch
lauravandoore
463
34k
Winning Ecommerce Organic Search in an AI Era - #searchnstuff2025
aleyda
1
2k
Have SEOs Ruined the Internet? - User Awareness of SEO in 2025
akashhashmi
0
320
The World Runs on Bad Software
bkeepers
PRO
72
12k
AI Search: Where Are We & What Can We Do About It?
aleyda
0
7.3k
Sam Torres - BigQuery for SEOs
techseoconnect
PRO
0
240
Measuring Dark Social's Impact On Conversion and Attribution
stephenakadiri
1
180
Transcript
Buildout Radim Novotný PyVo 25.10.2012
Co je to buildout? • zc.buildout (od r. 2006) •
opakovatelný deployment • nejen python • izolované prostředí na fs • rozšiřitelnost http://www.buildout.org
Syntaxe [buildout] parts = pokus [pokus] recipe = zc.recipe.egg interpreter
= mypython eggs = odict
Jak na to • wget http://svn.zope.org/repos/main/zc.buildout/ trunk/bootstrap/bootstrap.py • edit buildout.cfg
• python bootstrap.py • bin/buildout
Recipes • djangorecipe, fez.djangoskel • z3c.recipe.ldap • collective.recipe.patch • collective.recipe.omelette
http://www.buildout.org/docs/recipelist.html PyPI – hledat „recipe“
Příklady použití • https://github.com/plone/buildout.coredev • https://github.com/collective/ buildout.python • https://github.com/diefenbach/ lfs-buildout-development
• http://code.google.com/p/typhoonae/source/ browse/buildout.cfg (memcache, nginx, mongodb, rabbitmq, celery, sphinx, ejabberd, ...)
Minimal Plone buildout [buildout] parts = instance extends = http://dist.plone.org/release/4.1-
latest/versions.cfg find-links = http://dist.repoze.org/ [instance] recipe = plone.recipe.zope2instance eggs = Plone PIL collective.gallery
Plone • wget bootstrap.py • python2.6 bootstrap.py • bin/buildout •
<zadat admin username/password> • bin/instance fg • http://127.0.0.1:8080
Deployment • buildout.cfg a jeho závislosti jsou jediné opravdu důležité
soubory pro deployment • na serveru – git clone/svn checkout – ln -s deployment.cfg buildout.cfg – python bootstrap.py – bin/buildout
BAF Jakub Vysoký - https://github.com/kvbik/python-baf
BAF [buildout] extensions = mr.developer parts = pybaf [sources] baf
= git https://github.com/kvbik/python-baf [pybaf] recipe = zc.recipe.egg interpreter = pybaf eggs = baf
# bin/pybaf >>> import baf >>> baf.__version__ (1, 0) #
bin/baf an example packaging layout see https://github.com/kvbik/python-baf for more version = 1.0 BAF
BAF bin/develop checkout baf bin/buildout -N • nyní bin/baf i
bin/pybaf používají clone z src/baf bin/develop deactivate baf bin/buildout -N • bin/baf a bin/pybaf – egg z PyPI
Závěr ✗ složitější setup než virtualenv (bootstrap.py) ✔ vhodné na
větší, složitější projekty ✔ izolované prostředí ✔ možné použít nejen pro Python packages (Python, SOLR, Apache, Varnish, SQL, Jenkins, supervisor, selenium, ...)
One more thing...
jarn.mkrelease • Python releaser • commit/tag git, svn, hg •
upload na PyPI, sftp, plone.org nebo jen vytvoření egg/zip • release zip, egg • http://pypi.python.org/pypi/jarn.mkrelease
jarn.mkrelease # cd src/baf # mkrelease -qCTS (no-commit, no-tag, no-upload)
Releasing baf 1.0 running egg_info running sdist done # ls dist/ baf-1.0.zip
Děkuji
[email protected]
/python-cs
[email protected]
@narocz