Skip to content

Commit

Permalink
Run webassets build in Docker as current OS user (gravitational#20426)
Browse files Browse the repository at this point in the history
Set the current user when running webassets builds. In this way, the build artifacts will have correct permissions.
  • Loading branch information
jakule authored Jan 19, 2023
1 parent 7b7c4ad commit 8108230
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion build.assets/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -248,9 +248,10 @@ teleterm: buildbox-teleterm
docker run $(DOCKERFLAGS) $(NOROOT) $(BUILDBOX_TELETERM) \
bash -c "cd $(SRCDIR) && export CONNECT_TSH_BIN_PATH=\$$PWD/../teleport/build/tsh && yarn install --frozen-lockfile && yarn build-term && yarn package-term -c.extraMetadata.version=$(CONNECT_VERSION)"

# Builds webassets inside Docker.
.PHONY:ui
ui: buildbox
docker run -v "$$(pwd)/../":/teleport $(BUILDBOX) \
docker run -u $(UID):$(GID) -v "$$(pwd)/../":/teleport $(BUILDBOX) \
bash -c "cd ../teleport && yarn install --frozen-lockfile && yarn build-ui"

# grpc generates GRPC stubs from inside the buildbox
Expand Down

0 comments on commit 8108230

Please sign in to comment.