Configuring GET Parameters immediately after the hostname - web

This is a tough one to explain, but I have a requirement where a file on my web server needs to be accessed as such
http://www.something.com?param=value
I am just using Apache2 hosted on a Linux box and need to access a file on my server from another machine on the same LAN. So technically it'd be something like
http://ipaddr?param=value
I can't figure how to get this working or how to search for this online. I tried naming my script as "index.php" in the hopes that this might work but even then it needs something like http://ipaddr/index.php?param=value.
What do you call whatever is happening here and is there a way to do it?

Related

can i access a web server via virtual block in enginx?

so Im not sure how to describe it. I want to access my octoprint server via my personal website as a subdomain or direcotry. I am running nginx on an ubuntu 14.5.2 server on a VPS. The octoprint servers connects directly to the VPS via VPN.
Im sorry the title isn't that clear I'm not sure how to describe my goal.
All I need is a point in the right direction. If you want to write a full tutorial be my guest. But any documentation will do. I can figure it out when I know exactly what I need to look for.
AWW! how could i be so stupid! i just need to use a reverse proxy!
I am kicking my self right now.

How to use Alfresco with custom domain?

I've installed Alfresco CE in a Windows 7 machine (which is not ideal, but I have to deal with it). I can access my Alfresco share from inside the network:
192.168.2.252:8080/share
As far as I know, I can access it from outside the network using a dns service like no-ip.org, which gives me something like:
example.no-ip.org:8080/share
What I'm trying to do is to get something like:
mycustomdomain.com/share/ (removing the /share/ would be great too)
I've been reading a lot, but I'm not sure what to do. I read something about setting up DNS on my machine, but I don't know how to point the domain to the Alfresco share. Any suggestions?
Ip which you have shared is internal IP.You need to have one external IP.Which can be accessed outside network.
Below file will help you in URL redirection.If you want to remove share , you may also do that by configuration in below file.
tomcat\webapps\share\WEB-INF\urlrewrite.xml

Configuring Apache Tomcat to run PHP

I would like to start out by apologizing. I have very little knowledge in the areas of Linux and Servers. I have been asked at work to set up a Linux box running Apache Tomcat. The Server needs to be enabled to allow websockets. I managed to get Debian installed. During the installation it gave me the option to make it a web server, which I did. There are now some different folders and files that are named "apache" in the files system, so my guess is that I am in fact running Apache, but to be honest I'm not 100% sure, and if it is, I don't know if its Tomcat. I fumbled around a bit and figured out the IP address of the computer I installed on and tried going to that IP from another computer in the network and it worked. I was able to see the html file that I put in the /var/www folder on the host machine. I then went out and found a nice piece of code, someone was kind enough to share, that is suppose to test websockets capability but I cant seem to get it working. My thinking is that my server isn't allowing PHP to run. I came to this conclusion by testing. I took a web page from my other server, its written in PHP, that when opened will send a text to my phone. Its just a small piece of code that I used for testing. When I tried running it from the Linux server it wont run, meaning it wont send the text to my phone. So here I am. I realize I'm asking for a simple solution to a complex problem, but I'm under the gun so to speak. I have about a week to get this going, so I just don't have the time to really immerse my self in this stuff the way I would like to. My question in its simplest form is"How do I configure my server to run PHP?" Any help/advice would be greatly appreciated! Thank you all for your time and patience.
Have you tried running a simple PHP script like echo 'Hello World';??
If not then try, if it works then your PHP is up, but sockets are just not configured to use.
If it doesn't work then install Ubuntu, a simple newbie friendly interface for Linux, and then install LAMP, here its how to do it.
And don't panic.

Helping Clients See Their New Site on A Different IP Address (Before DNS Changes)

Our client currently has a website on their own domain: we are in the process of setting up their new site on a new server, with the same domain name.
Originally we started work on a subdomain that they could access when need be. As time came closer we pushed the work to the actual domain (on the new server) and continued to make changes (by adding a line to our hosts file to ensure we were looking at the new server).
The client wants to see the site as it stands today, before switching the DNS to point to the new server. While we could copy everything back to the original subdomain that is not as easy as we first hoped, as unfortunately there's a few too many links and references to files using the domain name (as opposed to just using relative paths).
One other thing: the code auto-redirects back to the 'proper' domain if it's not currently being used (it's a Magento install) and this stops the possibility of pointing the subdomain document root to the current directory (as the first thing that will happen is that it will see that we're using the subdomain, and will push the client to the original domain).
What are our options? I know that we could get them to change their hosts file, but I'm hoping for something a little less 'techy' for the client.
Is there any proxy server out there that we can use, specifically using our own DNS settings, maybe, or is there some Windows client side application that they could install to make it a bit simpler?
It would be pretty darn simple to write a program — in pretty much any language — which would change the hosts file for your clients. All they'd need to do is run the program.
Alternately (this is more work, and not necessarily any more benefit) you could set up a DNS server on the subnet, and configure the web server to use that DNS server. I really don't see this being any easier than just (somehow) modifying the hosts file, though.
I wrote my own proxy server for exactly this purpose: http://chiselapp.com/user/evilotto/repository/web-tools/wiki?name=hr-proxy
The standalone executable is not there, but it can be bundled into a starpack fairly easily. It it only a proxy tho, and does not do things like change the user's system proxy settings (meaning the user would need to change that themself through Internet Options, etc)

FTP configuration for WordPress

I've installed a WordPress instance on a Linux server, and I need to give it FTP access in order to install plugins and execute automatic backup/restores. I've just installed vsftpd, and started the service, but now what?
How do I figure out/set what the username/pass is?
Should I allow anonymous access?
Is the hostname just 'localhost'?
Any advice would be appreciated. I've never messed with FTP on linux before. Thanks-
Your question is a little unclear because you don't specify what aspect of wordpress "wants" FTP access. If you got WP installed, you clearly have at least some access to the machine already. That said, I'll try to answer around that inclarity.
Your questions in order, then some general thoughts:
How do I figure out/set what the username/pass is?
Remember that the man page for a program is a good first stop. A good man page will also contain a FILES or "SEE ALSO" section near the bottom that will point you to relevant config files.
In this case, "man vsftpd" mentions /etc/vsftpd.conf, so you can then do "man vsftpd.conf" to get info on how to configure it.
VSFTPD is configurable, and can allow users to log in in several ways. In the man page, check out "guest_enable" and "guest_username", "local_enable" and "user_sub_token".
*The easiest route for your single user usage is probably configuring local_enable, then your username and password would be whatever it is in /etc/password.*
Should I allow anonymous access?
No. Since you're using this to admin your Wordpress, there's no reason anyone else should be using this FTP. VSFTPD has this off by default.
Is the hostname just 'localhost'?
Depends where you're coming from. 'localhost' maps back to the loopback, or the same physical machine you're on. So if you need to put ftp configuration information for Server A into a wordpress configuration file on Server A, then 'localhost' is perfectly acceptable. If you're trying to configure the pasv_addr_resolve/pasv_addr flag of VSFTPD, then no, you'll want to either pass in the fully qualified name of Server A (serverA.mydomain.com), or leave it off an rely on the IP address.
EDIT: I actually forgot the critical disclaimer to never send credentials over plain FTP. Plain old FTP (meaning not SFTP) sends your username and password in cleartext. I didn't install VSFTP and play with it, but you'll want to make sure that there is some form of encryption happening when you connect. Try hitting it with WinSCP (from windows) or sftp (from linux) to make sure you're getting an ecrypted SFTP, rather than plaintext FTP.
Apologies if you already knew that ;)
You would probably get better answers on server fault.
That said:
vsftp should use your local users by default, and drop you in that user's home directory on login.
disable anonymous access if you don't need it, I don't think wordpress will care but your server will be safer.
yes, or 127.0.0.1, or your public IP if you think you might split the front and back end some day.
WordPress does not natively support SFTP. You can get around this two ways:
chmod permissions in the appropriate directories to allow the normal, automatic update to work correctly. This is the approach most certain to work, as long as it doesn't trip over any local security policies.
Try hacking it in yourself. There have been any number of threads on this at the WordPress.org forums. Here is a recent one which is also talking about non-standard ports. Here is an article about how to try to get it working on Debian Lenny (which also addresses the non-standard port issue).

Resources