Gitpod seems not work
Closed this issue ยท 7 comments
First of all, thanks for the great libraries! I have recently been having fun creating slides using SLyDIFi ๐
What I've encountered
When I opened this repo in Gitpod using the link on README, I got the following error in the integrated terminal:
HISTFILE=/workspace/.gitpod/cmd-0 history -r; {
export PATH=/home/gitpod/.opam/4.10.0/bin:$PATH;./entrypoint.sh
} && {
satysfi demo/demo.saty; open demo/demo.saty demo/demo.pdf
}
od/cmd-0 history -r; {9j2bk08qpv5:/workspace/slydifi$ HISTFILE=/workspace/.gitpo
> export PATH=/home/gitpod/.opam/4.10.0/bin:$PATH;./entrypoint.sh
> } && {
> satysfi demo/demo.saty; open demo/demo.saty demo/demo.pdf
> }
[ERROR] Opam has not been initialised, please run `opam init'
[ERROR] Opam has not been initialised, please run `opam init'
[ERROR] Opam has not been initialised, please run `opam init'
./entrypoint.sh: 9: satyrographos: not found
gitpod@monaqa-slydifi-9j2bk08qpv5:/workspace/slydifi$
It seems that opam is not initialized correctly. I have also tried Gitpod with other libraries such as easytable, and got the same error.
It is probably because the user who invoked opam init (root) and the user on Gitpod (gitpod) are different.
Thanks for the report.
I don't usually use gitpod or docker-satysfi, so I have no idea how to solve this problem. Do you have any good ideas?
To be honest, I also have no idea because I don't usually use gitpod too...
But it seems to me that it need to be done it manually, including the installation of SATySFi, as a normal user. I have tried the following configuration in my private repo and it works fine.
# .gitpod.Dockerfile
FROM gitpod/workspace-base
RUN sudo install-packages opam
USER gitpod
RUN echo '. /home/gitpod/.opam/opam-init/init.sh > /dev/null 2> /dev/null || true' >> /home/gitpod/.bashrc
RUN opam init --disable-sandboxing
RUN eval $(opam env) && opam repository add satysfi-external https://github.com/gfngfn/satysfi-external-repo.git
RUN eval $(opam env) && opam repository add satyrographos https://github.com/na4zagin3/satyrographos-repo.git
RUN eval $(opam env) && opam update
RUN eval $(opam env) && opam install --yes satysfi satysfi-dist satyrographos
RUN eval $(opam env) && satyrographos install
But this of course takes a lot of time to build the image.
Thank you!
Hmm, if the Dockerfile is going to be somewhat complicated or manual one, it might be better to create a separate repository for a quick trial of SATySFi.
This is the SLyDIFi repository, and the Gitpod demo environment is just an adjunct, so I would like to avoid seriously maintaining Dockerfile here.
May I create a docker image for Gitpod + SATySFi which can be used here?
I'm currently planning to release SATySFi Workshop to Open VSX (Marketplace for Gitpod, etc.), so I think I would be the right person to manage it ๐
I too have been thinking how great it would be if the SATySFi workshop was available online. I would be extremely grateful if you could do that for me!
Iโve just created a docker image (pickoba/gitpod-satysfi) and a template which use it! You can now use SATySFi, Satyrographos, and satysfi-language-server on Gitpod!
Excellent!!
I have confirmed that your Gitpod template does indeed work in this repository.
Thank you again!