I have since connected to my SSH site using Putty and Filezilla. Putty and Filezilla give me direct access to the appropriate directories and Filezilla gives me a full path from the top level directory. I have then tried the same path from the starting point in Aptana, but get blocked one level above my target directory. If I collapse all the directories in Putty and Filezilla and try to expand again, Putty works fine, but Filezilla then blocs at the same point as Aptana. So there is some subtle difference in approach between Filezilla and Aptana and Putty.
I was looking for a way to get an encryted link when editing files on my hosted webserver when using Aptana Studio. I can get an ordinary Remote FTP link set up and use that to edit files. The SSH facility looked as though it could do a secure link, so got the SSH details off my ISP and set up in Studio. In the setup I was asked to select a directory, but the ones available were all system directories rather than my htdocs tree. However by leaving out the default provided /, I could get to the htdocs tree and see all my files under remote. However when I try to load a file to Studio, I get a file does not exist message.
I'm new to SSH (and Studio) and don't know whether what I am trying to do is not possible or there is something else I need to set up. So far I have just been using Studio as a remote editor for PHP and HTML. I suspect there is a much better and professional way to set up what I am doing under Studio (even ignoring the secure transfer) as I am currently doing separate backup of the files in Filezilla, but just haven't figured out the way to set everything up yet.
Many thanks for any help.
Actually I'd like to post this as a comment to your question, but I'm pretty new here, so the system doesn't allow me to.
Anyway. You can add connections to remote servers over ssh like this:
If you don't have the remote tab go to Window -> Show View -> Remote
Rightclick in the remote tab and click "Add New FTP Site..."
Change the Protocol to SFTP and put in your credentials (you can use Username/Password or Username/Private Key authentification)
When you close Aptana with files still opened, it usually show you those files when you reopen Aptana later. It seams not to do this when you work with files of a SFTP remote host and shows you an error instead. I guess this is because it tries to validate those files (if they still exists) but doesn't authenticate with the remote host first. So nothing to worry there.
Hope this helps.
Related
I want to edit files on my server, but don't want to always upload the files, is there a way on to edit the files remotly?
I tryed to make an bash script which should upload the files, but its not realy good :/ and sometimes didn't worked
You can use Atom with the
Retome FTP edit
Package
If you have got an SSH (SFTP enabled) access to your server, an option would be use use SSHFS to mount a remote directory on your local working path.
In this way you can use any editor (or even something else) to change your files and they will always be synchronised.
Just keep in mind that, in this way, files are actually located on your server, you won't have a real copy on your local machine.
The problem is incorrect path to remote host, but is not true. I have acces to my server via ftp without problems. All WP files are there and the site is working fine (frontend/backent). I have also access to phpMyAdmin to MySQL datepase binded to this site.
I have notce that paht to the web files is differ depend on FTP or SFTP is. In FTP app is such stright:
/[all wp files]
in editor app (such TextWrangler), after the samy access id/pass, I have got such path:
/home/[accountname]/public_html/[all wp files]
After click on detect button, app changing the path filed on:
- blanc - under FTP connection
or
- public_html - under SFTP
so it mean conection between MAMP and my server is working. Fine. But after this when I trying to Check URLs & credentials or when I trying Import Host... I received:
Error code: -3010 (The 'Path' to your remote document root is incorrect. The 'Path' field on the remote tab is the document root of your remote site that will be accessed via your Public Site URL (e.g.: 'public_html').) - Start auto detect not solved the problem.
or
Error code: -3113 (The 'Path' to your remote document root is incorrect. The 'Path' field on the remote tab is the document root of your remote site that will be accessed via your Public Site URL (e.g.: 'public_html').)
But it is not true! All files are there!
Please help. Should I use some special code under Apache tab (Additional parameters for VirtualHost directive or Directory directive?
Should I know something more from my serverprovider (home.pl) and solved this problem with them (there is no, in my subscription plan, access via cPanel or so, to set up something)?
Should I change something in https.conf file?
I'm not so using server coding so please forgive me but I have no idea where is the problem (but I'm trying to learn) :o)
My environment is:
MacOS X: 10.13.6
MAMP Pro: 5.2.2 (17923)
Thanx for any help or redirection to the answers someware else (I used searching ;o) but without success or I used wrong ask).
Just ran into this and found a solution that worked for me. I just had to switch the Public URL from https to http and it worked.
I had this error too.
Here's what I did to fix it:
Logged into my remote CPanel account
Created an FTP account for user#sitename.com
Defined the user directory in the FTP user settings similar to this /home/[site]/public_html
Ensured that this user had read/write permissions on the remote server (otherwise importing a site in MAMP Pro might fail)
Then, in MAMP Pro (v 6.0.1) created a new host following these steps:
https://documentation.mamp.info/en/MAMP-PRO-Mac/Create-a-new-host/Import/
I found that once the correct FTP permissions were set at the server, MAMP was OK and functioned as planned.
Good luck, hope this works for you too.
I am using a host to try and deploy my Django site but I am confused by the SSH vs. FTP.
Background info:
I got the IP address, name and password from my host for the VPS.
I logged in using the same information via Putty and via WinSCP.
Both show me as having accessed root#[VPS IP Address].
Running ls on Putty shows nothing (no files or folders). So I created a file hello.txt.
WinSCP shows a lot of folders at the root, unlike Putty. I then searched all the folders for the hello.txt that I created and it's nowhere to be found.
Why would accessing the same VPS via two different methods show completely different things?
If you are indeed sure that you are logged into the same host, with the same user account you should check that you are in the same folder.
Using ssh you can issue the command pwd (print working directory) to view the current the directory you are in.
To change to another directory using the shell, use the cd command, for example:
cd .. # This moves up to the parent directory
cd /var/www/html
The Winscp user interface should also show you in what directory you are currently in.
Navigation to another directory using Winscp should be fairly straightforward.
There's no reason to think these methods will put you in the same directory location at all.
When you SSH in using Putty, you will almost certainly be put in your home directory, and that will be where your hello.txt was created.
But the FTP service has presumably been configured to put you in the common area where your service's files are located, which is not under your home directory. Where it is will be specific to the configuration of that machine.
Using SSH you will probably be able to use cd to change directory to the FTP location, if you can find out what it is; however, the reverse is not true and you almost certainly won't be able to navigate to the home directory via FTP.
(Note, this is not a question about Django, and should probably have been asked on ServerFault.)
I have set up a reactJS environment on digitalocean just to start learning developing with react and graphQL and i was wondering if there is a text editor that can connect to connect on the internet and retrieve the files of the project.
Im not really sure if something like this is doable but in my head is like i will code the files on the VPS with a proper text editor and save them so i can have some sort of live preview.
I have already tried with sublime and brackets but im not really sure how to connect them on the project folder in my vps.
If your VPS has SFTP set up, you can use your SSH login details to connect and edit code live through an editor such as sublime text.
( I would recommend using FTP if the SSH access is through root or anything with authority on the server, if you do not care about security then feel free to use root )
https://www.sublimetext.com/
An SFTP / FTP plugin exists for what you require, please see below:
https://wbond.net/sublime_packages/sftp
Example usage of the plugin is as follows
Create a project folder
CTRL+SHIFT+P > "sftp" > SFTP -> Setup Server
Edit the login details within your sftp-config.json file
Make sure the remote path is correct and your credentials are correct
"upload on save" - change to true inside your sftp-config.json file
Save the sftp-config.json file, CTRL+SHIFT+P > "sftp" > SFTP Sync remote -> local
I'd recommend adding node_modules inside your ignore_regexes, as it can take up to 10-15 minutes to download these.
Now it should ( if set up correctly ) download the files specified in your "remote_path" folder. Saving future files will upload them to the server on save.
I hope this helps!
I'm looking right at the file I want to download in my current directory. wget wants a FULL url, I don't know what the full url is. im in directory /usr/local/lib/ and want to download php.ini.
I am using putty to log into my web server, and when i say donwload i want to download it from the web server to my pc
Firstly, forget URLs, and forget wget - this file isn't going to be accessible over the world wide web (if it is, your security is seriously broken).
However, if you can see it on SSH, you can probably (depending on security policies on the server) access it by using the same credentials over SCP.
On the command-line, using the PSCP program which comes with PuTTY that would look something like:
pscp user#server.example.com:/usr/local/lib/php.ini .
Or you could use a graphical client like WinSCP or FileZilla (which supports SFTP, which is another SSH-based protocol; use sftp://server.example.com as the server to connect to), if you're on a Windows desktop.
Use pscp which is included with PuTTY
If you are on Linux:
scp user#server:/path2file/file path-on-localpc