Questions tagged [doas]
Use this tag with questions regarding the use or configuration of the doas utility, used for executing a command or shell as another user.
How to run a command in the background with 'doas'?
I want to run a command in the background as root. And I have a problem with doas command. With sudo, I can use sudo --background <command>. It will ask for password, then runs in the background....
Why doesn't this script succeed from crontab as it does when manually run?
This script works when executed with doas ./backup_cron_root.sh #!/usr/bin/bash /usr/bin/crontab -l> "/tmp/cron.$(whoami).$(hostname)" && /bin/date>>"/tmp/cron.$(...
Why doesn't doas wget -qO- archive.tar.gz|doas tar -xz work as with sudo?
sudo wget -qO- https://go.dev/dl/go1.20.1.linux-amd64.tar.gz|sudo tar -xz works fine. doas wget -qO- https://go.dev/dl/go1.20.1.linux-amd64.tar.gz|doas tar -xz does not work. I get no input, it just ...
How to install packages in chroot when chroot is launched with doas?
On OpenBSD 7.2 stable, I've setup my chroot using this script: #!/bin/ksh dir="/jails/$1" mkdir -p "$dir" tar -C "$dir" -xzf /usr/src/base/base72.tgz tar -C "$dir&...
How to make doas ask for root password
I want to configure doas so that it asks for root password, but not for normal user password. How do I do that?
doas doesn't run a /usr/sbin binary
I'm using Debian/GNU/Linux Unstable, and I was trying doas for the first time today, with the following simple config file: $ doas cat /etc/doas.conf permit persist alx as root While it worked for ...
Using "doas" with root password instead of user password
From my limited understanding, the doas utility allows you to run any command as root but, by default, requires you to enter your own password instead of the root user's password. How do I make it ...
Is there any way to prevent someone from running a shell as root?
This is a question I've pondered for a long time and thought was impossible. Is it possible to prevent administrators of a machine from bypassing the audit capabilities of sudo or doas? For instance, ...
Changing "doas" prompt
How may I change my doas prompt? For example, to change sudo prompt you just run export SUDO_PROMPT="Prompt: " Is there an equivalent for doas?
shutdown without password using doas
I want to be able to shutdown (or restart) my system without having to enter my password. My /etc/doas.conf looks like this and my user is in the wheel group permit nopass :wheel as root cmd /sbin/...
"doas" allow user to run command with other user and set environment variables
There are two normal users on my OpenBSD machine ("user" and "TESTUSER") and I have this doas config: # cat /etc/doas.conf ...
Why would root need to run unrestricted commands as itself via doas?
I've just come across doas, and while reading the man page for its configuration I found this example: The following example permits users in group wsrc to build ports; wheel to execute commands as ...