Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Anything Llm
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mirrored_repos
MachineLearning
Mintplex Labs
Anything Llm
Commits
74d7038a
Unverified
Commit
74d7038a
authored
1 year ago
by
Preetesh Jain
Committed by
GitHub
1 year ago
Browse files
Options
Downloads
Patches
Plain Diff
fix: add platform config in docker compose (#60)
parent
2a556c27
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
docker/Dockerfile
+4
-5
4 additions, 5 deletions
docker/Dockerfile
docker/HOW_TO_USE_DOCKER.md
+1
-16
1 addition, 16 deletions
docker/HOW_TO_USE_DOCKER.md
docker/docker-compose.yml
+1
-1
1 addition, 1 deletion
docker/docker-compose.yml
with
6 additions
and
22 deletions
docker/Dockerfile
+
4
−
5
View file @
74d7038a
...
@@ -5,7 +5,6 @@ FROM ubuntu:jammy-20230522 AS base
...
@@ -5,7 +5,6 @@ FROM ubuntu:jammy-20230522 AS base
ARG
ARG_UID
ARG
ARG_UID
ARG
ARG_GID
ARG
ARG_GID
ARG
ARG_CLOUD_BUILD=0 # Default to local docker build
ARG
ARG_CLOUD_BUILD=0 # Default to local docker build
ARG
ARCH=amd64 # Default to amd64 if not provided
# Install system dependencies
# Install system dependencies
RUN
DEBIAN_FRONTEND
=
noninteractive apt-get update
&&
\
RUN
DEBIAN_FRONTEND
=
noninteractive apt-get update
&&
\
...
@@ -21,9 +20,9 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get update && \
...
@@ -21,9 +20,9 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get update && \
curl
-LO
https://github.com/yarnpkg/yarn/releases/download/v1.22.19/yarn_1.22.19_all.deb
\
curl
-LO
https://github.com/yarnpkg/yarn/releases/download/v1.22.19/yarn_1.22.19_all.deb
\
&&
dpkg
-i
yarn_1.22.19_all.deb
\
&&
dpkg
-i
yarn_1.22.19_all.deb
\
&&
rm
yarn_1.22.19_all.deb
&&
\
&&
rm
yarn_1.22.19_all.deb
&&
\
curl
-LO
https://github.com/jgm/pandoc/releases/download/3.1.3/pandoc-3.1.3-1-
${
ARCH
}
.deb
\
curl
-LO
https://github.com/jgm/pandoc/releases/download/3.1.3/pandoc-3.1.3-1-
amd64
.deb
\
&&
dpkg
-i
pandoc-3.1.3-1-
${
ARCH
}
.deb
\
&&
dpkg
-i
pandoc-3.1.3-1-
amd64
.deb
\
&&
rm
pandoc-3.1.3-1-
${
ARCH
}
.deb
&&
\
&&
rm
pandoc-3.1.3-1-
amd64
.deb
&&
\
rm
-rf
/var/lib/apt/lists/
*
/usr/share/icons
&&
\
rm
-rf
/var/lib/apt/lists/
*
/usr/share/icons
&&
\
dpkg-reconfigure
-f
noninteractive tzdata
&&
\
dpkg-reconfigure
-f
noninteractive tzdata
&&
\
python3
-m
pip
install
--no-cache-dir
virtualenv
python3
-m
pip
install
--no-cache-dir
virtualenv
...
@@ -91,7 +90,7 @@ HEALTHCHECK --interval=1m --timeout=10s --start-period=1m \
...
@@ -91,7 +90,7 @@ HEALTHCHECK --interval=1m --timeout=10s --start-period=1m \
CMD /bin/bash /usr/local/bin/docker-healthcheck.sh || exit 1
CMD /bin/bash /usr/local/bin/docker-healthcheck.sh || exit 1
# Docker will still install deps as root so need to force chown
# Docker will still install deps as root so need to force chown
# or else
# or else
USER
root
USER
root
RUN if
[
"
$ARG_CLOUD_BUILD
"
=
1
]
;
then
\
RUN if
[
"
$ARG_CLOUD_BUILD
"
=
1
]
;
then
\
echo
"Reowning all files as user!"
&&
\
echo
"Reowning all files as user!"
&&
\
...
...
This diff is collapsed.
Click to expand it.
docker/HOW_TO_USE_DOCKER.md
+
1
−
16
View file @
74d7038a
...
@@ -9,22 +9,7 @@ Use the Dockerized version of AnythingLLM for a much faster and complete startup
...
@@ -9,22 +9,7 @@ Use the Dockerized version of AnythingLLM for a much faster and complete startup
-
`git clone`
this repo and
`cd anything-llm`
to get to the root directory.
-
`git clone`
this repo and
`cd anything-llm`
to get to the root directory.
-
`yarn setup:envs`
from repo root & fill out the
`.env`
file that is then created in
`./docker/`
-
`yarn setup:envs`
from repo root & fill out the
`.env`
file that is then created in
`./docker/`
-
`cd docker/`
-
`cd docker/`
-
To build the image,
**use any of these commands based on your CPU architecture**
.
-
`docker-compose up -d --build`
to build the image - this will take a few moments.
**This will use `amd64` (common on Windows/Intel Mac)**
```
docker-compose up -d --build
```
**This will use `arm64` (M1/M2 Mac)**
```
ARCH=arm64 docker-compose up -d --build
```
This step will take a few moments on the first run.
Your docker host will show the image as online once the build process is completed. This will build the app to
`http://localhost:3001`
.
Your docker host will show the image as online once the build process is completed. This will build the app to
`http://localhost:3001`
.
...
...
This diff is collapsed.
Click to expand it.
docker/docker-compose.yml
+
1
−
1
View file @
74d7038a
...
@@ -10,6 +10,7 @@ services:
...
@@ -10,6 +10,7 @@ services:
anything-llm
:
anything-llm
:
container_name
:
anything-llm
container_name
:
anything-llm
image
:
anything-llm:latest
image
:
anything-llm:latest
platform
:
linux/amd64
build
:
build
:
context
:
../.
context
:
../.
dockerfile
:
./docker/Dockerfile
dockerfile
:
./docker/Dockerfile
...
@@ -17,7 +18,6 @@ services:
...
@@ -17,7 +18,6 @@ services:
ARG_UID
:
${UID}
ARG_UID
:
${UID}
ARG_GID
:
${GID}
ARG_GID
:
${GID}
ARG_CLOUD_BUILD
:
${CLOUD_BUILD}
ARG_CLOUD_BUILD
:
${CLOUD_BUILD}
ARCH
:
${ARCH:-amd64}
volumes
:
volumes
:
-
"
../server/storage:/app/server/storage"
-
"
../server/storage:/app/server/storage"
-
"
../collector/hotdir/:/app/collector/hotdir"
-
"
../collector/hotdir/:/app/collector/hotdir"
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment