perl/root/help.1
2018-11-06 14:18:14 +00:00

148 lines
4.3 KiB
Groff

.TH Perl 5.26 container image
.PP
This container image includes Perl 5.26 as a S2I
\[la]https://github.com/openshift/source-to-image\[ra] base image for your Perl 5.26 applications.
Users can choose between RHEL and CentOS based builder images.
The RHEL image is available in the Red Hat Container Catalog
\[la]https://access.redhat.com/containers/#/registry.access.redhat.com/rhscl/perl-526-rhel7\[ra]
as registry.access.redhat.com/rhscl/perl\-526\-rhel7.
The CentOS image is then available on Docker Hub
\[la]https://hub.docker.com/r/centos/perl-526-centos7/\[ra]
as centos/perl\-526\-centos7.
The resulting image can be run using Docker
\[la]http://docker.io\[ra]\&.
.SH Description
.PP
Perl 5.26 available as container is a base platform for
building and running various Perl 5.26 applications and frameworks.
Perl is a high\-level programming language with roots in C, sed, awk and shell scripting.
Perl is good at handling processes and files, and is especially good at handling text.
Perl's hallmarks are practicality and efficiency. While it is used to do a lot of
different things, Perl's most common applications are system administration utilities
and web programming.
.PP
This container image includes an npm utility, so users can use it to install JavaScript
modules for their web applications. There is no guarantee for any specific npm or nodejs
version, that is included in the image; those versions can be changed anytime and
the nodejs itself is included just to make the npm work.
.SH Usage
.PP
To build a simple perl\-sample\-app
\[la]https://github.com/sclorg/s2i-perl-container/tree/master/5.26/test/sample-test-app\[ra] application,
using standalone S2I
\[la]https://github.com/openshift/source-to-image\[ra] and then run the
resulting image with Docker
\[la]http://docker.io\[ra] execute:
.IP \(bu 2
.PP
\fBFor RHEL based image\fP
.PP
.RS
.nf
$ s2i build https://github.com/sclorg/s2i\-perl\-container.git \-\-context\-dir=5.26/test/sample\-test\-app/ rhscl/perl\-526\-rhel7 perl\-sample\-app
$ docker run \-p 8080:8080 perl\-sample\-app
.fi
.RE
.IP \(bu 2
.PP
\fBFor CentOS based image\fP
.PP
.RS
.nf
$ s2i build https://github.com/sclorg/s2i\-perl\-container.git \-\-context\-dir=5.26/test/sample\-test\-app/ centos/perl\-526\-centos7 perl\-sample\-app
$ docker run \-p 8080:8080 perl\-sample\-app
.fi
.RE
.PP
\fBAccessing the application:\fP
.PP
.RS
.nf
$ curl 127.0.0.1:8080
.fi
.RE
.SH Environment variables
.PP
To set environment variables, you can place them as a key value pair into a \fB\fC\&.sti/environment\fR
file inside your source code repository.
.IP \(bu 2
.PP
\fBENABLE\_CPAN\_TEST\fP
.PP
Allow the installation of all specified cpan packages and the running of their tests. The default value is \fB\fCfalse\fR\&.
.IP \(bu 2
.PP
\fBCPAN\_MIRROR\fP
.PP
This variable specifies a mirror URL which will used by cpanminus to install dependencies.
By default the URL is not specified.
.IP \(bu 2
.PP
\fBPERL\_APACHE2\_RELOAD\fP
.PP
Set this to "true" to enable automatic reloading of modified Perl modules.
.IP \(bu 2
.PP
\fBHTTPD\_START\_SERVERS\fP
.PP
The StartServers
\[la]https://httpd.apache.org/docs/2.4/mod/mpm_common.html#startservers\[ra]
directive sets the number of child server processes created on startup. Default is 8.
.IP \(bu 2
.PP
\fBHTTPD\_MAX\_REQUEST\_WORKERS\fP
.PP
Number of simultaneous requests that will be handled by Apache. The default
is 256, but it will be automatically lowered if memory is limited.
.IP \(bu 2
.PP
\fBPSGI\_FILE\fP
.PP
Override PSGI application detection.
.PP
If the PSGI\_FILE variable is set to empty value, no PSGI application will
be detected and mod\_perl not be reconfigured.
.PP
If the PSGI\_FILE variable is set and non\-empty, it will define path to
the PSGI application file. No detection will be used.
.PP
If the PSGI\_FILE variable does not exist, autodetection will be used:
If exactly one ./*.psgi file exists, mod\_perl will be configured to
execute that file.
.IP \(bu 2
.PP
\fBPSGI\_URI\_PATH\fP
.PP
This variable overrides location URI path that is handled path the PSGI
application. Default value is "/".
.SH See also
.PP
Dockerfile and other sources are available on
\[la]https://github.com/sclorg/s2i-perl-container\[ra]\&.
In that repository you also can find another versions of Perl environment Dockerfiles.
Dockerfile for CentOS is called Dockerfile, Dockerfile for RHEL is called Dockerfile.rhel7.