6 Commits

Author SHA1 Message Date
venus
f8725658a5 docker works 2026-03-04 16:22:41 -06:00
venus
e07c75d857 updated compose and moved dockerfile 2026-03-04 16:09:55 -06:00
venus
f8a791a4fe changed to __init__.py 2026-03-04 16:08:22 -06:00
venus
58ba0b1444 added gitignore 2026-03-04 16:07:56 -06:00
venus
994a96a0be updated requirements from deleted build.py 2026-03-04 16:07:05 -06:00
venus
8acb06764a removed public vault dir 2026-03-04 16:05:00 -06:00
9 changed files with 18 additions and 68 deletions

1
.gitignore vendored Normal file
View File

@@ -0,0 +1 @@
app/__pychache__

15
Dockerfile Executable file
View File

@@ -0,0 +1,15 @@
FROM python:3.14-slim
ARG DEBUG_MODE=0
ENV FLASK_DEBUG=$DEBUG_MODE
ENV FLASK_APP=app
RUN mkdir /app
COPY app/requirements.txt /app
RUN pip3 install -r /app/requirements.txt
COPY app /app
ENTRYPOINT ["flask"]
CMD ["--app", "app", "run", "--host=0.0.0.0", "--port=80"]

View File

@@ -1,21 +0,0 @@
FROM python:3.10-slim AS builder
ARG DEBUG_MODE=0
ENV FLASK_DEBUG=$DEBUG_MODE
ENV FLASK_APP=app
COPY requirements.txt
RUN pip3 install -r requirements.txt
COPY . .
EXPOSE 443
ENTRYPOINT ["flask"]
# CMD [ "run", "--host=0.0.0.0", "--port=80"]
CMD ["--app", "app", "run", "--host=0.0.0.0", "--port=443"]

View File

@@ -1,2 +1,4 @@
flask
markdown
obsidianmd-parser
GitPython

View File

@@ -1,15 +1,9 @@
services:
app:
build:
context: app
args:
- DEBUG_MODE=1
ports:
- '80:80'
volumes:
- ./content:/content
# public_vault_builder:
# build:
# context: public_vault_builder
# volumes:
# - ./public_vault:/content

View File

@@ -1,14 +0,0 @@
FROM python:3.12-slim
run mkdir /public-vault
WORKDIR /build
COPY requirements.txt .
RUN pip3 install -r requirements.txt
COPY . .
CMD ["python", "build.py"]

View File

@@ -1,25 +0,0 @@
from obsidian_parser import Vault
import shutil
from git import Repo
# repo_url = "https://gitlab.com/username/my-vault.git"
dest = "/content"
src = "Personal-Wiki"
# Load a vault
vault = Vault(src)
if vault:
print ("found vault")
else:
print("could not find vault")
# Find notes by exact name
note = vault.get_note("test")
# Findd all public notes
publicNotes = vault.get_notes_with_tag("public")
for note in publicNotes:
print(note.title)
shutil.copy2(f"{note.path}", dest)

View File

@@ -1,2 +0,0 @@
obsidianmd-parser
GitPython