Hansimov commited on
Commit
7832245
1 Parent(s): dd37946

:gem: [Feature] Dockerfile: Minimal working instance

Browse files
Files changed (2) hide show
  1. Dockerfile +8 -0
  2. utils/enver.py +1 -5
Dockerfile ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ FROM python:3.11-slim
2
+ WORKDIR /app
3
+ COPY requirements.txt .
4
+ RUN pip install -r requirements.txt
5
+ COPY . .
6
+ VOLUME /data
7
+ EXPOSE 22222
8
+ CMD ["python", "-m", "apis.chat_api"]
utils/enver.py CHANGED
@@ -5,9 +5,8 @@ from pathlib import Path
5
 
6
 
7
  class OSEnver:
8
- def __init__(self, global_scope=True):
9
  self.envs_stack = []
10
- self.global_scope = global_scope
11
  self.envs = os.environ.copy()
12
 
13
  def store_envs(self):
@@ -47,8 +46,5 @@ class OSEnver:
47
  else:
48
  pass
49
 
50
- if self.global_scope:
51
- os.environ = self.envs
52
-
53
 
54
  enver = OSEnver()
 
5
 
6
 
7
  class OSEnver:
8
+ def __init__(self):
9
  self.envs_stack = []
 
10
  self.envs = os.environ.copy()
11
 
12
  def store_envs(self):
 
46
  else:
47
  pass
48
 
 
 
 
49
 
50
  enver = OSEnver()