Usually, when you log into any server, you will be placed at a point in the filesystem above which you cannot navigate. This may be the server’s real root point (/) or it may be your login user’s root (/users/yourname/ or ~/).
There will always be a point lower than that level where your site’s files live. I say always here because you will usually need to store things that are not publicly available – log files, your mail, etc. – and the web server can serve anything that lives in its own “root” or below that level. Each account in a shared server has its own site root folder, and the Web server can only share those files with the world when it is addressed by your account’s domain name.
If you are logging in for the first time to a new server, it’s always best to use a dedicated SFTP application, like Transmit or Fetch, because then you can visually survey the structure and see what you need to do.
In this initial login, you will see a folder containing all the files your user can see, and within that, you should see another folder containing index.html and all its pals. This folder will be named something (determined by the server’s administrator) that relates to the Web server, but its name is not specifically important. I have seen htdocs
, public_html
, public
, www
, etc. The key thing here is to find the folder where there is already an index.html and any associated resources. (Ubuntu Linux server usually have a file containing the words “It Works!”.) Freeway allows you to take the information you find with your SFTP application and automate the upload and future updates of the server, but only after you have determined the exact path from the “server root” as known to your user.
Not to further complicate this, but what I described above as the difference between the actual root of the server’s filesystem and your user’s opinion of its own root is something you may want to understand. There is a user in any Unix-like server that is named root. This user “owns” the server, and has absolute authority – they can see anything , edit anything, and delete anything. Naturally, you want to use this user as sparingly as possible. In most contexts, you will never have this authority at all. Your own user will have a very carefully limited authority, only able to see and more importantly edit certain files within the server. That user will be what’s called chroot jailed
into a particular corner of the filesystem, and will be able to see below their initial home folder into any subfolder contained within it. This is how a typical shared server works – thousands of users each have their own tiny slice of the larger whole, and cannot see or trample their neighbors’ slices. Some servers I have used take this step a little bit further, and when you set up a Web site, you also define a user who is allowed to upload into that site – that’s the only job it’s used for. In that case, the “jail” folder for that user is the web root. They log in, and upload directly to /, even though / is really /users/homes/somename/web_files/ or something similar. But most of the time, you will log in as the one user you were given by the server’s administrator, and your Web server’s files will be contained entirely within a subfolder within that user’s home folder.
So unfortunately, the real answer to any question like this is “it depends”. Because it really does. Only by investigating with a visual browser tool can you be certain how your server is configured.
Walter
freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options