-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add ability to package static content into the binary. #69
Labels
Comments
The reasoning for using https://github.com/phogolabs/parcello:
|
vrongmeal
added a commit
that referenced
this issue
Nov 12, 2020
This is possible by generating a zipped blob of `static` directory into a Go file, precisely, `pkg/static/resources.go`. This file can be generated using `make static` command. Fixes #69 Signed-off-by: Vaibhav <[email protected]>
vrongmeal
added a commit
that referenced
this issue
Nov 12, 2020
Now files can be accessed through the `NewFS` method of the static package and when run in debug mode, i.e., with "DEBUG" environment variable set to "on", there is no requirement of packing files inside resources.go and the build will run just fine from the root directory. Fixes #69 Signed-off-by: Vaibhav <[email protected]>
murex971
pushed a commit
that referenced
this issue
Nov 13, 2020
This is possible by generating a zipped blob of `static` directory into a Go file, precisely, `pkg/static/resources.go`. This file can be generated using `make static` command. Fixes #69 Signed-off-by: Vaibhav <[email protected]>
murex971
pushed a commit
that referenced
this issue
Nov 13, 2020
Now files can be accessed through the `NewFS` method of the static package and when run in debug mode, i.e., with "DEBUG" environment variable set to "on", there is no requirement of packing files inside resources.go and the build will run just fine from the root directory. Fixes #69 Signed-off-by: Vaibhav <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
For this, it's much better to write a script that produces a blob file that includes the contents of all the files.
https://github.com/phogolabs/parcello seems to fit nicely for this purpose. golang/go#35950 (comment) on the discussion thread nicely layouts many other options so we can let this be open for discussion for which option to chose.
The text was updated successfully, but these errors were encountered: