Code Monkey home page Code Monkey logo

galaxy-zoo's Introduction

Galaxy-Zoo

###Running with Docker

####Local development docker-compose run --service-ports galaxyzoo npm run start

runs a local server on http://localhost:9294/

####Build and deploy Deploy to https://galaxyzoo.org/beta for testing docker-compose run --service-ports galaxyzoo npm run deploy-to-staging

Deploy CSS and JavaScript docker-compose run --service-ports galaxyzoo npm run deploy quick

Full deploy (including images and other assets) docker-compose run --service-ports galaxyzoo npm run deploy

Getting Started

git clone https://github.com/zooniverse/Galaxy-Zoo.git
cd Galaxy-Zoo
npm install .

./fits/build.rb
./interactive/build.rb

hem server
open http://localhost:9294/

Installation

echo 'PATH="./node_modules/.bin:${PATH}"' >> ~/.bash_profile
echo 'export PATH' >> ~/.bash_profile
source ~/.bash_profile
git clone https://github.com/zooniverse/Galaxy-Zoo.git
cd Galaxy-Zoo
npm install .
hem server
open http://localhost:9294

Depending on your browser, you may have to confirm a security exception to allow a self-signed SSL certificate for dev.zooniverse.org

Translations

Galaxy Zoo uses our APIs built-in translation management for storing, and serving localized strings. The interface to add translations is available at http://translations.zooniverse.org/, though you need to be a registered dev/translator to save any changes.

What do I do when I add new text to the site

The way our translations system works is we store a canonical en-us version of the language strings both within the repo and remotely in a database. When changes are made to the local copy, we need to update the remote copy, so we can tell what text for languages other than en-us are out of date, missing, or otherwise need attention.

To do what, you need to either POST the current translations to the API manually, or use the https://github.com/parrish/translator-seed/ module that Michael wrote for convenience. A proper command to upload new translations to the site is conveniently provided as an npm script, runnable by npm run seed-locale. For the system to accept your upload, you must have an OUROBOROS_AUTH env. variable set (see parrish/translator-seed#2 for details on what that expects) and your account must be tagged as a developer.

License

Apache 2.

Zooniverse Galaxy Zoo translations not contained within this repo are also licensed under Apache 2.

Troubleshooting

  • If you encounter issues with the Ruby builds, ensure that you are using node version no later than 0.11.14. The n package can help with this. This is because the path.existsSync function was removed in 0.12. Example:
npm install nvm
. ~/nvm/nvm.sh

nvm install v0.10
nvm use v0.10
  • Also ensure that you have SSH access for github set up.
  • Ensure that you are running the hem command from the local path (./node_modules/.bin/hem), rather than any global version when starting hem server.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.