WS GCP Part5: Installing ws cli and importing datasets - Gapminder/waffle-server GitHub Wiki

WARNING! This article may change without notice since both GCP and Waffle Server are in active development

This instruction will help you to install a client to manage datasets in Waffle server and import one. If you don't yet have Waffle server up and running, make sure you've followed the previous parts



1. Install a WS client CLI

npm install -g waffle-server-import-cli

If get permissions denied, modify permissions of the critical folders and try installing again

sudo chmod -R 777 /usr/lib/node_modules 
sudo chmod 775 /usr/bin

Start ws-cli:

ws-cli



2. Log in to your WS instance from the client

  • Pick an option "Add new endpoint" — it has to be in a form like http://35.197.234.86, with http possibly https in the front and no slash in the end. TM EXTERNAL IP of the WS installation is used, or alternatively, a DNS name, pointing to that IP via Cloudflare or such

  • Pick option "Select from the List", chose the one you've entered in the above step, enter login [email protected] (hardcoded by now) and password (you have specified this password in WS configs before deploy. See here)



3. Register and import a repository

  • Once you're in, pick option "Register repository" and enter it from Github page, where you have "Cloning over SSH". Example: [email protected]:open-numbers/ddf--gapminder--systema_globalis.git, for this repo. Registering repositories results just in a local list, kept for convenience. This way you can import the exact same repo to many WS endpoints without the need to get its name from Github every time.

note: you can chose to import a specific branch of your dataset on Github by adding #branch-name in the end. Example: [email protected]:open-numbers/ddf--gapminder--systema_globalis.git#develop. By default it's master but you can also specify #master explicitly

  • Pick an option "Import DataSet". Select the repository you registered above

  • Choose “public”. On working with private repositories read here

  • Choose the latest commit (press arrow up twice)

  • Watch the validation and import process

note: if error appears check that you’ve added this computer’s SSH as well as waffle server’s SSH keys to a Github account, which has access to the desired dataset

  • Once the dataset is imported, move on to performing queries to see how it works
⚠️ **GitHub.com Fallback** ⚠️