Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
4570d10238
|
|||
|
c05cd29028
|
@@ -11,9 +11,9 @@ RUN pip install --no-cache-dir --upgrade torch torchvision mokuro
|
|||||||
|
|
||||||
# create a user to run the application
|
# create a user to run the application
|
||||||
RUN useradd -m mokurouser \
|
RUN useradd -m mokurouser \
|
||||||
&& mkdir -p /home/mokurouser/mokuro \
|
&& mkdir -p /mokuro \
|
||||||
&& chown -R mokurouser:mokurouser /home/mokurouser
|
&& chown -R mokurouser:mokurouser /mokuro
|
||||||
|
|
||||||
WORKDIR /home/mokurouser/mokuro
|
WORKDIR /mokuro
|
||||||
|
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|||||||
@@ -8,8 +8,8 @@ services:
|
|||||||
container_name: mokuro
|
container_name: mokuro
|
||||||
user: 1000:1000
|
user: 1000:1000
|
||||||
volumes:
|
volumes:
|
||||||
- ~/S/japanese/manga:/home/mokurouser/mokuro
|
- ~/S/japanese/manga:/mokuro/manga
|
||||||
command: mokuro --parent_dir One\ Piece\ Color --disable_confirmation && ./zip.sh "One Piece Color"
|
command: mokuro --parent_dir "manga/One Piece Color" --disable_confirmation && ./zip.sh "manga/One Piece Color"
|
||||||
runtime: nvidia
|
runtime: nvidia
|
||||||
restart: no
|
restart: no
|
||||||
network_mode: host
|
network_mode: host
|
||||||
|
|||||||
4
zip.sh
4
zip.sh
@@ -12,7 +12,9 @@ for f in *.mokuro; do
|
|||||||
base="${f%.mokuro}"
|
base="${f%.mokuro}"
|
||||||
dir="$base"
|
dir="$base"
|
||||||
zipfile="$base.zip"
|
zipfile="$base.zip"
|
||||||
if [ -d "$dir" ]; then
|
if [[ -f "$zipfile" ]]; then
|
||||||
|
echo "Warning: Zip file $zipfile already exists, skipping."
|
||||||
|
elif [ -d "$dir" ]; then
|
||||||
echo "Zipping: $zipfile <- $f $dir/"
|
echo "Zipping: $zipfile <- $f $dir/"
|
||||||
zip -qr "$zipfile" "$f" "$dir"
|
zip -qr "$zipfile" "$f" "$dir"
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user