Skip to content

Commit

Permalink
docker breaks the ownership
Browse files Browse the repository at this point in the history
  • Loading branch information
nickcharlton committed Nov 20, 2024
1 parent 4d13329 commit be030ce
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions bin/generate-database-schema
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ run_in_container() {
docker exec --workdir /app "$container_id" bash -c "$cmd"
}

owner=$(whoami)
# get ruby version from .ruby-version
ruby_version="3.2.2"

Expand All @@ -32,3 +33,6 @@ run_in_container "$container_id" "bundle exec rake db:setup"
echo "Tidying up container..."
docker stop "$container_id" > /dev/null
docker rm "$container_id" > /dev/null

echo "Restore file permissions..."
sudo chown -R "$owner" .

0 comments on commit be030ce

Please sign in to comment.