Skip to content

Setup for macOS

Gary Boodhoo edited this page Apr 22, 2018 · 25 revisions

To connect with the server we will download, install and configure:

  • A server access key, which serves as a kind of password for logging in to the server.
  • FileZilla, an open source file transfer application. This provides a drag and drop interface for transferring files between the server and your laptop.
  • Terminal, a built-in Apple utility which provides a command line interface for UNIX operating systems

Having done so, we will prepare a workspace and will be ready to make art.

Download the Software
Install FileZilla
Setup the Terminal
Prepare your workspace

#Download the software
Save the server access key to the Desktop:

Save the FileZilla installer to the Desktop:

#Install FileZilla

  1. Find the FileZilla installer on the Desktop and double-click

  2. The application appears on the Desktop. Double-click to launch it

  3. Click Open when MacOS asks if you are sure you want to open this application
    .

  4. FileZilla launches when installation completes

Configure FileZilla

  1. From the program menu select FileZilla > Settings

  2. In the Settings window select Connections > SFTP

  3. Click the Add key file button

    • A file dialog opens. Navigate to the Desktop and Open the server access key (synthetic_rsa.pem)
  4. Click the OK button to exit the Settings window

  5. From the program menu select File > Site Manager

  6. The Site Manager window opens. Click the New Site button

  7. Complete the following fields:

    • Host: ec2-35-167-188-17.us-west-2.compute.amazonaws.com (copy this and paste into the field)
    • Protocol: SFTP
    • Logon Type: Normal
    • User: ubuntu
    • Password: clear the default value so that this field is empty

Connect to the server with FileZilla

  1. Click the Connect button at the bottom of the Site Manager window
  2. Click OK in the security alert FileZilla raises when you first connect

You have connected to the server with FileZilla

FileZilla shows the files on the server in the panel on the right

#Setup the Terminal

  1. Find the Terminal utility by clicking the Search icon in the menu bar at the top right of your screen

  2. The search box appears

  3. Type the word Terminal and a list of search results is returned

  4. Double-click Terminal.app to launch it and the Terminal window opens

Connect to the server with the Terminal

  1. Copy this command: cd ./Desktop

    1. Click anywhere in the Terminal window
    2. Right-click > Paste
    3. Press Enter
  2. Copy this command chmod 400 synthetic_rsa.pem

    1. Click anywhere in the Terminal window
    2. Right-click > Paste then press Enter
  3. Copy this command ssh -i "synthetic_rsa.pem" ubuntu@ec2-34-212-24-226.us-west-2.compute.amazonaws.com

    1. Click anywhere in the Terminal window
    2. Right-click > Paste then press Enter
    3. Type yes in response to the security warning that appears, then press Enter

You have connected to the server with the Terminal

#Prepare your workspace
You'll be sharing the server with other workshop participants, To keep everyone's work seperate you've been assigned a username.

Find your user folder in FileZilla

The contents of the server are listed in the panel on the right. The top section of that panel shows the directories on the server, the lower section shows the contents of the selected directory. By default, you start in the root folder. We can navigate from here to your user folder

  1. in the lower panel, double-click the users directory
  2. double-click the folder with your username

Inside your user folder you will see 2 folders. The pictures folder contains the images that neural-style works with. The server renders its output to the temp folder. Note that pictures inside the temp folder tend to be overwritten, so it's always a good idea to save pictures you want to keep to your laptop.

Copy the pictures folder to your laptop

It's easier to review and manage pictures on your laptop than on the server. We'll work with pictures locally and upload any changes or new material to the server.

Find your user folder in the Terminal

In FileZilla you may have noticed a few files in your user folder in addition to the pictures and temp folders. These are rendering scripts. To start painting a picture you must type the name of these files into a Terminal window, but first you will need to point the terminal to your user folder

  1. Click anywhere inside the Terminal window to make it active
  2. Type this command: cd users
  3. Type this command, and replace USERNAME with the username you were given 'cd USERNAME` for example, if your username is tiger, you should type: 'cd tiger'
  4. Now the the following command, this will list the contents of your user folder: 'll'