Skip to content

Commit

Permalink
Init as sudo
Browse files Browse the repository at this point in the history
  • Loading branch information
fhammerl committed Sep 15, 2022
1 parent b4ebe66 commit f675120
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
]
}
},
"postCreateCommand": "/bin/bash /var/init.sh",
"postCreateCommand": "sudo /bin/bash /var/init.sh",
"waitFor": "postCreateCommand", // Will make extensions wait for restore (would have to manually restart omniSharp otherwise)
"remoteUser": "vscode"
}
3 changes: 2 additions & 1 deletion .devcontainer/first-run-notice.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
A self-hosted runner has been built in _layout and is ready to be configured.
A self-hosted runner has been built in '_layout' and is ready to be configured.

You can configure it for your repository or organisation by following these steps: https://docs.github.com/en/actions/hosting-your-own-runners/adding-self-hosted-runners#adding-a-self-hosted-runner-to-a-repository

If you'd like to make changes to the runner, check out docs/contribute.md for the details.

6 changes: 3 additions & 3 deletions .devcontainer/init.sh
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
#!/bin/bash

echo 'Creating symlink for embedded sdk...'

whoami
pwd
# pwd is the source root folder
rm -rf _dotnetsdk
mkdir _dotnetsdk
ln -s /usr/share/dotnet/sdk/6.0.300 _dotnetsdk/6.0.300

# Satisfy dev.sh SDK conditions
echo .6.0.300 > _dotnetsdk/.6.0.300
echo .6.0.300 > _dotnetsdk/6.0.300/.6.0.300
ln -s -f /usr/bin/dotnet /usr/share/dotnet/sdk/6.0.300/dotnet

rm -rf _layout
Expand Down

0 comments on commit f675120

Please sign in to comment.