Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cannot create directory '/home/steam/Unturned/Modules': Permission denied #6

Open
creeloper27 opened this issue Sep 18, 2022 · 1 comment

Comments

@creeloper27
Copy link

creeloper27 commented Sep 18, 2022

When installing a new Unturned server using the command:
sudo docker run -it -v "$PWD":/home/steam/Unturned -p 27015:27015 -p 27016:27016 -e SERVER_TYPE=rm4 --restart unless-stopped --name myserverinstance imperialplugins/unturned -SkipAssets

This is what i get:

steamcmd.sh
linux32/steamcmd
linux32/steamerrorreporter
linux32/libstdc++.so.6
linux32/crashhandler.so
Redirecting stderr to '/home/steam/Steam/logs/stderr.txt'
ILocalize::AddFile() failed to load file "public/steambootstrapper_english.txt".
[  0%] Checking for available update...
[----] Downloading update (0 of 55263 KB)...
[  0%] Downloading update (2111 of 55263 KB)...
[  3%] Downloading update (4857 of 55263 KB)...
[  8%] Downloading update (7409 of 55263 KB)...
[ 13%] Downloading update (9537 of 55263 KB)...
[ 17%] Downloading update (11724 of 55263 KB)...
[ 21%] Downloading update (13673 of 55263 KB)...
[ 24%] Downloading update (15613 of 55263 KB)...
[ 28%] Downloading update (17776 of 55263 KB)...
[ 32%] Downloading update (19733 of 55263 KB)...
[ 35%] Downloading update (21732 of 55263 KB)...
[ 39%] Downloading update (23677 of 55263 KB)...
[ 42%] Downloading update (25667 of 55263 KB)...
[ 46%] Downloading update (27957 of 55263 KB)...
[ 50%] Downloading update (30042 of 55263 KB)...
[ 54%] Downloading update (32092 of 55263 KB)...
[ 58%] Downloading update (34169 of 55263 KB)...
[ 61%] Downloading update (36230 of 55263 KB)...
[ 65%] Downloading update (37202 of 55263 KB)...
[ 67%] Downloading update (38117 of 55263 KB)...
[ 68%] Downloading update (39150 of 55263 KB)...
[ 70%] Downloading update (40084 of 55263 KB)...
[ 72%] Downloading update (41026 of 55263 KB)...
[ 74%] Downloading update (42124 of 55263 KB)...
[ 76%] Downloading update (43088 of 55263 KB)...
[ 77%] Downloading update (44049 of 55263 KB)...
[ 79%] Downloading update (45049 of 55263 KB)...
[ 81%] Downloading update (45887 of 55263 KB)...
[ 83%] Downloading update (46973 of 55263 KB)...
[ 84%] Downloading update (47924 of 55263 KB)...
[ 86%] Downloading update (48877 of 55263 KB)...
[ 88%] Downloading update (49945 of 55263 KB)...
[ 90%] Downloading update (50905 of 55263 KB)...
[ 92%] Downloading update (51838 of 55263 KB)...
[ 93%] Downloading update (52833 of 55263 KB)...
[ 95%] Downloading update (53872 of 55263 KB)...
[ 97%] Downloading update (54830 of 55263 KB)...
[ 99%] Downloading update (55263 of 55263 KB)...
[100%] Download Complete.
[----] Applying update...
[----] Extracting package...
[----] Extracting package...
[----] Extracting package...
[----] Extracting package...
[----] Installing update...
[----] Installing update...
[----] Installing update...
[----] Installing update...
[----] Installing update...
[----] Installing update...
[----] Installing update...
[----] Installing update...
[----] Cleaning up...
[----] Update complete, launching...
WARNING: setlocale('en_US.UTF-8') failed, using locale: 'C'. International characters may not work.
Redirecting stderr to '/home/steam/Steam/logs/stderr.txt'
/tmp/dumps insufficient permissions - delete and recreate
[  0%] Checking for available updates...
[----] Verifying installation...
[  0%] Downloading update...
[  0%] Checking for available updates...
[----] Download complete.
[----] Extracting package...
[----] Extracting package...
[----] Extracting package...
[----] Extracting package...
[----] Installing update...
[----] Installing update...
[----] Installing update...
[----] Installing update...
[----] Installing update...
[----] Installing update...
[----] Installing update...
[----] Installing update...
[----] Cleaning up...
[----] Update complete, launching Steamcmd...
WARNING: setlocale('en_US.UTF-8') failed, using locale: 'C'. International characters may not work.
Redirecting stderr to '/home/steam/Steam/logs/stderr.txt'
[  0%] Checking for available updates...
[----] Verifying installation...
Steam Console Client (c) Valve Corporation - version 1660762488
-- type 'quit' to exit --
Loading Steam API...OK

Connecting anonymously to Steam Public...OK
Waiting for client config...OK
Waiting for user info...OK
�[33;1mPlease use force_install_dir before logon!
�[0m"@sSteamCmdForcePlatformBitness" = "64"
�[0m Update state (0x3) reconfiguring, progress: 0.00 (0 / 0)
 Update state (0x3) reconfiguring, progress: 0.00 (0 / 0)
 Update state (0x11) preallocating, progress: 75.90 (1290608692 / 1700324856)
 Update state (0x11) preallocating, progress: 75.94 (1291266626 / 1700324856)
 Update state (0x11) preallocating, progress: 76.22 (1296017230 / 1700324856)
 Update state (0x11) preallocating, progress: 99.76 (1696177286 / 1700324856)
 Update state (0x61) downloading, progress: 3.80 (64608852 / 1700324856)
 Update state (0x61) downloading, progress: 4.25 (72280836 / 1700324856)
 Update state (0x61) downloading, progress: 6.41 (108980996 / 1700324856)
 Update state (0x61) downloading, progress: 7.70 (131001092 / 1700324856)
 Update state (0x61) downloading, progress: 9.25 (157286177 / 1700324856)
 Update state (0x61) downloading, progress: 12.38 (210551989 / 1700324856)
 Update state (0x61) downloading, progress: 26.04 (442809529 / 1700324856)
 Update state (0x61) downloading, progress: 29.54 (502335384 / 1700324856)
 Update state (0x61) downloading, progress: 42.21 (717775967 / 1700324856)
 Update state (0x61) downloading, progress: 52.81 (897904060 / 1700324856)
 Update state (0x61) downloading, progress: 56.16 (954851384 / 1700324856)
 Update state (0x61) downloading, progress: 75.90 (1290465869 / 1700324856)
 Update state (0x61) downloading, progress: 75.92 (1290805406 / 1700324856)
 Update state (0x61) downloading, progress: 75.94 (1291222864 / 1700324856)
 Update state (0x61) downloading, progress: 75.96 (1291576252 / 1700324856)
 Update state (0x61) downloading, progress: 76.06 (1293265156 / 1700324856)
 Update state (0x61) downloading, progress: 77.21 (1312771524 / 1700324856)
 Update state (0x61) downloading, progress: 79.92 (1358960574 / 1700324856)
 Update state (0x61) downloading, progress: 83.00 (1411288988 / 1700324856)
 Update state (0x61) downloading, progress: 85.01 (1445371418 / 1700324856)
 Update state (0x61) downloading, progress: 87.77 (1492317328 / 1700324856)
 Update state (0x61) downloading, progress: 89.69 (1524952282 / 1700324856)
 Update state (0x61) downloading, progress: 92.24 (1568448931 / 1700324856)
 Update state (0x61) downloading, progress: 95.43 (1622595946 / 1700324856)
 Update state (0x61) downloading, progress: 98.20 (1669714907 / 1700324856)
 Update state (0x81) verifying update, progress: 7.57 (128694664 / 1700324856)
 Update state (0x81) verifying update, progress: 29.44 (500555660 / 1700324856)
 Update state (0x81) verifying update, progress: 51.09 (868771040 / 1700324856)
 Update state (0x81) verifying update, progress: 72.04 (1224851989 / 1700324856)
 Update state (0x81) verifying update, progress: 85.46 (1453079362 / 1700324856)
 Update state (0x81) verifying update, progress: 99.51 (1692048108 / 1700324856)
 Update state (0x101) committing, progress: 75.93 (1291100951 / 1700324856)
 Update state (0x101) committing, progress: 76.30 (1297403512 / 1700324856)
 Update state (0x0) unknown, progress: 0.00 (0 / 0)
Success! App '1110390' fully installed.
mkdir: cannot create directory '/home/steam/Unturned/Modules': Permission denied
./init.sh: line 15: cd: /home/steam/Unturned/Modules: No such file or directory
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
Archive:  Rocket.zip
  End-of-central-directory signature not found.  Either this file is not
  a zipfile, or it constitutes one disk of a multi-part archive.  In the
  latter case the central directory and zipfile comment will be found on
  the last disk(s) of this archive.
unzip:  cannot find zipfile directory in one of Rocket.zip or
        Rocket.zip.zip, and cannot find Rocket.zip.ZIP, period.
mv: cannot stat 'Modules/*': No such file or directory
rmdir: failed to remove 'Modules': No such file or directory
rm: cannot remove 'README': No such file or directory
./start_gameserver.sh: line 13: ./Unturned_Headless.x86_64: No such file or directory

am I doing something wrong or is this a bug?

@jasonbronson
Copy link

jasonbronson commented Nov 2, 2023

The problem is because your current directory is not writable by whatever user the docker engine is using. Just adjust the directory to allow it to be writable. A quick fix is to write your directory as everyone can write. This isn't safe long term for security but can be used quickly to test with. If your directory is "/unturned" then just try to "chmod 777 /unturned" this will open up anyone to write to it. If it works you can lookup which user is running for docker and adjust to only allow writing for that user.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants