-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
39 lines (29 loc) · 950 Bytes
/
Copy pathDockerfile
File metadata and controls
39 lines (29 loc) · 950 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
37
38
39
FROM node:25-alpine
RUN apk add --no-cache \
git \
curl \
openssh \
build-base \
python3
RUN mkdir -p /var/run/sshd \
&& sed -i 's/^#\?PermitRootLogin.*/PermitRootLogin yes/' /etc/ssh/sshd_config \
&& sed -i 's/^#\?PasswordAuthentication.*/PasswordAuthentication yes/' /etc/ssh/sshd_config
EXPOSE 22 3000
WORKDIR /var/www/html
ARG TYPESENSE_COLLECTION_NAME
ARG TYPESENSE_HOST
ARG TYPESENSE_PORT
ARG TYPESENSE_PROTOCOL
ARG TYPESENSE_SEARCH_API_KEY
ENV TYPESENSE_COLLECTION_NAME=$TYPESENSE_COLLECTION_NAME
ENV TYPESENSE_HOST=$TYPESENSE_HOST
ENV TYPESENSE_PORT=$TYPESENSE_PORT
ENV TYPESENSE_PROTOCOL=$TYPESENSE_PROTOCOL
ENV TYPESENSE_SEARCH_API_KEY=$TYPESENSE_SEARCH_API_KEY
COPY package.json package-lock.json ./
RUN npm ci
COPY . .
RUN npm run build
COPY docker-entrypoint.sh /usr/local/bin/docker-entrypoint.sh
RUN chmod +x /usr/local/bin/docker-entrypoint.sh
ENTRYPOINT [ "/usr/local/bin/docker-entrypoint.sh" ]