-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
36 lines (25 loc) · 783 Bytes
/
Dockerfile
File metadata and controls
36 lines (25 loc) · 783 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# Build stage
FROM golang:1.22-bullseye AS build
LABEL authors="Jonathon Chambers"
LABEL description="This is the Dockerfile for setting up the Kratom Tracker Application"
# Set the Current Working Directory inside the container
WORKDIR /app
# Install Node.js
RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - && \
apt-get install -y nodejs
# Validate Node and NPM installation
RUN node -v && npm -v
# Copy the source
COPY . .
# Build the application
RUN chmod +x build_prod.sh && \
./build_prod.sh
# Final stage
FROM debian:bullseye-slim
WORKDIR /app
# Copy the build output from the build stage
COPY --from=build /app/output/kratom_tracker /app/kratom_tracker
# Expose the port the app runs on
EXPOSE 8080
# Run the binary
CMD ["/app/kratom_tracker"]