heroku - files.meetup.comfiles.meetup.com/501101/heroku.pdf · jtmac:perloku jt (master)$ git push...
Transcript of heroku - files.meetup.comfiles.meetup.com/501101/heroku.pdf · jtmac:perloku jt (master)$ git push...
HerokuPlatform as a Service Shootout
Create an Account
Install the Heroku Toolbelt
Attach Your Public Key
Create Your Appmkdir MyCoolApp cd MyCoolApp git init vi app.psgi # content on subsequent slide vi cpanfile # content on subsequent slide git add . git commit -m “Initial Commit”
app.psgi#!/usr/bin/env perl use Dancer2; !
get '/' => sub { "Hello World" }; !
dance;
cpanfilerequires 'Plack', '1.0000'; requires 'Dancer2', '0.15'; requires 'Starman', '0';
Deploy Your Appheroku create --stack cedar --buildpack https://github.com/miyagawa/heroku-buildpack-perl.git!
git push heroku masterDo this only one time, when you first
create your app.
Do not change this URL.
Do this every time you want to deploy a new version of your app.
Watch app deployCreating arcane-harbor-8799... done, stack is cedar BUILDPACK_URL=https://github.com/miyagawa/heroku-buildpack-perl.git http://arcane-harbor-8799.herokuapp.com/ | [email protected]:arcane-harbor-8799.git Git remote heroku added jtmac:perloku jt (master)$ git push heroku master Initializing repository, done. Counting objects: 4, done. Delta compression using up to 8 threads. Compressing objects: 100% (4/4), done. Writing objects: 100% (4/4), 384 bytes, done. Total 4 (delta 0), reused 0 (delta 0) !-----> Fetching custom git buildpack... done -----> Perl/PSGI app detected !... Installing CPAN modules here ... ! 110 distributions installed -----> Installing Starman Starman is up to date. (0.4010) -----> Discovering process types Procfile declares types -> (none) Default types for Perl/PSGI -> web !-----> Compressing... done, 4.9MB -----> Launching... done, v5 http://arcane-harbor-8799.herokuapp.com/ deployed to Heroku !To [email protected]:arcane-harbor-8799.git * [new branch] master -> master
This is the important bit.
What’s next?
• Increase the size of your dyno.
• Add a Postgres database.
• Integrate with about 100 add-on services.