Forum: Ruby on Rails ssl and lightpdd

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
11a7251b792d545cc7e518fdccb34c18?d=identicon&s=25 Raj Kapila (rage989)
on 2006-06-09 06:53
can you run a site with ssl on a computer on a router or do you need a
dedicated ip for this?
D0cd6b10e01bacb976b3b815a9c660bc?d=identicon&s=25 Alex Wayne (Guest)
on 2006-06-09 09:41
raj kapila wrote:
> can you run a site with ssl on a computer on a router or do you need a
> dedicated ip for this?

I believe ssl requires a static IP.  Not 100% sure of that however.
11a7251b792d545cc7e518fdccb34c18?d=identicon&s=25 Raj Kapila (rage989)
on 2006-06-09 20:35
Alex Wayne wrote:
> raj kapila wrote:
>> can you run a site with ssl on a computer on a router or do you need a
>> dedicated ip for this?
>
> I believe ssl requires a static IP.  Not 100% sure of that however.

Well my problem is that when i enable ssl in my lighttpd.conf file and i
go to my site all i get is a blank page regardless if that page requires
ssl.
D0cd6b10e01bacb976b3b815a9c660bc?d=identicon&s=25 Alex Wayne (Guest)
on 2006-06-09 21:28
raj kapila wrote:
> Alex Wayne wrote:
>> raj kapila wrote:
>>> can you run a site with ssl on a computer on a router or do you need a
>>> dedicated ip for this?
>>
>> I believe ssl requires a static IP.  Not 100% sure of that however.
>
> Well my problem is that when i enable ssl in my lighttpd.conf file and i
> go to my site all i get is a blank page regardless if that page requires
> ssl.

Since SSL runs on a different port (443), it requires a totally separate
vhost.

here is my config for ssl, and non ssl vhosts:

# SSL
$SERVER["socket"] == "70.87.55.194:443" {
	server.document-root             = "/home/foobar/public/"

	fastcgi.server = (
        ".fcgi" =>
          ( "localhost" =>
            (
              "socket" =>
"/home/lighttpd/var/run/lighttpd-fcgi-mwprod-ssl.socket",
              "bin-path" => "/home/foobar/public/dispatch.fcgi",
              "bin-environment" => ( "RAILS_ENV" => "production" ),
							"max-load-per-proc" => 25,
							"min-procs" => 1,
							"max-procs" => 4,
							"idle-timeout" => 30
            )
          )
        )

	#### SSL engine
	ssl.engine                  = "enable"
	ssl.pemfile                 = "/home/lighttpd/foobar.com.pem"
}

$HTTP["host"] =~ "foobar" {
	server.document-root = "/home/foobar/public/"
	fastcgi.server = (
        ".fcgi" =>
          ( "localhost" =>
            (
              "socket" =>
"/home/lighttpd/var/run/lighttpd-fcgi-mwprod.socket",
              "bin-path" => "/home/foobar/public/dispatch.fcgi",
              "bin-environment" => ( "RAILS_ENV" => "production" ),
							"max-load-per-proc" => 25,
							"min-procs" => 1,
							"max-procs" => 4,
							"idle-timeout" => 30
            )
          )
        )
}







hope it helps
11a7251b792d545cc7e518fdccb34c18?d=identicon&s=25 Raj Kapila (rage989)
on 2006-06-09 21:48
> Since SSL runs on a different port (443), it requires a totally separate
> vhost.
>
can i do all this behind a router?
11a7251b792d545cc7e518fdccb34c18?d=identicon&s=25 Raj Kapila (rage989)
on 2006-06-09 23:51
got it working, thanks for you help. I am running behind a router too.
most important part to lighttpd.conf is:

# SSL
$SERVER["socket"] == "70.87.55.194:443" {
	server.document-root             = "/home/foobar/public/"

	fastcgi.server = (
        ".fcgi" =>
          ( "localhost" =>
            (
              "socket" =>
"/home/lighttpd/var/run/lighttpd-fcgi-mwprod-ssl.socket",
              "bin-path" => "/home/foobar/public/dispatch.fcgi",
              "bin-environment" => ( "RAILS_ENV" => "production" ),
							"max-load-per-proc" => 25,
							"min-procs" => 1,
							"max-procs" => 4,
							"idle-timeout" => 30
            )
          )
        )

	#### SSL engine
	ssl.engine                  = "enable"
	ssl.pemfile                 = "/home/lighttpd/foobar.com.pem"
}
This topic is locked and can not be replied to.