GithubHelp home page GithubHelp logo

example-go-app's Introduction

example-go-app

A sample Go application, packaged with https://packager.io.

Installation

Have a look at the installation instructions on the packages page: https://packager.io/gh/pkgr/example-go-app.

For instance, for Ubuntu 12.04 64bit, you would run:

wget -qO - https://deb.packager.io/key | sudo apt-key add -
echo "deb https://deb.packager.io/gh/pkgr/example-go-app precise master" | sudo tee /etc/apt/sources.list.d/example-go-app.list
sudo apt-get update
sudo apt-get install example-go-app

Usage

You can run the app in the foreground:

$ sudo example-go-app run web
2014/09/11 10:29:04 Listening on port 6000...

Or you can generate the upstart or sysvinit scripts so that the app is daemonized and is launched after reboot:

$ sudo example-go-app scale web=1
$ sudo service example-go-app [start/stop/restart/status]

Logs will be available in var/logs/example-go-app, and you can see them with:

$ sudo example-go-app logs [--tail]

Once the app is running, check it is working by sending an HTTP request:

$ curl http://127.0.0.1:6000/cities.json
"{'cities':'San Francisco, Amsterdam, Berlin, New York'}"

I want to do the same with my app!

Have a look at the .pkgr.yml file, add a Procfile and a .godir directory, and you should be good to go!

example-go-app's People

Contributors

crohr avatar mies avatar

Watchers

 avatar  avatar

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.