[Camps-users] Upcoming development session and a proposed way forward

Brian J. Miller brian at endpoint.com
Thu Jan 15 03:02:38 UTC 2009


Jon Jensen wrote:
> Folks,
> 
> Following up on this thread:
> 
> Brian Miller and I talked tonight and he wondered about the best way to 
> get some code out that he's been working on for a next-generation camp 
> prototype. For those who have commit access to our Git repository, feel 
> free to make a branch and publish any experiments or in-progress code 
> there.
> 
> I feel very protective of the master branch, because that's our production 
> camps codebase, so only safe bugfixes, minor feature enhancements, new 
> documentation, etc. should go there without prior discussion.
> 
> But go wild on other branches if you want and let's get some movement 
> towards version 4.
> 
> Thanks,
> Jon

I've pushed my initial work out under the brian_workup branch in a 
directory called "new_dev". This is intended as just a first iteration 
in an attempt to give us real (albeit very immature) code to actually 
run and test some of the things we've been ranting about. It has a 
somewhat absurd CPAN dependency list, it is intended to be installable 
from CPAN (since that is the package system I know best), and the most 
interesting thing it can do is create directories. Hardly a version 3 
replacement! *But* it is installable, has rudimentary architecture 
similar to Ethan's *original* proposals (not the latest one), takes a 
step towards improved configurability, a step away from pre-determined 
paths, and a big step towards unification of the command line interface. 
It has minimal documentation and unit tests, but it does have them. 
Speaking of the command line interface, it is inspired (downright stolen 
even) from Jon's slides from UTSOC, with a couple of minor changes 
because of the intent to support a much larger range of services, 
meaning commands like 'camp psql' are replaced with something like 'camp 
connect psql', aka allowing for a generic 'camp connect' command that is 
provided a service. Enough babbling...

Steps to get up and running...

1. Checkout the brian_workup branch

2. cd into new_dev/camps/  (subdirectory created by Module::Starter)

3. Build distribution files and install to a local path

perl Build.PL --install_base=~/local

4. Run minimal test suite

./Build test

5. Install script and libs to ~/local

./Build install

6. Copy config files into place and adjust contents, specifically 
eg/config/etc/camps/base.xml into ~/local, and eg/config/.camprc into ~/.

7. Indicate where camps base config is stored (defaults to /etc/camps if 
you really want to put it there and skip this step)

export CAMPS_CONFIG_DIR=~/local/etc/camps

8. Create ~/camp_storage directory (or path as specified in .camprc)

9. Run some commands (assuming ~/local/bin is in your $PATH)

 > camp   (outputs list of available commands)
 > camp help  (same as above)
 > camp make (outputs error that you need to provide more info)
 > camp make <type> <comment> (<type> based on base.xml config file) 
(creates ~/camp_storage/camp999 and ~/camp_storage/camp999/.camp with 
init file inside)
 > camp make <type> <comment> --number=25 (creates ~/camp_storage/camp25 
etc.)
 > camp destroy --number=999 (removes specified camp)

Let me know what questions people have. Thanks...

Manifest as follows so you don't have to clone for it:

.gitignore
Build.PL
Changes
lib/Camp.pm
lib/Camp/CLI.pm
lib/Camp/CLI/Command.pm
lib/Camp/CLI/Command/connect.pm
lib/Camp/CLI/Command/destroy.pm
lib/Camp/CLI/Command/exec.pm
lib/Camp/CLI/Command/info.pm
lib/Camp/CLI/Command/lint.pm
lib/Camp/CLI/Command/list.pm
lib/Camp/CLI/Command/make.pm
lib/Camp/CLI/Command/restart.pm
lib/Camp/CLI/Command/start.pm
lib/Camp/CLI/Command/test.pm
lib/Camp/CLI/Command/update.pm
lib/Camp/CLI/CommandWithNumber.pm
lib/Camp/Service.pm
lib/Camp/Service/AppServer.pm
lib/Camp/Service/AppServer/Interchange.pm
lib/Camp/Service/AppServer/Rails.pm
lib/Camp/Service/DB.pm
lib/Camp/Service/DB/MySQL.pm
lib/Camp/Service/DB/Postgres.pm
lib/Camp/Service/HTTP.pm
lib/Camp/Service/HTTP/Apache.pm
lib/Camp/Service/VCS.pm
lib/Camp/Service/VCS/Git.pm
lib/Camp/Service/VCS/Subversion.pm
Makefile.PL
MANIFEST
META.yml
README
scripts/camp
t/00-load.t
t/boilerplate.t
t/pod-coverage.t.disabled
t/pod.t
TODO

-- 
Brian J. Miller
End Point Corp.
brian at endpoint.com


More information about the Camps-users mailing list