* Fix Docker entrypoint handling for non-root --user execution
This change updates the Docker entrypoint.sh to correctly support containers started with a numeric UID/GID via --user or user: (Docker Compose).
Previously, the entrypoint unconditionally attempted user and group management (useradd, groupadd, usermod) before checking whether the container was running as root. When the container was started as a non-root user, this resulted in immediate startup failures due to insufficient privileges.
The updated logic now:
* Detects whether the container is started as root or non-root
* Skips all user/group creation and ownership changes when running as non-root
* Treats --user / user: as authoritative when provided
* Preserves existing behaviour when the container is started as root (including optional privilege drop via gosu)
* Ensures ONEDRIVE_RUNAS_ROOT is only honoured when the container is actually running as root
This makes the container compatible with:
* Numeric UID/GID execution
* NFS-backed volumes where the user does not exist on the host
* Read-only bind mounts for upload-only scenarios
No changes are made to the OneDrive client itself; this update strictly improves container startup behaviour and correctness.
* Update Dockerfiles December 2025:
- Update to Fedora 43 and GO 1.23
- Update to Alpine 3.23 and GO 1.25
- Update to Debian 13 and support relevant time64 package changes
* Add Docker environment variable 'ONEDRIVE_THREADS' to control the value for the number of worker threads used for parallel upload and download operations.
* Revert back to v2.5.5 performSessionFileUpload() and apply minimal change for upload session offset handling to prevent desynchronisation on large files
* Add specific 403 handler for when the upload session URL itself expires
* Add 'file_fragment_size'
* Clean up debug logging output
* Add 'tempauth' to spelling words
* Update documentation URL's
* Ensure that on each fragment upload, whilst the application is using the 'tempauth' for session upload, the global OAuth2 token needs to be checked for validity and refreshed if required
* Add limit check for 'file_fragment_size' option
* Add to default 'config' file
* Update documentation for 'file_fragment_size'
* Add 'file_fragment_size' to --display-config output
* Add --file-fragment-size option to enable use via Docker option
* Add to manpage
* Update Docker entrypoint
* Update Docker | Podman documentation
* Update logging output to include connection method to URL
* Update Upload Session URL expiry update to include UTC and LocalTime values
* Update comment which was dropped / missed
* Clarify that this is the OAuth2 Access Token
* Clarify that the expiry timestamp is localTime
* Update PR with dynamic use of fragment size if fileSize > 100MiB
* Enforce multiple 320KiB for fragment size to align to Microsoft documentation
* Fix Docker entrypoint and confirm working for ONEDRIVE_FILE_FRAGMENT_SIZE
* Change 'defaultMaxFileFragmentSize' to 60
* Revise fragmentSize calculation to be as close to 60 MiB as possible without breaching Microsoft documented threshold
* Adds support for calling `acquireTokenInteractively` and `acquireTokenSilently` via D-Bus
* Parses and handles the full `brokerTokenResponse` object returned by the Intune broker
* Stores and reuses `account` data to enable silent token refresh without repeated interactive authentication
* Ensures the access token and its expiry time are properly calculated and stored for consistent token management
* Fallback to interactive authentication is triggered if silent authentication fails
* Update Dockerfile-alpine - revert to Alpine 3.19 due to LDC compiler (ldc (1.33.0-r0)) throwing a SIGINT on Alpine 3.20. The same compiler ldc (1.33.0-r0) has zero run-time issue on Alpine 3.19.
* Due to the significant issues with Debian and it's default version of 'curl' ensure that the Debian Docker image will update 'curl' from the relevant backports repository to avoid these issues
* Add --enable-debug to Docker files when building client application so that if the client crashes in any way, there is some meaningful crash data available to diagnose and assist in fixing the actual issue encountered.
* Add single directory sync to docker
---------
Co-authored-by: Hattum van <Nigel.van.Hattum@rabobank.nl>
Co-authored-by: abraunegg <alex.braunegg@gmail.com>
* Implement --display-running-config to display the running configuration as used at application startup
* Add ONEDRIVE_DISPLAY_CONFIG variable to control --display-running-config in Docker environments
* contrib: remove bash hashbang from completion
This file starts with the #! sequence that marks interpreted scripts, but
it is a bash completion script that is merely intended to be sourced.
* src: spelling error (Attemtping => Attempting)
* src: spelling error (reponse => response)
* src: spelling error (sucessfully => successfully)
* Update to dmd-2.088.0 and ldc-1.18.0
* Update documentation based on change in DMD and LDC minimum versions. Minimum DMD version now 2.088.0 and minimum LDC version now 1.18.0.
* Security upgrade alpine Docker file to 3.16
This issue relates to a build issue on the official docker build
system where Alpine Linux 3.14 will not currently build so fix
the Alpine version to 3.13.
Make sure build and runtime image used in building the docker
container are the same Alpine version to remove runtime issues.