This commit is contained in:
ITO Mac
2026-05-26 10:37:25 +02:00
parent c8cd541348
commit d4faf05bcb
3 changed files with 8 additions and 4 deletions

View File

@@ -7,7 +7,7 @@ COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt RUN pip install --no-cache-dir -r requirements.txt
# Kopiraj kod NAKON instalacije # Kopiraj kod NAKON instalacije
COPY app/ ./app/ COPY . ./app/
EXPOSE 8000 EXPOSE 8000

View File

@@ -4,8 +4,12 @@ app = FastAPI()
@app.get("/") @app.get("/")
def root(): def root():
return {"message": "Pozdrav svijete!", "autor": "VAŠ_KORISNIK"} return {"message": "Pozdrav svijete! (v2)", "autor": "VAŠ_KORISNIK"}
@app.get("/health") @app.get("/health")
def health(): def health():
return {"status": "ok"} return {"status": "ok", "version": "2.0"}
@app.get("/info")
def info():
return {"servis": "priprema-za-kolokvij", "verzija": "2.0"}

View File

@@ -15,7 +15,7 @@ spec:
spec: spec:
containers: containers:
- name: priprema-za-kolokvij - name: priprema-za-kolokvij
image: git.fpmoz.sum.ba/blazp04/priprema-za-kolokvij:1.0 image: git.fpmoz.sum.ba/blazp04/priprema-za-kolokvij:2.0
ports: ports:
- containerPort: 8000 - containerPort: 8000
resources: resources: