Giter Site home page Giter Site logo

piped-docker's Introduction

piped-docker's People

Contributors

atomhare avatar billigsteruser avatar bionade24 avatar bnyro avatar cbruegg avatar firemasterk avatar jeidnx avatar nyarau avatar soochaehwa avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

piped-docker's Issues

Backend boot problem on minipc

Tried running the project on minipc I've got I'm getting problems with the backend(1337kavin/piped:latest)

I'll crash with this error

Error: Port Library failed to initialize: -86
piped-backend | Error: Could not create the Java Virtual Machine.
piped-backend | Error: A fatal exception has occurred. Program will exit.

So I tried building the image from Piped-Backend but I'm getting a few errors

ERROR: JAVA_HOME is set to an invalid directory: /opt/java/openjdk

Checked /opt/java/openjdk/bin/java it exists and it can be executed I even forced it -rwxrwxrwx 1 root root 16320 Aug 17 11:55 /opt/java/openjdk/bin/java I skipped the check to see if that was the only error.

[0.005s][warning][os,thread] Failed to start thread "GC Thread#0" - pthread_create failed (EPERM) for attributes: stacksize: 1024k, guardsize: 4k, detached.
#
# There is insufficient memory for the Java Runtime Environment to continue.
# Cannot create worker GC thread. Out of system resources.
# An error report file with more information is saved as:
# /app/hs_err_pid6.log

output from "/app/hs_err_pid6.log"

#
# There is insufficient memory for the Java Runtime Environment to continue.
# Cannot create worker GC thread. Out of system resources.
# Possible reasons:
#   The system is out of physical RAM or swap space
#   The process is running with CompressedOops enabled, and the Java Heap may be blocking the growth of the native heap
# Possible solutions:
#   Reduce memory load on the system
#   Increase physical memory or swap space
#   Check if swap backing store is full
#   Decrease Java heap size (-Xmx/-Xms)
#   Decrease number of Java threads
#   Decrease Java thread stack sizes (-Xss)
#   Set larger code cache with -XX:ReservedCodeCacheSize=
#   JVM is running with Unscaled Compressed Oops mode in which the Java heap is
#     placed in the first 4GB address space. The Java Heap base address is the
#     maximum limit for the native heap growth. Please use -XX:HeapBaseMinAddress
#     to set the Java Heap base and to place the Java Heap above 4GB virtual address.
# This output file may be truncated or incomplete.
#
#  Out of Memory Error (workerManager.hpp:87), pid=6, tid=6
#
# JRE version:  (17.0.4.1+1) (build )
# Java VM: OpenJDK 64-Bit Server VM (17.0.4.1+1, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, g1 gc, linux-amd64)
# Core dump will be written. Default location: Core dumps may be processed with "/usr/share/apport/apport -p%p -s%s -c%c -d%d -P%P -u%u -g%g -- %E" (or dumping to /app/core.6)
#

---------------  S U M M A R Y ------------

Command Line: -Xmx64m -Xms64m -Dorg.gradle.appname=gradlew org.gradle.wrapper.GradleWrapperMain shadowJar

Host: AMD Ryzen 5 2500U with Radeon Vega Mobile Gfx, 8 cores, 15G, Ubuntu 22.04.1 LTS
Time: Fri Sep 16 14:54:30 2022 UTC elapsed time: 0.006217 seconds (0d 0h 0m 0s)

---------------  T H R E A D  ---------------

Current thread (0x000055e87fcd6190):  JavaThread "Unknown thread" [_thread_in_vm, id=6, stack(0x00007ffc3da6c000,0x00007ffc3e26c000)]

Stack: [0x00007ffc3da6c000,0x00007ffc3e26c000],  sp=0x00007ffc3e266af0,  free space=8170k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V  [libjvm.so+0xed8f51]  VMError::report_and_die(int, char const*, char const*, __va_list_tag*, Thread*, unsigned char*, void*, void*, char const*, int, unsigned long)+0x1a1
V  [libjvm.so+0xed9b1d]  VMError::report_and_die(Thread*, char const*, int, unsigned long, VMErrorType, char const*, __va_list_tag*)+0x2d
V  [libjvm.so+0x603823]  report_vm_out_of_memory(char const*, int, unsigned long, VMErrorType, char const*, ...)+0xc3
V  [libjvm.so+0xf0d14f]  WorkerManager::add_workers(WorkGang*, unsigned int, unsigned int, unsigned int, os::ThreadType, bool)+0x18f
V  [libjvm.so+0xf0d2ea]  WorkGang::initialize_workers()+0x4a
V  [libjvm.so+0x6e98c1]  G1CollectedHeap::initialize()+0x6c1
V  [libjvm.so+0xe87502]  universe_init()+0xd2
V  [libjvm.so+0x7f5bd7]  init_globals()+0x37
V  [libjvm.so+0xe5e6f0]  Threads::create_vm(JavaVMInitArgs*, bool*)+0x3a0
V  [libjvm.so+0x8b3122]  JNI_CreateJavaVM+0x52
C  [libjli.so+0x4a1f]  JavaMain+0x8f
C  [libjli.so+0x9a90]  CallJavaMainInNewThread+0xb0
C  [libjli.so+0x6a0d]  ContinueInNewThread+0x5d
C  [libjli.so+0x8166]  JLI_Launch+0x1566
C  [java+0x1203]  main+0x123


---------------  P R O C E S S  ---------------

Threads class SMR info:
_java_thread_list=0x00007f20277943a0, length=0, elements={
}

Java Threads: ( => current thread )

Other Threads:

[error occurred during error reporting (printing all threads), id 0xb, SIGSEGV (0xb) at pc=0x00007f2026b580b0]

VM state: not at safepoint (not fully initialized)

VM Mutex/Monitor currently owned by a thread:  ([mutex/lock_event])
[0x000055e87fcd3b80] Heap_lock - owner thread: 0x000055e87fcd6190

Heap address: 0x00000000fc000000, size: 64 MB, Compressed Oops mode: 32-bit

CDS archive(s) mapped at: [0x0000000000000000-0x0000000000000000-0x0000000000000000), size 0, SharedBaseAddress: 0x0000000800000000, ArchiveRelocationMode: 0.
Narrow klass base: 0x0000000000000000, Narrow klass shift: 0, Narrow klass range: 0x0

GC Precious Log:
<Empty>

Heap:
 garbage-first heap   total 0K, used 0K [0x00000000fc000000, 0x0000000100000000)
  region size 1024K, 0 young (0K), 0 survivors (0K)

[error occurred during error reporting (printing heap information), id 0xb, SIGSEGV (0xb) at pc=0x00007f2027119a0a]

GC Heap History (0 events):
No events

Deoptimization events (0 events):
No events

Classes unloaded (0 events):
No events

Classes redefined (0 events):
No events

Internal exceptions (0 events):
No events

VM Operations (0 events):
No events

Events (2 events):
Event: 0.003 Protecting memory [0x00007ffc3da6c000,0x00007ffc3da70000] with protection modes 0
Event: 0.004 Loaded shared library /opt/java/openjdk/lib/libjava.so


Dynamic libraries:
fc000000-100000000 ---p 00000000 00:00 0
55e87f0aa000-55e87f0ab000 r--p 00000000 00:a3 659778                     /opt/java/openjdk/bin/java
55e87f0ab000-55e87f0ac000 r-xp 00001000 00:a3 659778                     /opt/java/openjdk/bin/java
55e87f0ac000-55e87f0ad000 r--p 00002000 00:a3 659778                     /opt/java/openjdk/bin/java
55e87f0ad000-55e87f0ae000 r--p 00002000 00:a3 659778                     /opt/java/openjdk/bin/java
55e87f0ae000-55e87f0af000 rw-p 00003000 00:a3 659778                     /opt/java/openjdk/bin/java
55e87fc9c000-55e87fd09000 rw-p 00000000 00:00 0                          [heap]
7f200e564000-7f200e94f000 rw-p 00000000 00:00 0
7f200e94f000-7f200e950000 ---p 00000000 00:00 0
7f200e950000-7f200ea56000 rw-p 00000000 00:00 0
7f200ea56000-7f200ecb6000 ---p 00000000 00:00 0
7f200ecb6000-7f200f4c3000 rw-p 00000000 00:00 0
7f200f4c3000-7f200f5a9000 ---p 00000000 00:00 0
7f200f5a9000-7f200f5ae000 rw-p 00000000 00:00 0
7f200f5ae000-7f200f694000 ---p 00000000 00:00 0
7f200f694000-7f200f699000 rw-p 00000000 00:00 0
7f200f699000-7f200f6a0000 ---p 00000000 00:00 0
7f200f6a0000-7f200f910000 rwxp 00000000 00:00 0
7f200f910000-7f200fc32000 ---p 00000000 00:00 0
7f200fc32000-7f200fea2000 rwxp 00000000 00:00 0
7f200fea2000-7f2017169000 ---p 00000000 00:00 0
7f2017169000-7f20173d9000 rwxp 00000000 00:00 0
7f20173d9000-7f201e6a0000 ---p 00000000 00:00 0
7f201e6a0000-7f201e6ad000 r--p 00000000 00:a3 659505                     /opt/java/openjdk/lib/libjava.so
7f201e6ad000-7f201e6bf000 r-xp 0000d000 00:a3 659505                     /opt/java/openjdk/lib/libjava.so
7f201e6bf000-7f201e6c5000 r--p 0001f000 00:a3 659505                     /opt/java/openjdk/lib/libjava.so
7f201e6c5000-7f201e6c6000 ---p 00025000 00:a3 659505                     /opt/java/openjdk/lib/libjava.so
7f201e6c6000-7f201e6c7000 r--p 00025000 00:a3 659505                     /opt/java/openjdk/lib/libjava.so
7f201e6c7000-7f201e6c8000 rw-p 00026000 00:a3 659505                     /opt/java/openjdk/lib/libjava.so
7f201e6c8000-7f201e6c9000 rw-p 00000000 00:00 0
7f201e6c9000-7f201e6d1000 rw-s 00000000 00:a3 660280                     /tmp/hsperfdata_root/6
7f201e6d1000-7f2026256000 r--s 00000000 00:a3 659529                     /opt/java/openjdk/lib/modules
7f2026256000-7f202625a000 r--p 00000000 00:a3 659509                     /opt/java/openjdk/lib/libjimage.so
7f202625a000-7f202626d000 r-xp 00004000 00:a3 659509                     /opt/java/openjdk/lib/libjimage.so
7f202626d000-7f2026273000 r--p 00017000 00:a3 659509                     /opt/java/openjdk/lib/libjimage.so
7f2026273000-7f2026275000 r--p 0001c000 00:a3 659509                     /opt/java/openjdk/lib/libjimage.so
7f2026275000-7f2026276000 rw-p 0001e000 00:a3 659509                     /opt/java/openjdk/lib/libjimage.so
7f2026276000-7f2026376000 rw-p 00000000 00:00 0
7f2026376000-7f2026384000 r--p 00000000 00:a3 525441                     /usr/lib/x86_64-linux-gnu/libm.so.6
7f2026384000-7f2026400000 r-xp 0000e000 00:a3 525441                     /usr/lib/x86_64-linux-gnu/libm.so.6
7f2026400000-7f202645b000 r--p 0008a000 00:a3 525441                     /usr/lib/x86_64-linux-gnu/libm.so.6
7f202645b000-7f202645c000 r--p 000e4000 00:a3 525441                     /usr/lib/x86_64-linux-gnu/libm.so.6
7f202645c000-7f202645d000 rw-p 000e5000 00:a3 525441                     /usr/lib/x86_64-linux-gnu/libm.so.6
7f202645d000-7f202645e000 r--p 00000000 00:a3 525486                     /usr/lib/x86_64-linux-gnu/librt.so.1
7f202645e000-7f202645f000 r-xp 00001000 00:a3 525486                     /usr/lib/x86_64-linux-gnu/librt.so.1
7f202645f000-7f2026460000 r--p 00002000 00:a3 525486                     /usr/lib/x86_64-linux-gnu/librt.so.1
7f2026460000-7f2026461000 r--p 00002000 00:a3 525486                     /usr/lib/x86_64-linux-gnu/librt.so.1
7f2026461000-7f2026462000 rw-p 00003000 00:a3 525486                     /usr/lib/x86_64-linux-gnu/librt.so.1
7f2026462000-7f20266b3000 r--p 00000000 00:a3 659541                     /opt/java/openjdk/lib/server/libjvm.so
7f20266b3000-7f20273cc000 r-xp 00251000 00:a3 659541                     /opt/java/openjdk/lib/server/libjvm.so
7f20273cc000-7f2027657000 r--p 00f6a000 00:a3 659541                     /opt/java/openjdk/lib/server/libjvm.so
7f2027657000-7f2027710000 r--p 011f4000 00:a3 659541                     /opt/java/openjdk/lib/server/libjvm.so
7f2027710000-7f2027745000 rw-p 012ad000 00:a3 659541                     /opt/java/openjdk/lib/server/libjvm.so
7f2027745000-7f20277a2000 rw-p 00000000 00:00 0
7f20277a2000-7f20277ca000 r--p 00000000 00:a3 525389                     /usr/lib/x86_64-linux-gnu/libc.so.6
7f20277ca000-7f202795f000 r-xp 00028000 00:a3 525389                     /usr/lib/x86_64-linux-gnu/libc.so.6
7f202795f000-7f20279b7000 r--p 001bd000 00:a3 525389                     /usr/lib/x86_64-linux-gnu/libc.so.6
7f20279b7000-7f20279bb000 r--p 00214000 00:a3 525389                     /usr/lib/x86_64-linux-gnu/libc.so.6
7f20279bb000-7f20279bd000 rw-p 00218000 00:a3 525389                     /usr/lib/x86_64-linux-gnu/libc.so.6
7f20279bd000-7f20279ca000 rw-p 00000000 00:00 0
7f20279ca000-7f20279cb000 r--p 00000000 00:a3 525403                     /usr/lib/x86_64-linux-gnu/libdl.so.2
7f20279cb000-7f20279cc000 r-xp 00001000 00:a3 525403                     /usr/lib/x86_64-linux-gnu/libdl.so.2
7f20279cc000-7f20279cd000 r--p 00002000 00:a3 525403                     /usr/lib/x86_64-linux-gnu/libdl.so.2
7f20279cd000-7f20279ce000 r--p 00002000 00:a3 525403                     /usr/lib/x86_64-linux-gnu/libdl.so.2
7f20279ce000-7f20279cf000 rw-p 00003000 00:a3 525403                     /usr/lib/x86_64-linux-gnu/libdl.so.2
7f20279cf000-7f20279d0000 r--p 00000000 00:a3 525484                     /usr/lib/x86_64-linux-gnu/libpthread.so.0
7f20279d0000-7f20279d1000 r-xp 00001000 00:a3 525484                     /usr/lib/x86_64-linux-gnu/libpthread.so.0
7f20279d1000-7f20279d2000 r--p 00002000 00:a3 525484                     /usr/lib/x86_64-linux-gnu/libpthread.so.0
7f20279d2000-7f20279d3000 r--p 00002000 00:a3 525484                     /usr/lib/x86_64-linux-gnu/libpthread.so.0
7f20279d3000-7f20279d4000 rw-p 00003000 00:a3 525484                     /usr/lib/x86_64-linux-gnu/libpthread.so.0
7f20279d4000-7f20279d7000 r--p 00000000 00:a3 659510                     /opt/java/openjdk/lib/libjli.so
7f20279d7000-7f20279e1000 r-xp 00003000 00:a3 659510                     /opt/java/openjdk/lib/libjli.so
7f20279e1000-7f20279e4000 r--p 0000d000 00:a3 659510                     /opt/java/openjdk/lib/libjli.so
7f20279e4000-7f20279e5000 ---p 00010000 00:a3 659510                     /opt/java/openjdk/lib/libjli.so
7f20279e5000-7f20279e6000 r--p 00010000 00:a3 659510                     /opt/java/openjdk/lib/libjli.so
7f20279e6000-7f20279e7000 rw-p 00011000 00:a3 659510                     /opt/java/openjdk/lib/libjli.so
7f20279e7000-7f20279e9000 r--p 00000000 00:a3 525520                     /usr/lib/x86_64-linux-gnu/libz.so.1.2.11
7f20279e9000-7f20279fa000 r-xp 00002000 00:a3 525520                     /usr/lib/x86_64-linux-gnu/libz.so.1.2.11
7f20279fa000-7f2027a00000 r--p 00013000 00:a3 525520                     /usr/lib/x86_64-linux-gnu/libz.so.1.2.11
7f2027a00000-7f2027a01000 ---p 00019000 00:a3 525520                     /usr/lib/x86_64-linux-gnu/libz.so.1.2.11
7f2027a01000-7f2027a02000 r--p 00019000 00:a3 525520                     /usr/lib/x86_64-linux-gnu/libz.so.1.2.11
7f2027a02000-7f2027a03000 rw-p 0001a000 00:a3 525520                     /usr/lib/x86_64-linux-gnu/libz.so.1.2.11
7f2027a04000-7f2027a05000 ---p 00000000 00:00 0
7f2027a05000-7f2027a06000 r--p 00000000 00:00 0
7f2027a06000-7f2027a08000 rw-p 00000000 00:00 0
7f2027a08000-7f2027a0a000 r--p 00000000 00:a3 525371                     /usr/lib/x86_64-linux-gnu/ld-linux-x86-64.so.2
7f2027a0a000-7f2027a34000 r-xp 00002000 00:a3 525371                     /usr/lib/x86_64-linux-gnu/ld-linux-x86-64.so.2
7f2027a34000-7f2027a3f000 r--p 0002c000 00:a3 525371                     /usr/lib/x86_64-linux-gnu/ld-linux-x86-64.so.2
7f2027a3f000-7f2027a40000 ---p 00000000 00:00 0
7f2027a40000-7f2027a42000 r--p 00037000 00:a3 525371                     /usr/lib/x86_64-linux-gnu/ld-linux-x86-64.so.2
7f2027a42000-7f2027a44000 rw-p 00039000 00:a3 525371                     /usr/lib/x86_64-linux-gnu/ld-linux-x86-64.so.2
7ffc3da6c000-7ffc3da70000 ---p 00000000 00:00 0
7ffc3e24b000-7ffc3e26c000 rw-p 00000000 00:00 0                          [stack]
7ffc3e34c000-7ffc3e34f000 r--p 00000000 00:00 0                          [vvar]
7ffc3e34f000-7ffc3e350000 r-xp 00000000 00:00 0                          [vdso]
ffffffffff600000-ffffffffff601000 --xp 00000000 00:00 0                  [vsyscall]


VM Arguments:
jvm_args: -Xmx64m -Xms64m -Dorg.gradle.appname=gradlew
java_command: org.gradle.wrapper.GradleWrapperMain shadowJar
java_class_path (initial): /app/gradle/wrapper/gradle-wrapper.jar
Launcher Type: SUN_STANDARD

[Global flags]
     intx CICompilerCount                          = 4                                         {product} {ergonomic}
     uint ConcGCThreads                            = 2                                         {product} {ergonomic}
     uint G1ConcRefinementThreads                  = 8                                         {product} {ergonomic}
   size_t G1HeapRegionSize                         = 1048576                                   {product} {ergonomic}
    uintx GCDrainStackTargetSize                   = 64                                        {product} {ergonomic}
   size_t InitialHeapSize                          = 67108864                                  {product} {command line}
   size_t MarkStackSize                            = 4194304                                   {product} {ergonomic}
   size_t MaxHeapSize                              = 67108864                                  {product} {command line}
   size_t MinHeapDeltaBytes                        = 1048576                                   {product} {ergonomic}
   size_t MinHeapSize                              = 67108864                                  {product} {command line}
    uintx NonNMethodCodeHeapSize                   = 5839372                                {pd product} {ergonomic}
    uintx NonProfiledCodeHeapSize                  = 122909434                              {pd product} {ergonomic}
    uintx ProfiledCodeHeapSize                     = 122909434                              {pd product} {ergonomic}
    uintx ReservedCodeCacheSize                    = 251658240                              {pd product} {ergonomic}
     bool SegmentedCodeCache                       = true                                      {product} {ergonomic}
   size_t SoftMaxHeapSize                          = 67108864                               {manageable} {ergonomic}
     bool UseCompressedClassPointers               = true                           {product lp64_product} {ergonomic}
     bool UseCompressedOops                        = true                           {product lp64_product} {ergonomic}
     bool UseG1GC                                  = true                                      {product} {ergonomic}

Logging:
Log output configuration:
 #0: stdout all=warning uptime,level,tags
 #1: stderr all=off uptime,level,tags

Environment Variables:
JAVA_HOME=/opt/java/openjdk
PATH=/opt/java/openjdk/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
LANG=en_US.UTF-8
LC_ALL=en_US.UTF-8

Signal Handlers:
   SIGSEGV: crash_handler in libjvm.so, mask=11100100010111111101111111111110, flags=SA_RESTART|SA_SIGINFO
    SIGBUS: crash_handler in libjvm.so, mask=11100100010111111101111111111110, flags=SA_RESTART|SA_SIGINFO
    SIGFPE: crash_handler in libjvm.so, mask=11100100010111111101111111111110, flags=SA_RESTART|SA_SIGINFO
   SIGPIPE: javaSignalHandler in libjvm.so, mask=11100100010111111101111111111110, flags=SA_RESTART|SA_SIGINFO
   SIGXFSZ: javaSignalHandler in libjvm.so, mask=11100100010111111101111111111110, flags=SA_RESTART|SA_SIGINFO
    SIGILL: crash_handler in libjvm.so, mask=11100100010111111101111111111110, flags=SA_RESTART|SA_SIGINFO
   SIGUSR2: SR_handler in libjvm.so, mask=00000000000000000000000000000000, flags=SA_RESTART|SA_SIGINFO
    SIGHUP: SIG_DFL, mask=00000000000000000000000000000000, flags=none
    SIGINT: SIG_DFL, mask=00000000000000000000000000000000, flags=none
   SIGTERM: SIG_DFL, mask=00000000000000000000000000000000, flags=none
   SIGQUIT: javaSignalHandler in libjvm.so, mask=11100100010111111101111111111110, flags=SA_RESTART|SA_SIGINFO
   SIGTRAP: crash_handler in libjvm.so, mask=11100100010111111101111111111110, flags=SA_RESTART|SA_SIGINFO


---------------  S Y S T E M  ---------------

OS:
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=22.04
DISTRIB_CODENAME=jammy
DISTRIB_DESCRIPTION="Ubuntu 22.04.1 LTS"
uname: Linux 5.4.0-121-generic #137-Ubuntu SMP Wed Jun 15 13:33:07 UTC 2022 x86_64
OS uptime: 74 days 20:58 hours
libc: glibc 2.35 NPTL 2.35
rlimit (soft/hard): STACK 8192k/infinity , CORE infinity/infinity , NPROC infinity/infinity , NOFILE 1048576/1048576 , AS infinity/infinity , CPU infinity/infinity , DATA infinity/infinity , FSIZE infinity/infinity , MEMLOCK 64k/64k
load average: 2.51 2.19 2.06

/proc/meminfo:
MemTotal:       16153272 kB
MemFree:          329124 kB
MemAvailable:   11130348 kB
Buffers:          944224 kB
Cached:          9740168 kB
SwapCached:       104396 kB
Active:          2543784 kB
Inactive:       10036860 kB
Active(anon):    1273612 kB
Inactive(anon):   550268 kB
Active(file):    1270172 kB
Inactive(file):  9486592 kB
Unevictable:       18492 kB
Mlocked:           18492 kB
SwapTotal:       4194300 kB
SwapFree:        3058428 kB
Dirty:             18760 kB
Writeback:             0 kB
AnonPages:       1904148 kB
Mapped:         10074252 kB
Shmem:              2780 kB
KReclaimable:     380428 kB
Slab:             628036 kB
SReclaimable:     380428 kB
SUnreclaim:       247608 kB
KernelStack:       15268 kB
PageTables:       203832 kB
NFS_Unstable:          0 kB
Bounce:                0 kB
WritebackTmp:          0 kB
CommitLimit:    12270936 kB
Committed_AS:   13122332 kB
VmallocTotal:   34359738367 kB
VmallocUsed:       45032 kB
VmallocChunk:          0 kB
Percpu:            69376 kB
HardwareCorrupted:     0 kB
AnonHugePages:     12288 kB
ShmemHugePages:        0 kB
ShmemPmdMapped:        0 kB
FileHugePages:         0 kB
FilePmdMapped:         0 kB
CmaTotal:              0 kB
CmaFree:               0 kB
HugePages_Total:       0
HugePages_Free:        0
HugePages_Rsvd:        0
HugePages_Surp:        0
Hugepagesize:       2048 kB
Hugetlb:               0 kB
DirectMap4k:     2295648 kB
DirectMap2M:    14174208 kB
DirectMap1G:     1048576 kB

/sys/kernel/mm/transparent_hugepage/enabled: always [madvise] never
/sys/kernel/mm/transparent_hugepage/defrag (defrag/compaction efforts parameter): always defer defer+madvise [madvise] never

Process Memory:
Virtual Size: 480864K (peak: 480884K)
Resident Set Size: 18172K (peak: 18172K) (anon: 5812K, file: 12360K, shmem: 0K)
Swapped out: 0K
C-Heap outstanding allocations: 12660K, retained: 131K
glibc malloc tunables: (default)

/proc/sys/kernel/threads-max (system-wide limit on the number of threads): 124979
/proc/sys/vm/max_map_count (maximum number of memory map areas a process may have): 65530
/proc/sys/kernel/pid_max (system-wide limit on number of process identifiers): 4194304

container (cgroup) information:
container_type: cgroupv1
cpu_cpuset_cpus: 0-7
cpu_memory_nodes: 0
active_processor_count: 8
cpu_quota: no quota
cpu_period: 100000
cpu_shares: no shares
memory_limit_in_bytes: unlimited
memory_and_swap_limit_in_bytes: not supported
memory_soft_limit_in_bytes: unlimited
memory_usage_in_bytes: 8832 k
memory_max_usage_in_bytes: 8832 k
maximum number of tasks: unlimited
current number of tasks: 2

Steal ticks since vm start: 0
Steal ticks percentage since vm start:  0.000

CPU: total 8 (initial active 8) (8 cores per cpu, 2 threads per core) family 23 model 17 stepping 0 microcode 0x810100b, cx8, cmov, fxsr, ht, mmx, 3dnowpref, sse, sse2, sse3, ssse3, sse4a, sse4.1, sse4.2, popcnt, lzcnt, tsc, tscinvbit, avx, avx2, aes, clmul, bmi1, bmi2, adx, sha, fma, vzeroupper, clflush, clflushopt
CPU Model and flags from /proc/cpuinfo:
model name      : AMD Ryzen 5 2500U with Radeon Vega Mobile Gfx
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm constant_tsc rep_good nopl nonstop_tsc cpuid extd_apicid aperfmperf pni pclmulqdq monitor ssse3 fma cx16 sse4_1 sse4_2 movbe popcnt aes xsave avx f16c rdrand lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw skinit wdt tce topoext perfctr_core perfctr_nb bpext perfctr_llc mwaitx cpb hw_pstate sme ssbd sev ibpb vmmcall fsgsbase bmi1 avx2 smep bmi2 rdseed adx smap clflushopt sha_ni xsaveopt xsavec xgetbv1 xsaves clzero irperf xsaveerptr arat npt lbrv svm_lock nrip_save tsc_scale vmcb_clean flushbyasid decodeassists pausefilter pfthreshold avic v_vmsave_vmload vgif overflow_recov succor smca

Online cpus: 0-7
Offline cpus: 8-15
BIOS frequency limitation: 2000000
Frequency switch latency (ns): 0
Available cpu frequencies: 2000000 1700000 1600000
Current governor: ondemand
Core performance/turbo boost: 1

Memory: 4k page, physical 16153272k(329124k free), swap 4194300k(3058428k free)
Page Sizes: 4k

vm_info: OpenJDK 64-Bit Server VM (17.0.4.1+1) for linux-amd64 JRE (17.0.4.1+1), built on Aug 12 2022 00:00:00 by "temurin" with gcc 10.3.0

END.
The command '/bin/sh -c ./gradlew shadowJar || cat /app/hs_err_*.log && die ":c"' returned a non-zero code: 127

Tried increasing "DEFAULT_JVM_OPTS" to "-Xmx512m -Xms512m" that didn't change anything

I tried building and running from the image on docker hub on an other system and it worked. On the minipc I've other images build in "linux/amd64" running that work. This is the first image I've got problems with.

Image tags tested

  • openj9 didn't boot
  • graalvm-jvm did boot
  • hotspot didn't boot but with "There is insufficient memory for the Java Runtime Environment to continue"

The cpu the machine is using

processor       : 0
vendor_id       : AuthenticAMD
cpu family      : 23
model           : 17
model name      : AMD Ryzen 5 2500U with Radeon Vega Mobile Gfx
stepping        : 0
microcode       : 0x810100b
cpu MHz         : 1505.366
cache size      : 512 KB
physical id     : 0
siblings        : 8
core id         : 0
cpu cores       : 4
apicid          : 0
initial apicid  : 0
fpu             : yes
fpu_exception   : yes
cpuid level     : 13
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm constant_tsc rep_good nopl nonstop_tsc cpuid extd_apicid aperfmperf pni pclmulqdq monitor ssse3 fma cx16 sse4_1 sse4_2 movbe popcnt aes xsave avx f16c rdrand lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw skinit wdt tce topoext perfctr_core perfctr_nb bpext perfctr_llc mwaitx cpb hw_pstate sme ssbd sev ibpb vmmcall fsgsbase bmi1 avx2 smep bmi2 rdseed adx smap clflushopt sha_ni xsaveopt xsavec xgetbv1 xsaves clzero irperf xsaveerptr arat npt lbrv svm_lock nrip_save tsc_scale vmcb_clean flushbyasid decodeassists pausefilter pfthreshold avic v_vmsave_vmload vgif overflow_recov succor smca
bugs            : sysret_ss_attrs null_seg spectre_v1 spectre_v2 spec_store_bypass
bogomips        : 3992.37
TLB size        : 2560 4K pages
clflush size    : 64
cache_alignment : 64
address sizes   : 43 bits physical, 48 bits virtual
power management: ts ttp tm hwpstate eff_freq_ro [13] [14]

Problem with Varnish container not being able to read default.vcl

I previously had Piped working but just moved to a new VPS and am running into a problem when I try to start up the containers with docker-compose. When I run docker-compose up I see the following error associated with the varnish container and that container keeps restarting.

varnish          | Error: Cannot read -f file '/etc/varnish/default.vcl' (Permission denied)
varnish          | (-? gives usage)

I've tried a variety of permissions for the ./config directory within my Piped-docker directory, including root:root, as well as making sure that the permissions are readable, but nothing seems to make any difference. Any idea what might be causing this? Thanks for the help!

Nginx cannot connect to pipedproxy

Hello,

I am trying to self host, I ran the configure-instance.sh and chose nginx, I use nginx proxy manager as the reverse proxy.
I followed all of the steps in the self host docs, my instance can show video titles but doesn't show thumbnails or play videos. I looked at the docker logs for the piped containers, they all look working, except the nginx logs which showed the error:

2024/06/21 04:01:05 [crit] 22#22: *53 connect() to unix:/var/run/ytproxy/actix.sock failed (13: Permission denied) while connecting to upstream,
client: 172.29.0.6, server: pipedproxy.example.org, request: "GET /sw.js HTTP/1.1", upstream: "http://unix:/var/run/ytproxy/actix.sock:/sw.js", host: "youtube.example.org"

All of the containers run on the same user so I don't understand why there are permission problems.

I kept all of the configuration files the same and I am running this on a nixos 23.11 server.

Can't get it to run with global caddy and nginx setup

Hello, thanks for the awesome project. I'm trying to run it locally. I ran the configure-instance.sh and chose nginx. I added those urls to my Caddyfile and that redirect appears to work (I have many other reverse_proxies that work fine). When I check the docker logs for the piped instances, they all look fine, but the nginx is giving this error:

2024/06/21 00:24:07 [emerg] 1#1: host not found in upstream "pipedfrontend:80" in /etc/nginx/conf.d/pipedfrontend.conf:2
nginx: [emerg] host not found in upstream "pipedfrontend:80" in /etc/nginx/conf.d/pipedfrontend.conf:2

I used the automatically generated compose file as below (with the pipedfrontend in nginx dependencies changed to piped-frontend so it'll work):

services:
    piped-frontend:
        image: 1337kavin/piped-frontend:latest
        restart: unless-stopped
        depends_on:
            - piped
        environment:
            BACKEND_HOSTNAME: pipedapi.test.info
        container_name: piped-frontend
    piped-proxy:
        image: 1337kavin/piped-proxy:latest
        restart: unless-stopped
        environment:
            - UDS=1
        volumes:
            - piped-proxy:/app/socket
        container_name: piped-proxy
    piped:
        image: 1337kavin/piped:latest
        restart: unless-stopped
        volumes:
            - ./config/config.properties:/app/config.properties:ro
        depends_on:
            - postgres
        container_name: piped-backend
    nginx:
        image: nginx:mainline-alpine
        restart: unless-stopped
        ports:
            - "9090:80"
        volumes:
            - ./config/nginx.conf:/etc/nginx/nginx.conf:ro
            - ./config/pipedapi.conf:/etc/nginx/conf.d/pipedapi.conf:ro
            - ./config/pipedproxy.conf:/etc/nginx/conf.d/pipedproxy.conf:ro
            - ./config/pipedfrontend.conf:/etc/nginx/conf.d/pipedfrontend.conf:ro
            - ./config/ytproxy.conf:/etc/nginx/snippets/ytproxy.conf:ro
            - piped-proxy:/var/run/ytproxy
        container_name: nginx
        depends_on:
            - piped
            - piped-proxy
            - piped-frontend
        labels:
            - "traefik.enable=true"
            - "traefik.http.routers.piped.rule=Host(`FRONTEND_HOSTNAME`, `BACKEND_HOSTNAME`, `PROXY_HOSTNAME`)"
            - "traefik.http.routers.piped.entrypoints=websecure"
            - "traefik.http.services.piped.loadbalancer.server.port=8080"
    postgres:
        image: postgres:15
        restart: unless-stopped
        volumes:
            - ./data/db:/var/lib/postgresql/data
        environment:
            - POSTGRES_DB=piped
            - POSTGRES_USER=piped
            - POSTGRES_PASSWORD=changeme
        container_name: postgres
    watchtower:
        image: containrrr/watchtower
        restart: always
        volumes:
            - /var/run/docker.sock:/var/run/docker.sock
            - /etc/timezone:/etc/timezone:ro
        environment:
            - WATCHTOWER_CLEANUP=true
            - WATCHTOWER_INCLUDE_RESTARTING=true
        container_name: watchtower
        command: piped-frontend piped-backend piped-proxy varnish nginx postgres watchtower
volumes:
    piped-proxy: null

I changed the 8080 to 9090 since I'm using something on 8080 already.
Am I missing something? I tried adding ports to each of the piped packages, but it was recommended to put the same port for each piped instance, and it says that that port is already in use when I do and won't start up.

I'm running it on Ubuntu 22.04.4 LTS x86_64.

Apache with `Docker-Compose Nginx AIO script` -- site issues.

The instructions under the heading Docker-Compose Nginx AIO script at https://piped-docs.kavin.rocks/docs/self-hosting/ say that all we need to do is set the DNS A records, run the docker, and pass the web traffic from all three hostnames to the nginx instance in the docker container.

I've done all this. I've copied the same configuration I have for multiple other web applications on different domains, but I cannot get Piped working. I'm getting a generic Index of / page when I navigate to piped.$host.

Here's my Apache httpd config:

<VirtualHost *:80>
    ErrorLog     /var/log/httpd/piped.http.info-error_log
    CustomLog    /var/log/httpd/piped.http.info-access_log common
    ServerName   piped.$host
    Redirect permanent / https://piped.$host/
</VirtualHost>
<VirtualHost *:80>
    ErrorLog     /var/log/httpd/piped.http.info-error_log
    CustomLog    /var/log/httpd/piped.http.info-access_log common
    ServerName   pipedapi.$host
    Redirect permanent / https://pipedapi.$host/
</VirtualHost>
<VirtualHost *:80>
    ErrorLog     /var/log/httpd/piped.http.info-error_log
    CustomLog    /var/log/httpd/piped.http.info-access_log common
    ServerName   pipedproxy.$host
    Redirect permanent / https://pipedproxy.$host/
</VirtualHost>
<VirtualHost *:443>
    ServerName   piped.$host
    ServerName   pipedapi.$host
    ServerName   pipedproxy.$host

    SSLEngine on
    SSLCertificateFile "/etc/letsencrypt/live/$host/fullchain.pem"
    SSLCertificateKeyFile "/etc/letsencrypt/live/$host/privkey.pem"

    RewriteEngine On
    
    ProxyRequests     Off
    ProxyPreserveHost On
    ProxyPass / http://127.0.0.1:8071/
    ProxyPassReverse / http://127.0.0.1:8071/
</VirtualHost>

And in the docker-compose file I have

nginx:
    image: nginx:mainline-alpine
    restart: unless-stopped
    ports:
        - "8071:80"

The output of docker-compose up doesn't print anything extra after

piped-backend   | Cleanup: Removed 0 old videos

even when accessing the page.

Output of docker ps:

CONTAINER ID   IMAGE                                COMMAND                  CREATED          STATUS                    PORTS                                                               NAMES
9159694d0413   nginx:mainline-alpine                "/docker-entrypoint.…"   52 seconds ago   Up 45 seconds             0.0.0.0:8071->80/tcp, :::8071->80/tcp                               nginx
10d08a5d0619   1337kavin/piped-frontend:latest      "ash -c 'sed -i s/pi…"   52 seconds ago   Up 47 seconds             80/tcp                                                              piped-frontend
8337cbe086ea   varnish:7.0-alpine                   "/usr/local/bin/dock…"   52 seconds ago   Up 47 seconds (healthy)   80/tcp, 8443/tcp                                                    varnish
0b7397f7a149   1337kavin/piped:latest               "/bin/sh -c 'java -s…"   52 seconds ago   Up 49 seconds             8080/tcp                                                            piped-backend
46e5b137583a   containrrr/watchtower                "/watchtower piped-f…"   52 seconds ago   Up 50 seconds             8080/tcp                                                            watchtower
4aabdf9cc485   1337kavin/ytproxy:latest             "/bin/sh -c ./http3-…"   52 seconds ago   Up 50 seconds                                                                                 ytproxy
1aa5a288744c   postgres:13-alpine                   "docker-entrypoint.s…"   52 seconds ago   Up 50 seconds             5432/tcp                                                            postgres

...confirming that the server is running and listening on port 8071 on the host.

Likewise, nmap tells me the port is open and listening:

[user@host Piped-Docker]$ nmap -p 8071 localhost
Starting Nmap 7.92 ( https://nmap.org ) at 2021-12-03 XX:XX XXXX
Nmap scan report for localhost (127.0.0.1)
Host is up (0.00011s latency).
Other addresses for localhost (not scanned): ::1

PORT     STATE SERVICE
8071/tcp open  unknown

Nmap done: 1 IP address (1 host up) scanned in 0.06 seconds

The hostname in the URL bar is definitely resolving to the right server. It's even rewriting http to https per the httpd config. But still it shows the generic Index of / page.

Is this a problem with Piped-Docker? Any ideas?

docker-compose check fails if you instead have docker compose

Using docker's repos on my Debian server, I have Docker version 20.10.17 with the compose plugin v2.6.0 (run using docker compose), instead of an actual docker-compose command. This causes this check to fail:

# Check if Docker-Compose is not installed
if [ -z "$(which docker-compose)" ]; then
echo "Docker-Compose is not installed. Please install it first from https://docs.docker.com/compose/install/#install-compose."
exit 1
fi

Commenting that check out is a workaround.

[Enhancement] Self hosted option - Docker Swarm with Traefik

Hey Team,

Came across this cool project last night and got a personal instance running using a Swarm with Traefik to link things together. Had to figure out a lot of the container relationships and configs, since the documentation and general project is still getting up to speed. (personally, I would love this project to gain more traction that Invidious as it has a ton of potential)

Below is the contents of the compose:

version: '3.8'

services:
  pipedfrontend:
    image: 1337kavin/piped-frontend:latest
    entrypoint: ash -c 'sed -i s/pipedapi.kavin.rocks/api.yourdomain.com/g /usr/share/nginx/html/js/* && /docker-entrypoint.sh && nginx -g "daemon off;"'
    networks:
      - traefik_public
    deploy:
      mode: global
      placement:
        constraints: [node.role == manager]
      labels:
        - "traefik.docker.network=traefik_public"
        - "traefik.http.services.piped-ui.loadbalancer.server.port=80"
        - "traefik.http.routers.piped-ui.entrypoints=https"
        - "traefik.http.routers.piped-ui.rule=Host(`frontend.yourdomain.com`)"

  piped:
    image: 1337kavin/piped:latest
    volumes:
      - ./Piped/config/config.properties:/app/config.properties:ro
    networks:
      - internal
    deploy:
      mode: global
      placement:
        constraints: [node.role == manager]

  nginx:
    image: nginx:mainline-alpine
    networks:
      - traefik_public
      - internal
    volumes:
      - ./Piped/config/nginx.conf:/etc/nginx/nginx.conf:ro
      - ./Piped/config/pipedproxy.conf:/etc/nginx/conf.d/pipedproxy.conf:ro
      - ./Piped/config/ytproxy.conf:/etc/nginx/snippets/ytproxy.conf:ro
      - ./Piped/ytproxy:/var/run/ytproxy
    deploy:
      mode: global
      placement:
        constraints: [node.role == manager]
      labels:
        - "traefik.docker.network=traefik_public"
        - "traefik.http.services.piped-proxy.loadbalancer.server.port=80"
        - "traefik.http.routers.piped-proxy.entrypoints=https"
        - "traefik.http.routers.piped-proxy.rule=Host(`proxy.yourdomain.com`)"

  ytproxy:
    image: 1337kavin/ytproxy:latest
    networks:
      - internal
    volumes:
      - ./Piped/ytproxy/:/app/socket/
    deploy:
      mode: global
      placement:
        constraints: [node.role == manager]

  varnish:
    image: varnish:7.0-alpine
    volumes:
      - ./Piped/config/default.vcl:/etc/varnish/default.vcl:ro
    networks:
      - traefik_public
      - internal
    deploy:
      mode: global
      placement:
        constraints: [node.role == manager]
      labels:
        - "traefik.docker.network=traefik_public"
        - "traefik.http.services.piped-api.loadbalancer.server.port=80"
        - "traefik.http.routers.piped-api.entrypoints=https"
        - "traefik.http.routers.piped-api.rule=Host(`api.yourdomain.com`)"

  postgres:
    image: postgres:13-alpine
    volumes:
      - ./Piped/db:/var/lib/postgresql/data
    networks:
      - internal
    environment:
      - POSTGRES_DB=piped
      - POSTGRES_USER=piped
      - POSTGRES_PASSWORD=changeme
    deploy:
      mode: global
      placement:
        constraints: [node.role == manager]

networks:
  traefik_public:
    external: true
  internal:
    driver: overlay
    ipam:
      config:
        - subnet: 172.16.25.0/24

Notes:

  • The traefik_public network is created external to this stack that serves as the ingest network, this may be different for other people.
  • Nginx is still used in this stack to serve the proxy, in the limited time I had I thought leaving this was the best option.
  • Additional changes were made to the config files in this repo's template folder.
    • config.properties - Changed host names and DB credentials.
    • pipedproxy.conf - Changed API host name.

I'm sure this all can be improved, but I thought it could serve as a good starting point for the multi-container architecture that has been chosen.

Hopefully this can help in some shape or form. Let me know how else I can help with the project.

How do I change ports?

Hi. Thanks for your work. I would want something like #6. Run it locally and use my own global reverse-proxy to make it available from the outside. I would also like to change ports in the configuration since I have other service on the server that uses the required ports.

Any tips would be appreciated. I'm a small bit more advanced than a newbie.

Add more GZIP options for nginx

GZIP in nginx requires further configuration than gzip on to properly work and have an impact on performance.

I suggest adding the following lines to the nginx config to compress assets more for faster loading:


        gzip_vary on;
        gzip_proxied any;
        gzip_comp_level 6;
        gzip_buffers 16 8k;
        gzip_http_version 1.1;
        gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
        # Specify the minimum length of the response to compress (default 20)
        gzip_min_length 500;

caddy port conflict (+ ipv6 only)

I have a service already running on port 443 and 80 on my host. but I also want to run piped. but, when I use the docker AIO script, caddy has an error because 443 is already in use.

The other service is nextcloud running as a snap on the local host and is assigned an IPv6 address.

I have allocated a different set IPv6 address for Piped and I want run piped in docker, but I dont know how to set up caddy to handle this situation. can anyone help me figure this out?

Basically, I have one IPv6 address for Nextcloud on the machine, and a secondary one I have assigned for Piped. how do I configure caddy/piped to use the secondary IP address so they do not conflict.

Also, I do NOT want to use IPv4. this machine does not have IPv4 access to the internet.

Calls to fonts.kavin.rocks

It's a little thing, but I was checking the network calls since I had some issues and noticed that some stuff it's loaded from ther

GET /s/materialiconsround/v65/LDItaoyNOAY6Uewc665JcIzCKsKc_M9flwmM.otf HTTP/3
Host: fonts.kavin.rocks
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Firefox/91.0
Accept: application/font-woff2;q=1.0,application/font-woff;q=0.9,*/*;q=0.8
Accept-Language: en-US;q=0.5,en;q=0.3
Accept-Encoding: gzip, deflate, br
Origin: https://myserver.com
Connection: keep-alive
Referer: https://myserver.com
Sec-Fetch-Dest: font
Sec-Fetch-Mode: cors
Sec-Fetch-Site: cross-site
DNT: 1
Sec-GPC: 1
Pragma: no-cache
Cache-Control: no-cache

I get two calls, for /s/materialiconsround/v65/LDItaoyNOAY6Uewc665JcIzCKsKc_M9flwmM.otf and /s/roboto/v27/KFOmCnqEu92Fr1Mu4mxP.ttf

fix self-host documents script generated docker-compose.yaml file content.

Official Instance

Describe the bug

After running configure-instance.sh, the docker-compose file generated via traefik labels has some problems:

  1. The nginx container label for traefik "traefik.http.services.piped.loadbalancer.server.port=8080" uses wrong port. it should be 80.
  2. should clearly explain in documents, if user want to use an existing reverse proxy, the current compose file is correct, the user can just edit his configuration, reverse the localhost:8080. but traefik label only work when in the same docker network with nginx, and if user want to append a traefik container at the end of the compose file, the nginx container should not map ports.
  3. current:
    nginx:
        image: nginx:mainline-alpine
        restart: unless-stopped
        ports:
            - "8080:80"
        volumes:
            - ./config/nginx.conf:/etc/nginx/nginx.conf:ro
            - ./config/pipedapi.conf:/etc/nginx/conf.d/pipedapi.conf:ro
            - ./config/pipedproxy.conf:/etc/nginx/conf.d/pipedproxy.conf:ro
            - ./config/pipedfrontend.conf:/etc/nginx/conf.d/pipedfrontend.conf:ro
            - ./config/ytproxy.conf:/etc/nginx/snippets/ytproxy.conf:ro
            - piped-proxy:/var/run/ytproxy
        container_name: nginx
        depends_on:
            - piped
            - piped-proxy
            - pipedfrontend
        labels:
            - "traefik.enable=true"
            - "traefik.http.routers.piped.rule=Host(``)"
            - "traefik.http.routers.piped.entrypoints="
            - "traefik.http.services.piped.loadbalancer.server.port=8080"

changed:

    nginx:
        image: nginx:mainline-alpine
        restart: unless-stopped
        # ports:
        #     - "8080:80"
        volumes:
            - ./config/nginx.conf:/etc/nginx/nginx.conf:ro
            - ./config/pipedapi.conf:/etc/nginx/conf.d/pipedapi.conf:ro
            - ./config/pipedproxy.conf:/etc/nginx/conf.d/pipedproxy.conf:ro
            - ./config/pipedfrontend.conf:/etc/nginx/conf.d/pipedfrontend.conf:ro
            - ./config/ytproxy.conf:/etc/nginx/snippets/ytproxy.conf:ro
            - piped-proxy:/var/run/ytproxy
        container_name: nginx
        depends_on:
            - piped
            - piped-proxy
            - pipedfrontend
        labels:
            - "traefik.enable=true"
            - "traefik.http.routers.piped.rule=Host(``)"
            - "traefik.http.routers.piped.entrypoints="
            - "traefik.http.services.piped.loadbalancer.server.port=80"
            - "traefik.http.routers.piped.tls.certresolver="

To Reproduce

  1. First, install git, docker, and the compose plugin for docker.

  2. Run git clone https://github.com/TeamPiped/Piped-Docker.

  3. Then, run cd Piped-Docker.

  4. Then, run ./configure-instance.sh and fill in the hostnames when asked. Choose nginx as the reverse proxy when asked.

  5. Now, create A (and AAAA) records to your server’s public IP with the hostnames you had filled in above.

  6. Append a traefik container at last of compose file like this one:

    traefik:
        image: traefik:latest
        ports:
            - "80:80"
            - "443:443"
        volumes:
        - ./traefik/:/etc/traefik/
        - /var/run/docker.sock:/var/run/docker.sock:ro
  1. Run docker compose up -d.
  2. And the traefik logs start appear ‘502 bad gatewat' , nginx:8080 refuse connect. because traefik labels use wrong port.

Expected behavior

the traefik should connect nginx correctly , and start reverse proxy traffic

Logs/Errors

piped-docker-traefik-1  | time="2023-12-09T09:35:51Z" level=debug msg="'502 Bad Gateway' caused by: dial tcp 172.20.0.8:8080: connect: connection refused"
piped-docker-traefik-1  | time="2023-12-09T09:35:52Z" level=debug msg="'502 Bad Gateway' caused by: dial tcp 172.20.0.8:8080: connect: connection refused"
piped-docker-traefik-1  | time="2023-12-09T09:38:03Z" level=debug msg="'502 Bad Gateway' caused by: dial tcp 172.20.0.8:8080: connect: connection refused"
piped-docker-traefik-1  | time="2023-12-09T09:38:04Z" level=debug msg="'502 Bad Gateway' caused by: dial tcp 172.20.0.8:8080: connect: connection refused"

Browser, and OS with Version.

chrome:latest
windows10 workstation:latest
docker-ce:latest

Additional context

No response

Nginx can't resolve hostname because of hardcoded dns resolver in nginx.conf

Currently a hard coded resolver address 127.0.0.11 is set in nginx.conf
It works in typical Docker setup, however it fails in setups using Podman with an explicit IPAM
It works with Docker, but fails with Podman where dns is 10.89.0.1 by default.

piped-nginx     | 2023/10/05 09:33:20 [error] 31#31: recv() failed (111: Connection refused) while resolving, resolver: 127.0.0.11:53
piped-nginx     | 2023/10/05 09:33:24 [error] 30#30: *1 piped could not be resolved (110: Operation timed out), client: 10.11.8.1, server: piped-api.example.com, request: "GET /channel/UCBR8-60-B28hp2BmDPdntcQ HTTP/1.1", host: "piped-api.example.com"

Referring to https://stackoverflow.com/a/31864024 , I removed resolver line in nginx.conf and used the following config as pipedapi.conf, which indeed fixed the issue.

proxy_cache_path /tmp/pipedapi_cache levels=1:2 keys_zone=pipedapi:4m max_size=2g inactive=60m use_temp_path=off;

upstream pipedapi {
    server piped:8080;
}
server {
    listen 80;
    server_name piped-api.example.com;

    location / {
        proxy_cache pipedapi;
        proxy_pass http://pipedapi;
        proxy_http_version 1.1;
        proxy_set_header Connection "keep-alive";
    }
}

problems registering and login

Hi,

Maybe I'm doing something wrong withe setup. But tried some things for a few hours now.

My host:
-- redacted --
Ubuntu 20.04.03 with nginx running on 80 + 443 with valid certs.

Steps:

  1. git clone
  2. ./configure-instance.sh with 3 A records+ nginx as proxy
  3. docker-compose up -d

Nginx config for this vhost:

server {

    listen 443 ssl http2;
    listen       [::]:443 ssl http2;

    server_name youtube.algra.io youtube-api.algra.io youtube-proxy.algra.io;

    index index.html index.htm;

    location / {proxy_pass http://127.0.0.1:8080; proxy_set_header Host $host; }
    ssl_certificate /etc/letsencrypt/live/youtube.algra.io/fullchain.pem;
    ssl_certificate_key /etc/letsencrypt/live/youtube.algra.io/privkey.pem;
    ssl_protocols TLSv1.3 TLSv1.2;
    ssl_ciphers EECDH+AESGCM:EECDH+AES256;
}

At first I had port 80 redirected to 443 for all these A-records. But I've also tried running it on both port 80 and 443. with the same config. (proxy_pass to docker 8080). The same result.

This works for the front-end. I can play clips etc. But registering or logging in ends in error:
afbeelding
When clicking "Register" button it displays a modal dialog "undefined".

Dockers logs:

piped-frontend   | 2022/02/11 17:13:16 [error] 10#10: *178 open() "/usr/share/nginx/html/register" failed (2: No such file or directory), client: 172.20.0.8, server: localhost, request: "GET /register HTTP/1.1", host: "pipedfrontend"
nginx            | 172.20.0.1 - - [11/Feb/2022:17:13:16 +0000] "GET /register HTTP/1.0" 200 2429 "-" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
piped-frontend   | 172.20.0.8 - - [11/Feb/2022:17:13:16 +0000] "GET /register HTTP/1.1" 200 2429 "-" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
piped-frontend   | 172.20.0.8 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/index.8b980bcf.js HTTP/1.1" 200 51721 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
nginx            | 172.20.0.1 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/index.8b980bcf.js HTTP/1.0" 200 51721 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
piped-frontend   | 172.20.0.8 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/index.52988dc5.css HTTP/1.1" 200 18194 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
nginx            | 172.20.0.1 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/index.52988dc5.css HTTP/1.0" 200 18194 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
piped-frontend   | 172.20.0.8 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/vendor.5a593439.js HTTP/1.1" 200 237575 "http://youtube.algra.io/assets/index.8b980bcf.js" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
nginx            | 172.20.0.1 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/vendor.5a593439.js HTTP/1.0" 200 237575 "http://youtube.algra.io/assets/index.8b980bcf.js" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
piped-frontend   | 172.20.0.8 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/vendor.5a593439.js HTTP/1.1" 200 237575 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
piped-frontend   | 172.20.0.8 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/registerServiceWorker.4adac1fc.js HTTP/1.1" 200 5698 "http://youtube.algra.io/assets/index.8b980bcf.js" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
nginx            | 172.20.0.1 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/registerServiceWorker.4adac1fc.js HTTP/1.0" 200 5698 "http://youtube.algra.io/assets/index.8b980bcf.js" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
nginx            | 172.20.0.1 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/vendor.5a593439.js HTTP/1.0" 200 237575 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
piped-frontend   | 172.20.0.8 - - [11/Feb/2022:17:13:17 +0000] "GET /img/icons/logo.svg HTTP/1.1" 200 6583 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
nginx            | 172.20.0.1 - - [11/Feb/2022:17:13:17 +0000] "GET /img/icons/logo.svg HTTP/1.0" 200 6583 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
piped-frontend   | 172.20.0.8 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/RegisterPage.622ada20.js HTTP/1.1" 200 1440 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
nginx            | 172.20.0.1 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/RegisterPage.622ada20.js HTTP/1.0" 200 1440 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
piped-frontend   | 172.20.0.8 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/RegisterPage.622ada20.js HTTP/1.1" 200 1440 "http://youtube.algra.io/assets/index.8b980bcf.js" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
nginx            | 172.20.0.1 - - [11/Feb/2022:17:13:17 +0000] "GET /assets/RegisterPage.622ada20.js HTTP/1.0" 200 1440 "http://youtube.algra.io/assets/index.8b980bcf.js" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
piped-frontend   | 172.20.0.8 - - [11/Feb/2022:17:13:17 +0000] "GET /favicon.ico HTTP/1.1" 200 33310 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"
nginx            | 172.20.0.1 - - [11/Feb/2022:17:13:17 +0000] "GET /favicon.ico HTTP/1.0" 200 33310 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"

Login has similar results:
piped-frontend | 2022/02/11 17:14:37 [error] 9#9: *188 open() "/usr/share/nginx/html/login" failed (2: No such file or directory), client: 172.20.0.8, server: localhost, request: "GET /login HTTP/1.1", host: "pipedfrontend"

Snippet from (my) nginx logs:

==> access.log <==
83.86.73.157 - - [11/Feb/2022:18:13:17 +0100] "GET /assets/RegisterPage.622ada20.js HTTP/1.1" 200 1440 "http://youtube.algra.io/register" "Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0" "-"

==> error.log <==
2022/02/11 18:15:17 [warn] 49552#49552: *355 an upstream response is buffered to a temporary file /var/cache/nginx/proxy_temp/8/00/0000000008 while reading upstream, client: 83.86.73.157, server: youtube.algra.io, request: "GET /assets/vendor.5a593439.js HTTP/1.1", upstream: "http://127.0.0.1:8080/assets/vendor.5a593439.js", host: "youtube.algra.io", referrer: "http://youtube.algra.io/assets/index.8b980bcf.js"

Am I missing a part of the configuration? I've got the feeling the last part of the https://piped-docs.kavin.rocks/docs/self-hosting/ page is kind of old, as most of this is covered by the configure-instance.sh script? Or am I mistaking?

Missing Shebang in configure script

The configure-instance.sh script doesn't include a shebang in the file. This results in the script failing in cases where it is not run with bash.

Can't run docker through VPN

Hello, love this so much. I got it working with very minor adjustments before, but I was hoping to run the proxy and backend behind a VPN (I have proton VPN). When I did this with gluetun I got an error on the backend saying Failed to get country even though I set the server city:

Failed to get country from YouTube!
org.postgresql.util.PSQLException: The connection attempt failed.
        at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:358)
        at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:54)
        at org.postgresql.jdbc.PgConnection.<init>(PgConnection.java:273)
        at org.postgresql.Driver.makeConnection(Driver.java:446)
        at org.postgresql.Driver.connect(Driver.java:298)
        at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:683)
        at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:230)
        at me.kavin.piped.utils.LiquibaseHelper.init(LiquibaseHelper.java:32)
        at me.kavin.piped.Main.main(Main.java:82)
Caused by: java.net.UnknownHostException: postgres
        at java.base/sun.nio.ch.NioSocketImpl.connect(NioSocketImpl.java:567)
        at java.base/java.net.SocksSocketImpl.connect(SocksSocketImpl.java:327)
        at java.base/java.net.Socket.connect(Socket.java:757)
        at org.postgresql.core.PGStream.createSocket(PGStream.java:243)
        at org.postgresql.core.PGStream.<init>(PGStream.java:98)
        at org.postgresql.core.v3.ConnectionFactoryImpl.tryConnect(ConnectionFactoryImpl.java:136)
        at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:262)

I'm pretty confident that the issue is with the network_mode to the gluetun instance, since when I remove it, it works fine.

(On a side note, I'm just wondering if there's a way to make an instance private or only allow specific log ins). Thanks!

Problem when running without HTTPS

I am trying to set up Piped to run inside of my own intranet/VPN. I want to run it on plain HTTP because the VPN has it's own encryption already and also I don't really want to mess with setting up a custom CA, installing the certs on all of my devices, etc.

I've managed to install Piped following the self-hosting manual for nginx. But it seems that the frontend has a problem connecting to the API:

161403927-45fd4aca-4c02-452c-b711-0acf9cc20e6e-border
161403939-e5d6cd5b-b3ae-408e-8e40-a018bead888b-border

So, the frontend is trying to access the API via HTTPS. This seems to be the main problem.

The API itself seems to work fine via HTTP if I access it manually:

161404102-dbd81f84-922e-4d6a-83c2-28b9d2927447-border

I've tried to change these variables in config/config.properties to use HTTP, without any luck.

PROXY_PART: http://pipedproxy.vpn
API_URL: http://pipedapi.vpn
FRONTEND_URL: http://piped.vpn

Maybe there's something else that I'm missing?

[Request] TrueNAS ready docker-compose

It would be nice to have a docker-compose file ready to use for TrueNAS for a easier setup. Otherwise I'm testing a way to make this work on TrueNAS. If I find a way I will share it.

Using other proxy instances

I'm a bit concerned about bandwidth use.

It seems technically possible1 to run just the frontend image without command to change the instance URLs. I'm assuming the proxy service will be the biggest bandwidth consumer.

Can we set up a piped backend service using a proxy of a public instance? (i.e., use pipedproxy-yyz.kavin.rocks as the URL for the PROXY_HOSTNAME value - this is what I saw in the network tab on the kavin.rocks instance)

My motivation is that I'd prefer to host the account/subscription data, etc for my private instance. But I'm not really fussed if another instance operator knows which videos have been watched.

Footnotes

  1. I've only tested to the point of running the 1337kavin/piped-frontend container locally and using entrypoint: ash -c '/docker-entrypoint.sh && nginx -g "daemon off;"' as the command. It seems to work as expected (not too surprising since it's a Vue app) and plays videos - I just haven't tested logging in yet

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.