FAQ
Hello, gophers! I have read some e-mail threads with some methods to
pack all data into single binary for go install. But i can't select
one for using.
I need to distribute some templates, maybe some css files and images
in one binary web app. This files must not slowdown compiling
application and not utilize ram.
Does it possible? What package i need to use?
Thanks for all answers.

--
Vasiliy Tolstov,
Clodo.ru
e-mail: v.tolstov@selfip.ru
jabber: vase@selfip.ru

--

Search Discussions

  • Miki Tebeka at Oct 27, 2012 at 4:23 am
    I updated nrsc <https://bitbucket.org/tebeka/nrsc> to do about what you
    want. Please let me know if you find any issues.
    On Thursday, October 25, 2012 11:59:51 AM UTC-7, Vasiliy Tolstov wrote:

    Hello, gophers! I have read some e-mail threads with some methods to
    pack all data into single binary for go install. But i can't select
    one for using.
    I need to distribute some templates, maybe some css files and images
    in one binary web app. This files must not slowdown compiling
    application and not utilize ram.
    Does it possible? What package i need to use?
    Thanks for all answers.

    --
    Vasiliy Tolstov,
    Clodo.ru
    e-mail: v.to...@selfip.ru <javascript:>
    jabber: va...@selfip.ru <javascript:>
    --
  • Carlos Castillo at Oct 27, 2012 at 11:47 am
    Alternatively you could use my resources package:
    http://github.com/cookieo9/resources-go/

    Both versions of the package supports the appended zip-file (what nrsc
    does) without fuss (simply "cat app-norsrc rsrc.zip > app"). The older V1
    version also uses the same interface to access files from a search path,
    including loading from the current package if it's in GOPATH, so you can
    run your app without packing in the resources, modify them on the fly, and
    then use the packed version for distribution with little to no code changes.
    On Friday, October 26, 2012 12:32:05 PM UTC-7, Miki Tebeka wrote:

    I updated nrsc <https://bitbucket.org/tebeka/nrsc> to do about what you
    want. Please let me know if you find any issues.
    On Thursday, October 25, 2012 11:59:51 AM UTC-7, Vasiliy Tolstov wrote:

    Hello, gophers! I have read some e-mail threads with some methods to
    pack all data into single binary for go install. But i can't select
    one for using.
    I need to distribute some templates, maybe some css files and images
    in one binary web app. This files must not slowdown compiling
    application and not utilize ram.
    Does it possible? What package i need to use?
    Thanks for all answers.

    --
    Vasiliy Tolstov,
    Clodo.ru
    e-mail: v.to...@selfip.ru
    jabber: va...@selfip.ru
    --
  • Vasiliy Tolstov at Oct 29, 2012 at 11:40 am

    2012/10/27 Carlos Castillo <cookieo9@gmail.com>:
    Alternatively you could use my resources package:
    http://github.com/cookieo9/resources-go/

    Both versions of the package supports the appended zip-file (what nrsc does)
    without fuss (simply "cat app-norsrc rsrc.zip > app"). The older V1 version
    also uses the same interface to access files from a search path, including
    loading from the current package if it's in GOPATH, so you can run your app
    without packing in the resources, modify them on the fly, and then use the
    packed version for distribution with little to no code changes.
    On Friday, October 26, 2012 12:32:05 PM UTC-7, Miki Tebeka wrote:

    I updated nrsc to do about what you want. Please let me know if you find
    any issues.
    On Thursday, October 25, 2012 11:59:51 AM UTC-7, Vasiliy Tolstov wrote:

    Hello, gophers! I have read some e-mail threads with some methods to
    pack all data into single binary for go install. But i can't select
    one for using.
    I need to distribute some templates, maybe some css files and images
    in one binary web app. This files must not slowdown compiling
    application and not utilize ram.
    Does it possible? What package i need to use?
    Thanks for all answers.
    Thanks for links, but is that possible to get desired binary not run
    additional commands? For example on clean system i get go install
    http://github.com/xxx/xx and get full binary with all assets included?

    --
    Vasiliy Tolstov,
    Clodo.ru
    e-mail: v.tolstov@selfip.ru
    jabber: vase@selfip.ru

    --
  • Minux at Oct 29, 2012 at 11:24 am

    On Mon, Oct 29, 2012 at 6:39 PM, Vasiliy Tolstov wrote:

    Thanks for links, but is that possible to get desired binary not run
    additional commands? For example on clean system i get go install
    http://github.com/xxx/xx and get full binary with all assets included?
    to fulfill this, you need to resort to byte slice in Go file method or
    a .syso based solution.

    --
  • Vasiliy Tolstov at Oct 29, 2012 at 12:00 pm

    2012/10/29 minux <minux.ma@gmail.com>:
    to fulfill this, you need to resort to byte slice in Go file method or
    a .syso based solution.
    Thanks!

    --
    Vasiliy Tolstov,
    Clodo.ru
    e-mail: v.tolstov@selfip.ru
    jabber: vase@selfip.ru

    --

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupgolang-nuts @
categoriesgo
postedOct 25, '12 at 6:59p
activeOct 29, '12 at 12:00p
posts6
users4
websitegolang.org

People

Translate

site design / logo © 2022 Grokbase