Closed Bug 1204516 Opened 5 years ago Closed 4 years ago
Can't run the task cluster commands locally due to ~/.tc-vcs not existing
I'm trying to run https://tools.taskcluster.net/task-graph-inspector/#KkKhYP_AS1OC91Mz4t1W7g/I-V64jDOQO2bGMuNNDm4sg/ locally: home/worker/tooltool-cache' taskcluster/desktop-build:0.1.3 /bin/bash 'bin/build.sh' # TODO: when bug 1093833 is solved and tasks can run as non-root, reduce this # to a simple fail-if-root check if [ $(id -u) = 0 ]; then # each of the caches we have mounted are owned by root, so update that ownership # to 'worker' for cache in /home/worker/.tc-vcs /home/worker/workspace /home/worker/tooltool-cache; do # -R probably isn't necessary forever, but it fixes some poisoned # caches for now chown -R worker:worker $cache done # ..then drop privileges by re-running this script exec su worker /home/worker/bin/build.sh fi ++ id -u + '[' 0 = 0 ']' + for cache in /home/worker/.tc-vcs /home/worker/workspace /home/worker/tooltool-cache + chown -R worker:worker /home/worker/.tc-vcs chown: cannot access `/home/worker/.tc-vcs': No such file or directory
This works locally for me if I change the build.sh file in the container, and allows to go to the next failure per bug 1230511 (tooltool). Does this still require to bump a version and to create a new image?
Attachment #8717779 - Flags: review?(dustin)
Comment on attachment 8717779 [details] [diff] [review] Ignore missing directories when changing ownership of cache directories in build.sh Good fix, thanks. Note, however, that running the container this way loses all caching, including vcs, so you'll have a long build time every run.
Attachment #8717779 - Flags: review?(dustin) → review+
Do I need to do something more than landing this patch?
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.