add directions from 4shutosh.com
This commit is contained in:
parent
a65a872a83
commit
1d9ae76682
2 changed files with 25 additions and 7 deletions
28
Dockerfile
28
Dockerfile
|
|
@ -9,20 +9,36 @@ WORKDIR /build
|
|||
RUN apk add --no-cache \
|
||||
bash \
|
||||
ca-certificates \
|
||||
openjdk21-jdk \
|
||||
openjdk21-jre-headless \
|
||||
git \
|
||||
curl
|
||||
#RUN curl -O https://download.clojure.org/install/linux-install-1.11.1.1435.sh && chmod +x linux-install-1.11.1.1435.sh && ./linux-install-1.11.1.1435.sh
|
||||
RUN curl -LO https://github.com/clojure/brew-install/releases/latest/download/linux-install.sh && chmod +x linux-install.sh && ./linux-install.sh
|
||||
RUN git clone https://github.com/logseq/logseq.git && cd logseq && yarn install
|
||||
RUN curl -LO https://github.com/clojure/brew-install/releases/latest/download/linux-install.sh \
|
||||
&& chmod +x linux-install.sh \
|
||||
&& ./linux-install.sh
|
||||
RUN git clone https://github.com/logseq/logseq.git --depth 1 \
|
||||
&& cd logseq \
|
||||
&& yarn install
|
||||
WORKDIR /build/logseq
|
||||
RUN git config --global --add safe.directory '*' \
|
||||
&& git config --global user.email "builder@local" \
|
||||
&& git config --global user.name "Docker Builder" \
|
||||
&& git remote add 4shutosh https://github.com/4shutosh/logseq.git \
|
||||
&& git fetch 4shutosh self_host/21_march_2026 \
|
||||
&& git cherry-pick 477061ffb
|
||||
WORKDIR /build/logseq/deps/db-sync
|
||||
#build db-sync
|
||||
RUN cd logseq/deps/db-sync && yarn install && yarn build:node-adapter && yarn install --production
|
||||
RUN yarn install \
|
||||
&& yarn build:node-adapter \
|
||||
&& yarn install --production
|
||||
#copy to /logseq-sync for final image
|
||||
RUN cd logseq/deps/db-sync && mkdir -p /logseq-sync/worker && mv worker/dist /logseq-sync/worker && mv node_modules package.json yarn.lock start.sh /logseq-sync
|
||||
RUN mkdir -p /logseq-sync/worker \
|
||||
&& mv worker/dist /logseq-sync/worker \
|
||||
&& mv node_modules package.json yarn.lock start.sh /logseq-sync
|
||||
|
||||
#final image
|
||||
FROM node:22-alpine3.21
|
||||
COPY --from=builder /logseq-sync /logseq-sync
|
||||
COPY start.sh /logseq-sync
|
||||
RUN apk add --no-cache \
|
||||
bash \
|
||||
curl
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue