jump into squeak - integrate squeak projects with docker & github
TRANSCRIPT
Jump into DevelopmentSelf-Sustaining Systems
Hubert Hesse, Robert LehmannSoftware Architecture Group
Hasso Plattner Institute
© 2008 by FF-Kostheim, https://www.flickr.com/photos/ffkostheim/2533995614Throughout this presentation,
Amazon Web Services and its logos are trademarks of Amazon.com, Inc.Docker and its logos are trademarks of Docker, Inc.Git and its logos are trademarks of Software Freedom Conservancy
Install dependenciesFileTree, Metacello
Installer ss3 project: 'FileTree'; install: 'ConfigurationOfFileTree'. ((Smalltalk at: #ConfigurationOfFileTree) project version: '1.0') load.
(Smalltalk at: #Gofer) new url: 'http://seaside.gemtalksystems.com/ss/metacello'; package: 'ConfigurationOfMetacello'; load. ((Smalltalk at: #ConfigurationOfMetacello) project version: #'previewBootstrap') load. (Smalltalk at: #Metacello) new configuration: 'MetacelloPreview'; version: #'stable'; repository: 'github://dalehenrich/metacello-work:configuration'; get. (Smalltalk at: #Metacello) new configuration: 'MetacelloPreview'; version: #'stable'; repository: 'github://dalehenrich/metacello-work:configuration'; load.
7
© 2010 by iragazzidiredbull, https://www.flickr.com/photos/redbullfanclub/4618355162
☛ install Squeak☛ clone repository☛ install repository☛ try out☛ make changes☛ fork repository☛ change upstream☛ commit to Monticello☛ commit to Git☛ push repository
☹ complex installation☹ duplicate input☹ much boilerplate☹ many roundtrips
Jump into Development …very carefully
19
The Docker logo © Docker, Inc.Git Logo © Jason Long
docker + Github
Automated Squeak Deployment
20
© 2008 by Roberto Ventre, https://www.flickr.com/photos/robie06/4653351388
☛ install Squeak☛ clone repository☛ install repository☛ try out☛ make changes☛ fork repository☛ change upstream☛ commit to Monticello☛ commit to Git☛ push repository☛ fork own repository☛ pull request
setup
commit
setup
commit
22
setup Squeak instances on-demand
☛ install Squeak☛ install Squeak libraries☛ clone repository☛ install repository☛ provide remote access
23
#!/bin/bashwget http://ftp.squeak.org/4.5/Squeak-4.5-All-in-One.zipecho “Installer ss3 install: 'FileTree'.“ > install.st./squeak.sh -headless install.st && vncstart -p $PORT
bare hands approach: Shell script.
☛ install Squeak☛ install Squeak libraries☛ clone repository☛ install repository☛ provide remote access
24
#!/bin/bashwget http://ftp.squeak.org/4.5/Squeak-4.5-All-in-One.zipecho “Installer ss3 install: 'FileTree'.“ > install.st./squeak.sh -headless install.st
bare hands approach: Shell script.
☛ install Squeak☛ install Squeak libraries☛ clone repository☛ install repository☛ provide remote access
poor performancere-run every deployment step time and time again
25
full-on approach: VM image.
Squeak-4.5-All-in-One/install.st
☛ install Squeak☛ install Squeak libraries☛ clone repository☛ install repository☛ provide remote access
26
full-on approach: VM image. (includes OS)
Squeak-4.5-All-in-One/install.st
☛ install Squeak☛ install Squeak libraries☛ clone repository☛ install repository☛ provide remote access
heavy footprintimage needs to include everything
27
Linux
Libraries (Git, VNC, …)
Squeak
Commit supportRepository V
NC
Solution: Linux Containers via Docker.
☛ install Squeak☛ install Squeak libraries☛ clone repository☛ install repository☛ provide remote access
28
☛ install Squeak☛ install Squeak libraries☛ clone repository☛ install repository☛ provide remote access
Linux
Libraries (Git, VNC, …)
Squeak
Commit supportRepository V
NC
Solution: Linux Containers via Docker.
linux containersLXC allows optimizations, eg. kernel samepage merging
union filesystemAUFS stores delta only
containers are configurable versioning, isolation, port mapping
29
© 2008 by Roberto Ventre, https://www.flickr.com/photos/robie06/4653351388
☛ install Squeak☛ clone repository☛ install repository☛ try out☛ make changes☛ fork repository☛ change upstream☛ commit to Monticello☛ commit to Git☛ push repository☛ fork own repository☛ pull request
setup
commit
setup
commit
✔
30
middleware
middleware
maintenance burdenSingle Point of Failure
limited resourceswho pays the dime?
33
IE © by Pit-tux, http://findicons.com/icon/13282/ie Amazon Web Services is a trademark of Amazon.com, Inc.34
IE © by Pit-tux, http://findicons.com/icon/13282/ie Amazon Web Services is a trademark of Amazon.com, Inc.
requires AWS accountthere is no free lunch
35
IE © by Pit-tux, http://findicons.com/icon/13282/ie Amazon Web Services is a trademark of Amazon.com, Inc.
Same Origin PolicyEC2 not usable in aws-sdk.js
requires AWS accountthere is no free lunch
36
IE © by Pit-tux, http://findicons.com/icon/13282/ie Amazon Web Services is a trademark of Amazon.com, Inc.
CORS proxy
37
IE © by Pit-tux, http://findicons.com/icon/13282/ie Amazon Web Services is a trademark of Amazon.com, Inc.
CORS proxy
AWS credentials in the open
38
© 2008 by Roberto Ventre, https://www.flickr.com/photos/robie06/4653351388 Amazon Web Services is a trademark of Amazon.com, Inc.
☛ install Squeak☛ clone repository☛ install repository☛ try out☛ make changes☛ fork repository☛ change upstream☛ commit to Monticello☛ commit to Git☛ push repository☛ fork own repository☛ pull request
setup
commit
setup
commit
✔deploydeploy
✔
( )
39
repository .filetree Signals.package
.filetree (omitted from here on for brevity)
monticello.meta package version postscript
SignalTest.class README.md properties.json methodProperties.json instance
test01ConnectDisconnect.st class
new.st …
41
repository .filetree Signals.package
.filetree (omitted from here on for brevity)
monticello.meta package version postscript
SignalTest.class README.md properties.json methodProperties.json instance
test01ConnectDisconnect.st class
new.st …
this file is being writtenby a Monticello save*
actually, MCFileTreeRepository just deletes the top-level repository and writes out everything fresh.42
repository .filetree Signals.package
.filetree (omitted from here on for brevity)
monticello.meta package version postscript
SignalTest.class README.md properties.json methodProperties.json instance
test01ConnectDisconnect.st class
new.st …
this file is being writtenby a Monticello save*
actually, MCFileTreeRepository just deletes the top-level repository and writes out everything fresh.
poll directory for changeseg. inotifywait black-box approach
43
repository .filetree Signals.package
.filetree (omitted from here on for brevity)
monticello.meta package version postscript
SignalTest.class README.md properties.json methodProperties.json instance
test01ConnectDisconnect.st class
new.st …
this file is being writtenby a Monticello save*
actually, MCFileTreeRepository just deletes the top-level repository and writes out everything fresh.
poll directory for changeseg. inotifywait black-box approach
unclear interaction for credentialsfrom console, system dialogs, key store?
extra environmentrace conditions, auxiliary binary, setup per repository
44
Monticello
MCGithubRepository
git-clone git-push git-commit hub fork
authorized
MCFileTreeRepository
51
Monticello
MCGithubRepository
git-clone git-push git-commit hub fork
authorized
git-credential-store environment
52
© 2008 by Roberto Ventre, https://www.flickr.com/photos/robie06/4653351388
☛ install Squeak☛ clone repository☛ install repository☛ try out☛ make changes☛ fork repository☛ change upstream☛ commit to Monticello☛ commit to Git☛ push repository☛ fork own repository☛ pull request
setup
commit
setup
commit
✔
✔
53
Quickstart☛ Open Monticello☛ Create a Github repository☛ Save package to Github
repository
☛ Add Docker instructions¹☛ Add packaging instructions²☛ Add jump into button3
☛ Commit☛ Optional: Setup Monticello
postscript to load your application
¹ DockerfileFROM lehmannro/squeakADD . /checkoutCMD run.sh
2 .packagesSignals
3 README.md[![Jump into](shields.io/badge/jump-into-green.svg)](http://novnc.com/?autoconn…)
a new Github repository
54
© 2010 by Andy Atmtx, https://www.flickr.com/photos/atmtx/4842894834
Git support in Squeak for free!remote
61
© 2008 by Roberto Ventre, https://www.flickr.com/photos/robie06/4483015383
↪ deploy on AWSfrom user credentials
↪ support multiple versions in Monticello
↪ make bootstrapping easier(install from SS3)
↪ image retrieval from session
Next Steps Limitations
✗ copious Windows deployment1
✗ restricts Git to pure sequential history(no tags, branches)
✗ no git-merge during merge conflicts
✗ Docker SaaS’esstill experimental
✗ Docker Index a SPoF
[1] http://docs.docker.com/installation/windows/
62
© 2008 by Roberto Ventre, https://www.flickr.com/photos/robie06/4653351388
☛ install Squeak☛ clone repository☛ install repository☛ try out☛ make changes☛ fork repository☛ change upstream☛ commit to Monticello☛ commit to Git☛ push repository☛ fork own repository☛ pull request
setup
commit
setup
commit
✔
✔
http://github.com/lehmannro/metacello-githttp://github.com/lehmannro/squeak-docker
63
git:///signals/
extend Monticello
Thierry Goubier’s filetreehttps://github.com/ThierryGoubier/filetree
FileTree on steroids, onlyno push, pull, fork
Tim Felgentreff’s Git O’cellohttps://github.com/timfel/gitocello
new Registry, Package Format, git hooks
emulate MCZ for squeakvm
complex setup
Dale Henrichs’ BuilderCIhttps://github.com/dalehenrich/builderCI
collection of bash scripts to execute tests with travis ci
provides compatibility with GLASS, Pharo and Squeak
complex