feat: build custom Facefusion image with NSFW filter patch baked in

This commit is contained in:
2025-11-13 06:05:42 +01:00
parent 8f406f62c1
commit 95099a443e
2 changed files with 12 additions and 1 deletions

8
ai/Dockerfile Normal file
View File

@@ -0,0 +1,8 @@
FROM facefusion/facefusion:3.5.0-cpu
# Patch content_analyser.py to disable NSFW filter
RUN sed -i '197s/.*/\treturn False # Patched: NSFW filter disabled/' /facefusion/facefusion/content_analyser.py && \
grep -q 'return False.*Patched' /facefusion/facefusion/content_analyser.py || (echo "ERROR: Patch failed!" && exit 1)
# Verify patch was applied
RUN echo "NSFW filter patch successfully applied to image"