Skip to content
This repository has been archived by the owner on Nov 20, 2021. It is now read-only.

Compiling issue - modifying any files in the public folder has no effect when compiling the docker image #27

Open
gionko opened this issue Oct 14, 2021 · 1 comment

Comments

@gionko
Copy link

gionko commented Oct 14, 2021

Hi,
i have clone your git hub repo
https://github.com/criticalstack/quake-kube.git

and edit the file
quake-kube/public/index.html

adding this lines
args.push.apply(args, ['+set', 'cg_drawfps', '"1"'])
args.push.apply(args, ['+set', 'cg_fov', '"115"'])
after line 142.

but after compiling the docker image, the changes have no effect. Compilation is successful.

In directory
quake-kube/public/
it's file called zz_generated.static.go and inside is (line 217):
"/index.html": &vfsgen۰CompressedFileInfo{ name: "index.html", modTime: time.Time{}, uncompressedSize: 6166, compressedContent: []byte("\x1f\x8b\x08\... ...\x00\x00"),

perhaps the index.html file is not recompressed and converted. How can I solve?

@gionko
Copy link
Author

gionko commented Oct 14, 2021

ok, i found a solution:

in Dockerfile add after line 12
COPY tools tools/
RUN /usr/local/go/bin/go run ./tools/genstatic.go public public

and in .dockerignore file remove
tools

now when you compile a docker image, the zz_generated.static.go file is regenerated based on the changes made in the public folder

@gionko gionko changed the title Compiling issue Compiling issue - edit any files in public folder not have effect in compiling docker image Oct 14, 2021
@gionko gionko changed the title Compiling issue - edit any files in public folder not have effect in compiling docker image Compiling issue - modifying any files in the public folder has no effect when compiling the docker image Oct 14, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant