Bug #47572
closedmgr/dashboard: stop Angular from pausing a non-interactive build
0%
Description
This was reported via IRC:
In a fresh development environment, e.g. inside a container, the dashboard build process stops with the following output:
> @angular/cli@10.0.5 postinstall /home/brad/working/src/ceph-fedora-32-brad/src/pybind/mgr/dashboard/frontend/node_modules/@angular/cli > node ./bin/postinstall/script.js ? Would you like to share anonymous usage data with the Angular Team at Google under Google’s Privacy Policy at https://policies.google.com/privacy? For more details and how to change this setting, see http://angular.io/analytics. No
According to the developer documentation there are several ways to suppress this message:
Setting an environment variable: export NG_CLI_ANALYTICS=ci
Disabling analytics via a command: ng analytics off
Adding a property to angular.json
:
"cli": { "analytics": false }
Updated by Brad Hubbard over 3 years ago
Let me know if I can provide further details and thanks.
Updated by Lenz Grimmer over 3 years ago
Brad Hubbard wrote:
Let me know if I can provide further details and thanks.
On what version of Ceph did you experience this behavior?
Updated by Brad Hubbard over 3 years ago
- Affected Versions v16.0.0 added
e15e825f85edf0e0f4eba7926e179e666607b8eb master
Updated by Brad Hubbard over 3 years ago
Try this.
git clean -fdx
git submodule foreach git clean -fdx
./do_cmake.sh
cd build
make mgr-dashboard-frontend-build
Updated by Brad Hubbard over 3 years ago
Hmmm... there's more to it than the previous comment. It has something to do with the user's cache.
Try this.
$ podman run -it --rm centos:latest # dnf -y install git # git clone http://github.com/ceph/ceph.git # cd ceph/ # ./install-deps.sh # ./do_cmake.sh # cd build/ # make mgr-dashboard-frontend-deps
You should see the anonymous usage prompt. Once you've seen it once it tends to disappear and be difficult to reproduce (something to do with ~/.config and/or ~/.npm*) so it's crucial to start with a "pristine" environment such as that provided by a container. This is one of the issue with storing state in users' home directories IMHO, it can have unforeseen consequences, but that's an issue for another tracker.
Updated by Brad Hubbard over 3 years ago
Ah, now I understand why I was seeing this so much as I was messing around with where these $HOME files were being stored.
In order to reproduce it's as simple as removing ~/.angular-config.json. Therefore, once ~/.angular-config.json is written once you won't see this.
# cat ~/.angular-config.json { "version": 1, "cli": { "analytics": false } }
Following on from the previous commands to reproduce just do the following.
# rm -f ~/.angular-config.json && cd .. && git clean -fdx;git submodule foreach git clean -fdx && mkdir build && cd $_ && cmake .. && make mgr-dashboard-frontend-deps
Updated by Brad Hubbard over 3 years ago
- Pull request ID set to 37325
- Affected Versions deleted (
v16.0.0)
Updated by Lenz Grimmer over 3 years ago
- Status changed from New to Fix Under Review
- Assignee set to Brad Hubbard
Updated by Kefu Chai over 3 years ago
- Status changed from Fix Under Review to Resolved
Updated by Ernesto Puerta about 3 years ago
- Project changed from mgr to Dashboard
- Category changed from 160 to Build, CI, Dependencies & Tools