Prnting PDF from fileshare without user interaction

I have written an application in PHP running on an Ubuntu server which generates PDF files. Now I need to print these documents on a local standard office printer immediatedly and without user interaction after generating these files.

The easiest way would be to save these PDF files to a local fileshare (or ftp server) and tell the printer to print all incoming documents from this fileshare and delete the files after successful printing.

Is this a builtin feature of todays printers or what do I need to make this work?

Can’t get directories inside root paths from fileshare in PowerShell

I am trying to get the names of files and directories that exist in the root path of a fileshare.

The following code:

$  List = Get-ChildItem -Path "\fileshare\files\" | Write-Output -InputObject $  List 

gives the files and directories of \fileserver\files\ as expected. But

$  List = Get-ChildItem -Path "\fileshare\*" | Write-Output -InputObject $  List 

results in a blank output. What is happening in PowerShell that is causing this issue?