Rebol Talk Forum  |  Getting Started  |  Newbie Help  |  Topic: Tiny web server
Pages: [1] Print
Author Topic: Tiny web server  (Read 191 times)
leke
Jr. Member
**
Offline Offline

Posts: 86


View Profile WWW
Tiny web server
« on: March 29, 2008, 06:21:54 PM »

I'm running Linux and have just grabbed the 2.7.6.4.2 core build. I wanted to see if I could do this on my home computer.
http://www.rebol.net/cookbook/recipes/0057.html
The script runs (if the process stick spinning is a good thing), but i couldn't get a test page running.
I created an index.htm and pointed my browser to http://my-ip-address/index.htm (correct path defined in the script).
Is this the correct setup or do I need to do something more?

Thanks.
Logged

btiffin
Jr. Member
**
Offline Offline

Posts: 51


View Profile
Re: Tiny web server
« Reply #1 on: March 30, 2008, 02:13:00 AM »

Try browsing  http://localhost  see if that has any effect.

webserver.r (the cookbook example is in rebol.org as webserver.r) works for 1.3.2 and 2.7.6 here, but it's Windows.

You may be getting blocked by your firewall - one of a few hundreds of things this could be...  Smiley

Cheers,
Brian
Logged
leke
Jr. Member
**
Offline Offline

Posts: 86


View Profile WWW
Re: Tiny web server
« Reply #2 on: March 30, 2008, 02:52:32 AM »

Thanks, I've already tried the localhost, 127.0.0.1 and firewall thing. If all I need is rebol, the web-server.r script and a web directory, I'll figure the rest out.
Oh, but one thing:
Code:
>> system/network/host-address
== 127.0.1.1
>>
Shouldn't that be my IP-Address?
Code:
>> system/network/host 
== "leke-desktop"
>>
Seems ok.
Logged

fhein
Newbie
*
Offline Offline

Posts: 47


View Profile
Re: Tiny web server
« Reply #3 on: March 30, 2008, 03:48:45 AM »

When you try to access localhost, do you get any text in the Rebol window?
Logged
leke
Jr. Member
**
Offline Offline

Posts: 86


View Profile WWW
Re: Tiny web server
« Reply #4 on: March 30, 2008, 04:28:30 AM »

Code:
>> read http://localhost/
connecting to: localhost
** Access Error: Cannot connect to localhost
** Where: open-proto
** Near: read http://localhost/
>> read http://127.0.0.1
connecting to: 127.0.0.1
** Access Error: Cannot connect to 127.0.0.1
** Where: open-proto
** Near: read http://127.0.0.1
>> read http://127.0.1.1
connecting to: 127.0.1.1
** Access Error: Cannot connect to 127.0.1.1
** Where: open-proto
** Near: read http://127.0.1.1
>> read http://google.com
connecting to: google.com
connecting to: www.google.com
connecting to: www.google.fi
== {<html><head><meta http-equiv="content-type" content="text/html; charset=ISO-8859-1"><title>Google</title><style>body,td,a,p,.h{...
>>
Edit: Oh, sorry i see what you mean now. No the busy indicator is constantly spinning.
>> do %/home/leke/dev/rebol/web-server.r
Script: "Tiny Web Server" (none)
/ (spins)
I think this means its running and it stay in this state when i'm trying to do the tests in a browser.
« Last Edit: March 30, 2008, 04:40:10 AM by leke » Logged

leke
Jr. Member
**
Offline Offline

Posts: 86


View Profile WWW
Re: Tiny web server
« Reply #5 on: March 30, 2008, 03:21:28 PM »

OK got it sorted! Cheesy
I had to add my port :8000 to the end of http://my-ip-address (or localhost)
so http://my-ip-address:8000
« Last Edit: March 30, 2008, 03:23:10 PM by leke » Logged

Pages: [1] Print 
Rebol Talk Forum  |  Getting Started  |  Newbie Help  |  Topic: Tiny web server
Jump to:  

  
Quick Search...

Advanced search
  
Welcome, Guest. Please login or register.
Did you miss your activation email?
May 17, 2008, 04:57:06 PM
Username: Password: Session Length:
  

News: 01-09-08

Alpha version of REBOL 3 has been released!


  
2169 Posts in 562 Topics by 1224 Members
Latest Member: thyptoste

  Rebol Talk Forum | Powered by SMF 1.0.9.
© 2001-2005, Lewis Media. All Rights Reserved.

RT design by Defiant Pc