julialang / devcontainer-features Goto Github PK
View Code? Open in Web Editor NEWJulia Development Container Feature
Julia Development Container Feature
I believe that the postcreate.jl
script referenced from the current Dev Container Template can be installed with the julia Feature.
https://github.com/microsoft/vscode-dev-containers/blob/8918c936dfaf3b03b923ce63c524adf52d32e492/containers/julia/.devcontainer/devcontainer.json#L17
https://github.com/julia-vscode/julia-devcontainer/blob/60c2852703d5f4e2fc419198a95c49be37d12ccb/postcreate.jl
That would be helpful when creating a new Dev Container Template using the julia Feature.
It may be a good idea to change the installation path, see also how the common-utils Feature copies scripts into the container.
Would it make sense to e.g. pre-compile some packages in postcreate.jl
to make the language server etc. start faster? (once postcreate.jl
is done)
I.e.
LanguageServer
et al., i.e. the language server env., e.g., @ ~/.vscode-server/extensions/julialang.language-julia-1.60.2/scripts/environments/languageserver/v1.9
.VSCodeServer
https://containers.dev/collections
The julia Feature seems to be working well, so it would be good to add this repository to the index.
Once registered in the index, it will appear in the VS Code and Codespaces UI.
Note: There is currently no document URL set for Julia Feature, consider merging #7 and publishing a new version.
Looking at the Rust Feature, it does indeed contain the Better TOML extension.
https://github.com/devcontainers/features/blob/96bff0097028001e6e4126c5528d37cb8c13e785/src/rust/devcontainer-feature.json#L38-L52
Originally posted by @eitsupi in JuliaLang/devcontainer-templates#2 (comment)
The tests are failing on images with non-root users, as Juliaup and Julia are installed only for the root user at the moment.
Originally posted by @eitsupi in #3 (comment)
I get the following error during creation of a fresh dev container:
Running the postCreateCommand from Feature 'ghcr.io/julialang/devcontainer-features/julia:1'...
[11384 ms] Start: Run in container: /bin/sh -c /usr/local/julia-devcontainer-features/postcreate.jl
[20730 ms] postCreateCommand failed with exit code 1. Skipping any further user-provided commands.
I'm not able to see anything else.
My devcontainer.json
file is just this:
{
"image": "mcr.microsoft.com/devcontainers/base:ubuntu",
"features": {
"ghcr.io/julialang/devcontainer-features/julia:1": {},
}
}
When specifying PATH environment variable in the devcontainer.json, for example like this:
"remoteEnv": {
"PATH": "${containerEnv:PATH}"
}
the postcreate.jl script fails.
Running the postCreateCommand from Feature 'ghcr.io/julialang/devcontainer-features/julia:1'...
[19325 ms] Start: Run in container: /bin/sh -c /usr/local/julia-devcontainer-features/postcreate.jl
[20064 ms] postCreateCommand failed with exit code 127. Skipping any further user-provided commands.
Done. Press any key to close the terminal.
MWE here:
ahjulstad/julia-devcontainer-feature-errror-minimimworkingexample@df76810
julia> versioninfo()
Julia Version 1.10.2
Commit bd47eca2c8a (2024-03-01 10:14 UTC)
Build Info:
Official https://julialang.org/ release
Platform Info:
OS: Linux (x86_64-linux-gnu)
CPU: 12 ร Intel(R) Core(TM) i7-8850H CPU @ 2.60GHz
WORD_SIZE: 64
LIBM: libopenlibm
LLVM: libLLVM-15.0.7 (ORCJIT, skylake)
Threads: 1 default, 0 interactive, 1 GC (on 12 virtual cores)
After startup I can run Julia or the postcreate.jl
script just fine, but the language server does not start.
The resulting path if I delete the remoteEnv statement becomes:
/vscode/vscode-server/bin/linux-x64/e170252f762678dec6ca2cc69aba1570769a5d39/bin/remote-cli:/home/vscode/.juliaup/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/home/vscode/.local/bin
If I keep the remoteEnv statement
/home/vscode/.juliaup/bin:/vscode/vscode-server/bin/linux-x64/e170252f762678dec6ca2cc69aba1570769a5d39/bin/remote-cli:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/home/vscode/.local/bin
Same elements, but slightly different sequence.
(The purpose of the original path setting was to make the Julia-installed python available at the command prompt, with the goal of sharing python environments across devcontainers. And if you ask, why use devcontainers at all; I am on Windows.)
Perhaps this is caused by some core devcontainer feature, I don't know...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.