mirror of
https://github.com/boostorg/build.git
synced 2026-01-19 04:02:14 +00:00
Use docker to run "su" to get the root access.
This commit is contained in:
@@ -1,7 +1,13 @@
|
||||
steps:
|
||||
- script: |
|
||||
su -c "apt-get -qq update && apt-get -qq install sudo"
|
||||
- task: CmdLine@2
|
||||
displayName: Install Sudo
|
||||
target: host
|
||||
inputs:
|
||||
script: |
|
||||
cid=`docker container ls -q`
|
||||
echo "ID = $cid"
|
||||
/usr/bin/docker exec $cid su -c "apt-get -y update && apt-get -qq install sudo"
|
||||
displayName: Install Sudo
|
||||
# - script: |
|
||||
# which docker
|
||||
# /tmp/docker exec -t -u root container mv /etc/sudoers /etc/sudoers.bak
|
||||
|
||||
Reference in New Issue
Block a user