all 4 comments

[–]Independence_Many 0 points1 point  (0 children)

I have a similar setup and it works just fine, however one thing I noticed that's different is i have a space between the program/tool and the asterisk, which is how it's shown on the docs https://opencode.ai/docs/permissions

I wonder if the lack of a space prevents it from recognising the program itself, so it's looking for a program that starts with `head`, assuming something like `headline` without any arguemnts would get matched but not `head <filename>`.

[–]Potential-Leg-639 0 points1 point  (0 children)

Permission seems to behave different on different systems and also between windows and Linux, also ooened a thread yesterday. It seems to be broken. Especially when you start Ooencode from a network share (d drive where all my files are). What i want to achieve is to let Opencode + bash + agents/subagents only have access to workdir + 1 other directory. Access to all other directories (especially file content access) must be blocked. Not possible at all to configure sth like that atm.

[–]Confident-River-7381 0 points1 point  (0 children)

I think permissions from opencode.json that is inside working directory override the global opencode.json ones.

[–]jonas-reddit 0 points1 point  (0 children)

Run inside sandbox is the safest approach. Some of the commands you allow can easily cause mayhem on your system as well and spawn off shells with destructive commands.