-
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.
feat: gains development dockerization (#12)
* expose host url to dev dockerfile * add dev Dockerfile and compose * only COPY necessary files * remove old comment * add more useful comments * remove "as build" * rename techmix dataset * volume mount json assets
- Loading branch information
Showing
5 changed files
with
48 additions
and
3 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 |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Build the Svelte application | ||
# Use the official Node.js image as the base image | ||
FROM node:18-alpine | ||
|
||
# Set the working directory | ||
WORKDIR /app | ||
|
||
# Copy package.json and package-lock.json to the working directory | ||
COPY package*.json ./ | ||
|
||
# Install the dependencies | ||
RUN npm install | ||
|
||
# Copy necessary configurations to the working directory | ||
COPY postcss.config.cjs ./ | ||
COPY svelte.config.js ./ | ||
COPY tailwind.config.ts ./ | ||
COPY tsconfig.json ./ | ||
COPY vite.config.ts ./ | ||
|
||
# Copy the source code to the working directory | ||
COPY src ./src | ||
COPY static ./static | ||
COPY .svelte-kit ./.svelte-kit | ||
|
||
EXPOSE 3000 | ||
|
||
CMD ["npm", "run", "dev"] |
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 |
---|---|---|
@@ -0,0 +1,13 @@ | ||
--- | ||
services: | ||
svelte-app: | ||
build: | ||
context: . | ||
dockerfile: Dockerfile.dev | ||
ports: | ||
- '3000:3000' | ||
volumes: | ||
- type: bind | ||
source: ${JSON_ASSETS_PATH} | ||
target: /app/src/json | ||
read_only: true |
File renamed without changes.
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
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