rhoitjadhav commited on
Commit
5e42df4
1 Parent(s): be25e79

update dockerfile

Browse files
Files changed (4) hide show
  1. .gitignore +2 -1
  2. Dockerfile +4 -6
  3. start.sh +0 -1
  4. users.yml +5 -6
.gitignore CHANGED
@@ -1 +1,2 @@
1
- .history
 
 
1
+ .history
2
+ .idea
Dockerfile CHANGED
@@ -4,12 +4,12 @@ FROM ubuntu:20.04
4
  EXPOSE 6900
5
 
6
  # Environment variables
7
- ENV USERS_DB=/users.yml
8
  ENV UVICORN_PORT=6900
9
 
10
  # Install Python
11
  RUN apt update
12
- RUN apt -y install curl python3.9 python3.9-dev python3.9-distutils gcc gnupg
13
  RUN curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
14
  RUN python3.9 get-pip.py
15
 
@@ -27,7 +27,5 @@ COPY users.yml /
27
  COPY start.sh /
28
  RUN chmod +x /start.sh
29
 
30
- USER root
31
-
32
- CMD service elasticsearch start; sleep 15; uvicorn argilla:app --host "0.0.0.0"
33
-
 
4
  EXPOSE 6900
5
 
6
  # Environment variables
7
+ ENV ARGILLA_LOCAL_AUTH_USERS_DB_FILE=/users.yml
8
  ENV UVICORN_PORT=6900
9
 
10
  # Install Python
11
  RUN apt update
12
+ RUN apt -y install curl python3.9 python3.9-dev python3.9-distutils gcc gnupg apache2-utils
13
  RUN curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
14
  RUN python3.9 get-pip.py
15
 
 
27
  COPY start.sh /
28
  RUN chmod +x /start.sh
29
 
30
+ # Executing argilla along with elasticsearch
31
+ CMD /bin/bash /start.sh
 
 
start.sh CHANGED
@@ -7,4 +7,3 @@ service elasticsearch start
7
  echo "Waiting for elasticsearch to start"
8
  sleep 15
9
  uvicorn argilla:app --host "0.0.0.0"
10
-
 
7
  echo "Waiting for elasticsearch to start"
8
  sleep 15
9
  uvicorn argilla:app --host "0.0.0.0"
 
users.yml CHANGED
@@ -1,9 +1,8 @@
1
- - username: argilla
2
- hashed_password: $2b$12$vyJHxSgZ1MDeXvqOEVln.OjWiSY9x/wiAx8j9nP2VH0m9cOoyUq.a
3
- api_key: "argilla.apikey"
4
- workspaces: ["huggingface"]
5
  - username: admin
6
  hashed_password: $2b$12$vyJHxSgZ1MDeXvqOEVln.OjWiSY9x/wiAx8j9nP2VH0m9cOoyUq.a
7
  api_key: "admin.apikey"
8
- workspaces: []
9
-
 
 
 
 
 
 
 
 
1
  - username: admin
2
  hashed_password: $2b$12$vyJHxSgZ1MDeXvqOEVln.OjWiSY9x/wiAx8j9nP2VH0m9cOoyUq.a
3
  api_key: "admin.apikey"
4
+ workspaces: [ ]
5
+ - username: argilla
6
+ hashed_password: $2b$12$vyJHxSgZ1MDeXvqOEVln.OjWiSY9x/wiAx8j9nP2VH0m9cOoyUq.a
7
+ api_key: "argilla.apikey"
8
+ workspaces: [ "huggingface" ]