# Need to run a small, local web server



## majamin (Jan 8, 2021)

Hi everyone:

I would like to display a web page that is running on a local web server on a corporate TV. I'm new to FreeBSD, and frankly, to the LAMP-stack process. I don't need anything other than to be able to access the page on the local webserver, say 10.0.0.1/main.html, so I don't need a complicated stack. However, I don't know how to go about this in the FreeBSD "way". What's the fastest, minimal way of starting a local web server that can display a page on a local network? Thanks,

majamin


----------



## mark_j (Jan 8, 2021)

It's no different to probably hundreds of tutorials, blogs and manuals on the web. FreeBSD has the same access to open source applications as any other OS like systemd/Linux, Microsoft Windows, MacOS etc.
The difference is in the installation and perhaps some of the implementation.
So, start with looking at freshports and searching for the web server you want to use, the database, the language(s) and so on.
Then use `pkg` to install them and follow the specific instructions at the end of each install.


----------



## ondra_knezour (Jan 8, 2021)

Install FreeBSD, then
`pkg install nginx` and confirm installation of pkg, then nginx and dependencies
`sysrc nginx_enable=yes
service nginx start`
put your main.html to the /usr/local/www/nginx/ directory, point your browser to http://server-ip/main.html, you are done.


----------



## majamin (Jan 8, 2021)

ondra_knezour said:


> Install FreeBSD, then
> `pkg install nginx` and confirm installation of pkg, then nginx and dependencies
> `sysrc nginx_enable=yes
> service nginx start`
> put your main.html to the /usr/local/www/nginx/ directory, point your browser to http://server-ip/main.html, you are done.


These are the simple instructions I was looking for. Thank you.


----------

