import dockerfile

This commit is contained in:
2025-06-07 15:28:06 -04:00
commit ee5e85f2b2

20
Dockerfile Normal file
View File

@ -0,0 +1,20 @@
FROM alpine:latest AS build
ARG GIT_REF="main"
WORKDIR /src
RUN apk add git cmake nodejs npm alpine-sdk dbus-dev
COPY . .
#RUN git clone --recurse-submodules --branch ${GIT_REF} https://github.com/Affirmatech/MeshSense.git .
# Web Bluetooth
RUN cd api/webbluetooth && npm i && npm run build:all
# Meshtastic JS
RUN cd api/meshtastic-js && npm i && npm run build
# Install dependencies
RUN cd ui && npm i && cd ../api && npm i
# Build
RUN cd ui && npm run build && cd ../api && npm run build
FROM alpine:latest
WORKDIR /app
RUN apk add nodejs dbus-dev
COPY --from=build /src/api/dist /app
CMD ["node", "index.cjs"]