docker-code-server icon indicating copy to clipboard operation
docker-code-server copied to clipboard

[BUG] Permission Denied When Creating .git Folder

Open royaltongue opened this issue 1 year ago • 2 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Current Behavior

When trying to initialize a folder as a repository, I get the error /projects/docker-compose-files/.git: Permission denied

Expected Behavior

Git folder should be created and repository should be initalized.

Steps To Reproduce

  1. Open folder
  2. Try to initalize repository

Environment

- OS: OpenMediaVault 7.4.5-1 (Sandworm)
- How docker service was installed: OpenMediaVault-Compose plugin v. 7.2.4

CPU architecture

x86-64

Docker creation

code-server:
    container_name: code-server
    image: lscr.io/linuxserver/code-server:latest
    environment:
      - PUID=5063
      - PGID=1003
      - PASSWORD=${codeserverpassword}
      - SUDO_PASSWORD=${codeserversudopassword}
      - TZ=America/New_York
    volumes:
     - ${dcs}/code-server/workspaces:/workspaces
     - ${dcs}/code-server/projects:/projects
     - /srv/dev-disk-by-uuid-ca6f47d3-cd3d-4acc-bb5c-53a1d0eb27e5/docker/compose:/projects/docker-compose-files
     - ${dcs}/home_assistant/config:/projects/home-assistant
    hostname: code-server
    networks:
      - caddy_net
    restart: unless-stopped


### Container logs

```bash
───────────────────────────────────────
      ██╗     ███████╗██╗ ██████╗
      ██║     ██╔════╝██║██╔═══██╗
      ██║     ███████╗██║██║   ██║
      ██║     ╚════██║██║██║   ██║
      ███████╗███████║██║╚██████╔╝
      ╚══════╝╚══════╝╚═╝ ╚═════╝
   Brought to you by linuxserver.io
───────────────────────────────────────
To support LSIO projects visit:
https://www.linuxserver.io/donate/
───────────────────────────────────────
GID/UID
───────────────────────────────────────
User UID:    5063
User GID:    1003
───────────────────────────────────────
Linuxserver.io version: 4.92.2-ls232
Build-date: 2024-09-14T20:23:18+00:00
───────────────────────────────────────
    
setting up sudo access
setting sudo password using SUDO_PASSWORD env var
New password: Retype new password: passwd: password updated successfully
[custom-init] No custom files found, skipping...
[2024-09-20T01:31:52.264Z] info  code-server 4.92.2 de65bfc9477f61bc22d0b1a23085d1f18bb25202
[2024-09-20T01:31:52.278Z] info  Using user-data-dir /config/data
[2024-09-20T01:31:52.299Z] info  Using config file /config/.config/code-server/config.yaml
[2024-09-20T01:31:52.299Z] info  HTTP server listening on http://0.0.0.0:8443/
[2024-09-20T01:31:52.300Z] info    - Authentication is enabled
[2024-09-20T01:31:52.300Z] info      - Using password from $PASSWORD
[2024-09-20T01:31:52.301Z] info    - Not serving HTTPS
[2024-09-20T01:31:52.301Z] info  Session server listening on /config/data/code-server-ipc.sock
Connection to 127.0.0.1 8443 port [tcp/*] succeeded!
[ls.io-init] done.
[21:34:08] 
[21:34:08] Extension host agent started.
[21:34:09] [172.18.0.16][9f404533][ManagementConnection] New connection established.
File not found: /app/code-server/lib/vscode/out/vsda_bg.wasm
[21:34:10] [172.18.0.16][730479bd][ExtensionHostConnection] New connection established.
[21:34:10] [172.18.0.16][730479bd][ExtensionHostConnection] <628> Launched Extension Host Process.
[21:34:22] [172.18.0.16][dfd6bf5e][ManagementConnection] Unknown reconnection token (never seen).

royaltongue avatar Sep 20 '24 01:09 royaltongue

Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.

github-actions[bot] avatar Sep 20 '24 01:09 github-actions[bot]

Wasn't sure where to put this in the form, so here's extra information about users and permissions:

User 5063 is named vscodedocker and group 1003 is named dockergroup image

Folder .../docker/compose and everything contained is owned by root:dockergroup and has permissions set as 775 image image image

With this, I would expect any user within dockergroup to be able to read/write, but that's not happening here.

Just in case, I also rebooted the server after setting the permissions, but that did not solve the issue

royaltongue avatar Sep 20 '24 01:09 royaltongue

This issue has been automatically marked as stale because it has not had recent activity. This might be due to missing feedback from OP. It will be closed if no further activity occurs. Thank you for your contributions.

LinuxServer-CI avatar Oct 20 '24 02:10 LinuxServer-CI

This issue is locked due to inactivity

LinuxServer-CI avatar Jan 19 '25 02:01 LinuxServer-CI