forked from OneFinityCNC/onefinity-firmware
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
30 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,11 +16,39 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
gnupg \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
# Install Node.js 14.x | ||
RUN curl -fsSL https://deb.nodesource.com/setup_14.x | bash - && \ | ||
# Install Node.js 18.x | ||
RUN curl -fsSL https://deb.nodesource.com/setup_18.x | bash - && \ | ||
apt-get install -y nodejs && \ | ||
rm -rf /var/lib/apt/lists/* | ||
|
||
# Install npm packages globally | ||
RUN npm install -g [email protected] typescript | ||
|
||
# Set working directory for svelte components and create package.json | ||
WORKDIR /workspace/onefinity-firmware/src/svelte-components | ||
RUN echo '{\n\ | ||
"name": "svelte-components",\n\ | ||
"version": "0.0.0",\n\ | ||
"type": "module",\n\ | ||
"scripts": {\n\ | ||
"dev": "vite",\n\ | ||
"build": "vite build",\n\ | ||
"preview": "vite preview"\n\ | ||
},\n\ | ||
"dependencies": {\n\ | ||
"svelte": "^4.2.0"\n\ | ||
},\n\ | ||
"devDependencies": {\n\ | ||
"@sveltejs/vite-plugin-svelte": "^2.4.6",\n\ | ||
"@tsconfig/svelte": "^5.0.2",\n\ | ||
"typescript": "^5.3.3",\n\ | ||
"vite": "^4.5.1"\n\ | ||
}\n\ | ||
}' > package.json && npm install --legacy-peer-deps | ||
|
||
# Reset working directory | ||
WORKDIR /workspace | ||
|
||
# Install additional Python packages | ||
RUN pip3 install tornado | ||
|
||
|
@@ -38,8 +66,5 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
sudo \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
# Set working directory | ||
WORKDIR /workspace | ||
|
||
# Set default command | ||
CMD ["/bin/bash"] |