Working remotely on Littledamien

From Littledamien Wiki
Revision as of 19:41, 5 November 2012 by Video8 (talk | contribs)
Jump to navigation Jump to search

Overview

Describes the set up for working on "littledamien" projects remotely.

The latest workflow is to open a FTP version of the site in Netbeans and upload/download files from the littledamienii server as needed.

SSH

Bitvise WinSSHD is installed on the Littledamienii server. Start-up is set to "manual".

  • Remote desktop to littledamienii locally, and start the WinSSHD server through the WinSSHD Control Panel program.
  • I originally installed WinSSHD to support a local Git server. I ended up not using the Git server mainly because it ended up being so much extra work having multiple repos when really the server itself is a staging environment and I can't deploy from a Git server using Git to any of the freelance sites that I maintain.
  • Currently WinSSHD is set up to allow access to the entire directory structure, which of course is not very secure. This is why normally it's not even running, and the port is closed.
  • Open up the SSH port on the router.
    • After logging in go to "Virtual Server."
    • Use the router's admin interface to open the port. The default port for SSH is 22. WinSSHD is not set up to use the default port. The port number can be retrieved in the WinSSHD Control Panel.

SFTP

  • Can't connect directly to WinSSHD using an FTP client, even when the FTP client is set to use the SFTP protocol.
  • (Install and) run Bitvise SSH Client to create an "FTP-to-SFTP bridge".
  • Enter host, port, login, and password in the "Login" tab.
  • SFTP tab
    • Initial directory: 'd:\inetpub\develop'
    • Treat as home: checked
  • Services tab
    • FTP-to-SFTP Bridge: checked
    • Listen interface: 'localhost' or '127.0.0.1
    • Listen port: 21
  • Click the "login" button to start up the bridge. Keep the bridge open using other FTP clients.
  • A navigator window when the bridge is established. This can be used to transfer files, of course.
  • As described at Connecting to an SFTP Server with a FTP Client

Git

  • Make sure that the appropriate branch is active in Git before editing anything in Netbeans!

Netbeans

  • Create a project in the local file system.
  • Project > [right click] > Properties > Run Configuration
    • Remote Connection: connection to FTP-to-STFP bridge
    • Upload Directory: path to the project on littledamienii, relative to d:\inetpub\develop.
    • Upload Files: On Save
  • Remote connection
    • Make sure a remote connection exists for the purposes of connecting to the FTP-to-SFTP bridge.
    • Click the "Manage" button to the right of the Remote Connection setting to create/edit these connections.
    • Protocol: FTP (not SFTP. The bridge takes care of that.)
    • Hostname: localhost
    • Port: 12
    • Username & password
    • Intial Directory: /d/inetpub/develop
  • Once the remote connection has been set up for the project it's possible to download existing files from littledamienii by right clicking anywhere under the "Source Files" directory.