3 Catalyst::Manual::Installation::CentOS4 - Catalyst Installation on CentOS 4
9 This document provides directions on how to install CentOS 4 (a rebuild
10 of RedHat Enterprise 4) and then install Catalyst.
12 If you already have a functioning install of CentOS, RHEL, or a
13 comparable Linux OS, you should be able to skip this first section and
14 go straight to the C<INSTALL CATALYST> section.
16 B<NOTE:> You might want to consult the latest version of this document. It
18 L<http://dev.catalyst.perl.org/repos/Catalyst/trunk/Catalyst-Runtime/lib/Catalyst/Manual/Installation/CentOS4.pod>
24 These directions are written for CentOS 4.3 on an i386 machine; however,
25 you can substitute other versions as they become available.
32 Go to L<http://isoredirect.centos.org/centos/4/isos/i386/> and click the
37 Download C<CentOS-4.3-i386-bin1of4.iso> (you only need the first disk).
45 Insert the CD into your machine and power it up.
49 Hit C<Enter> at the C<boot:> prompt.
53 CD media test: you can either select C<OK> or C<Skip> depending on
54 whether or not you trust your burn.
58 The installation GUI should start. Click next at the "Welcome to
63 Select a language and click C<Next>.
67 Select a keyboard configuration and click C<Next>.
71 Select C<Custom> for the installation type and click C<Next>.
75 Leave C<Automatically partition> selected on the C<Disk Partitioning
76 Setup> and click C<Next>.
80 Uncheck C<Review (and modify if needed) the partitions created>, but
81 leave the rest of the default settings on the C<Automatic Partitioning>
82 screen. Then click C<Next>.
86 Click C<Yes> at the C<Are you sure you want to do this?> warning.
90 Click C<Next> on the C<Boot Loader Configuration> screen.
94 Update the C<Network Configuration> screen as necessary and click C<Next>.
98 Check C<Remote Login (SSH)> and click C<Next> on the C<Firewall
99 Configuration> screen.
103 Select additional languages as necessary. Click C<Next>.
107 Select the appropriate time zone and click C<Next>.
111 Enter a root password and click C<Next>.
115 Scroll to the bottom of the C<Package Group Selection> screen and check
116 C<Minimal> (the last option). Click C<Next>.
120 Click C<Next> at the C<About to Install> screen.
124 The installation will prepare the hard drive and then install the
125 required rpm packages.
129 Once the installation completes, remove the CD and click C<Reboot>.
133 Type C<vi /etc/sysconfig/iptables> and add the following line as the
134 third to last line of the file (I<above> the C<-A RH-Firewall-1-INPUT -j
135 REJECT --reject-with icmp-host-prohibited> line):
137 -A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 3000 -j ACCEPT
139 This will allow Catalyst to make use of port 3000 (the default for the
142 Type C<service iptables restart> to restart the iptables firewall using
143 the updated configuration.
147 Type C<yum -y update> to retrieve the latest patches.
152 =head1 INSTALL CATALYST
158 Type C<yum -y install gcc expat-devel sqlite3> to install several
159 packages used by Catalyst.
165 $ perl -MCPAN -e shell
169 Are you ready for manual configuration? [yes] n
173 cpan shell -- CPAN exploration and modules installation (v1.7601)
174 ReadLine support available (try 'install Bundle::CPAN')
176 cpan> force install Module::Build
184 B<Optional:> The remaining steps of the installation could run
185 significantly faster if you configure a fast mirror that uses HTTP vs.
186 FTP (both transfer data at the same rate once the transfer is in
187 progress, but HTTP connects much more quickly... and a Catalyst
188 installation involves many connections). One way to do this is to
189 answer C<yes> to the C<Are you ready for manual configuration?> prompt
190 when you ran C<perl -MCPAN -e shell> above. Or, you can rerun the
191 script by entering the following command at the C<cpanE<gt>> prompt:
195 It will then take you through the configuration dialog.
197 However, it's often easiesr to avoid the full configuration dialog and
198 manually add a URL. To prepend a new URL to the B<front> of the list,
199 use the C<unshift> option to C<o conf>:
201 cpan> o conf urllist unshift http://www.perl.com/CPAN/
203 Where C<http://www.perl.com/CPAN/> is replaced by a nearby, HTTP-based
204 mirror. You can get a list of all mirrors (including where they are
205 located, their bandwidth, and their update frequency) at
206 L<http://www.perl.com/CPAN/MIRRORED.BY>.
208 Then, be sure to save your changes (or they will be lost the next
209 time you restart the CPAN shell):
213 You can view the current settings with C<o conf urllist> (or just
214 C<o conf> to view all settings):
218 http://www.perl.com/CPAN/
219 Type 'o conf' to view configuration edit options
221 Note that multiple values can be entered for the C<urllist> option (the
222 first entry will be used as long as it responds).
226 Type C<wget http://www.shadowcatsystems.co.uk/static/cat-install> to
227 retrieve a copy of the C<cat-install> script.
231 Type C<vi cat-install> to open the installer script, then insert the
232 following lines at the bottom of the file (after the
233 C<install('Catalyst');> line):
235 install('Catalyst::Devel');
236 install('ExtUtils::ParseXS');
237 install('Digest::SHA1');
238 install('Digest::SHA');
239 install('Class::DBI');
240 install('DBIx::Class');
241 install('DBIx::Class::HTMLWidget');
242 install('Module::Install');
243 install('Catalyst::Plugin::ConfigLoader');
244 install('Catalyst::Plugin::Session');
245 install('Catalyst::Plugin::Session::State::Cookie');
246 install('Catalyst::Plugin::Session::Store::FastMmap');
247 install('Catalyst::Plugin::Authorization::ACL');
248 install('Catalyst::Plugin::Authentication');
249 install('Catalyst::Plugin::Authorization::Roles');
250 install('Catalyst::Plugin::Authentication::Store::DBIC');
251 install('Catalyst::Plugin::DefaultEnd');
252 install('Catalyst::Plugin::StackTrace');
253 install('Catalyst::Plugin::Dumper');
254 install('Catalyst::Plugin::HTML::Widget');
255 install('Catalyst::Model::DBIC::Schema');
256 install('Catalyst::View::TT');
257 install('Test::WWW::Mechanize');
258 install('Test::WWW::Mechanize::Catalyst');
259 install('Test::Pod');
260 install('Test::Pod::Coverage');
264 Type C<perl cat-install>. It will take a while to complete.
268 You should now have a functioning Catalyst installation with the modules
269 and plugins required to run the Catalyst tutorial.
272 =head1 TESTING THE INSTALLATION
278 Download the tarball of the final tutorial application:
280 $ wget http://dev.catalyst.perl.org/repos/Catalyst/trunk/examples/Tutorial/Final_Tarball/MyApp.tgz
293 $ CATALYST_DEBUG=0 prove --lib lib t
294 t/02pod...............skipped
295 all skipped: set TEST_POD to enable this test
296 t/03podcoverage.......skipped
297 all skipped: set TEST_POD to enable this test
298 t/01app...............ok
299 t/controller_Login....ok
300 t/live_app01..........ok 1/0[debug] ***Root::auto User not found, forwarding to /login
301 t/live_app01..........ok 2/0[debug] ***Root::auto User not found, forwarding to /login
302 t/live_app01..........ok 15/0[debug] ***Root::auto User not found, forwarding to /login
303 t/live_app01..........ok 16/0[debug] ***Root::auto User not found, forwarding to /login
304 t/live_app01..........ok
305 t/model_MyAppDB.......ok
306 All tests successful, 2 tests skipped.
307 Files=6, Tests=55, 11 wallclock secs ( 4.68 cusr + 4.84 csys = 9.52 CPU)
309 You should see C<All tests successful>.
317 Kennedy Clark, C<hkclark@gmail.com>
319 Please report any errors, issues or suggestions to the author. The
320 most recent version of the Catalyst Tutorial can be found at
321 L<http://dev.catalyst.perl.org/repos/Catalyst/trunk/Catalyst-Runtime/lib/Catalyst/Manual/Tutorial/>.
323 Copyright 2006, Kennedy Clark, under Creative Commons License
324 (L<http://creativecommons.org/licenses/by-nc-sa/2.5/>).