Updates
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
FROM node:lts-trixie
|
||||
|
||||
RUN apt update && apt install -y ca-certificates curl zip unzip wget rsync openssh-client zlib1g
|
||||
|
||||
RUN update-ca-certificates
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
RUN curl -fsSL https://bun.sh/install | bash
|
||||
ENV PATH="/root/.bun/bin:${PATH}"
|
||||
|
||||
COPY ./entrypoint.sh /usr/local/bin/entrypoint.sh
|
||||
RUN chmod +x /usr/local/bin/entrypoint.sh
|
||||
|
||||
|
||||
ENTRYPOINT ["entrypoint.sh"]
|
||||
@@ -0,0 +1,14 @@
|
||||
#!/bin/bash
|
||||
|
||||
cd /app
|
||||
|
||||
if [[ -z "$NODE_ENV" ]]; then
|
||||
echo "NODE_ENV is not set. Defaulting to development."
|
||||
NODE_ENV="development"
|
||||
fi
|
||||
|
||||
if [[ "$NODE_ENV" == "production" ]]; then
|
||||
bun src/cron/index.ts
|
||||
else
|
||||
bun --watch src/cron/index.ts
|
||||
fi
|
||||
Reference in New Issue
Block a user