Friday, July 22, 2022

Fix a “WARNING/ERROR in budgets, maximum exceeded for initial” in Angular

The warning or an error can appear and be related to the maximum budgets parameter:

Error: bundle initial exceeded maximum budget. Budget 1.00 MB was not met by 22.68 kB with a total of 1.02 MB.

Should be tuned budgets module in the angular.json file of the Angular project

"budgets": [
                 {
                   "type": "initial",
                   "maximumWarning": "500kb",
                   "maximumError": "1mb"
                 },
                 {
                   "type": "anyComponentStyle",
                   "maximumWarning": "6kb",
                   "maximumError": "10kb"
                 }
               ]

"budgets": [
                 {
                   "type": "initial",
                   "maximumWarning": "2mb",
                   "maximumError": "5mb"
                 },
                 {
                   "type": "anyComponentStyle",
                   "maximumWarning": "6kb",
                   "maximumError": "10kb"
                 }
               ]

Monday, June 13, 2022

Update Bitrix24 on the Remote Desktop

 Check the running Bitrix24 on the tray

Click the right mouse button on the running Bitrix24 icon in the tray:

Open tree dots and click on “About” and Check for Updates:

if the installed version is the latest then the program exposes this:

in otherwise case, it proposes to download the new version.

Before installation log off all users on the server and Exit in the Bitrix24 of your running session on the server

After installation recheck the current version within “About”

Wednesday, May 18, 2022

Last users’ login data with PowerShell


Get-ADUser -Identity username -Properties "LastLogonDate"

output:

DistinguishedName : CN=SomeName,CN=SomeGroup,DC=DomainName,DC=local
Enabled           : True
GivenName         : AccountName
LastLogonDate     : 7/18/2022 7:48:24 PM
Name              : AccountName
ObjectClass       : user
ObjectGUID        : 2d348557-ff9b-4452-8f3b-96e820df570s
SamAccountName    : AccountName
SID               : S-1-5-21-453637392-373859473-1311905769-2573
Surname           :
UserPrincipalName : AccountName@DomainName.local

or it is the PowerShell command with filter:

Get-ADUser -Identity username -Properties LastLogon | Select Name, @{Name='LastLogon';Expression={[DateTime]::FromFileTime($_.LastLogon)}}

output:

Name  LastLogon
----  ---------
AccountName 7/18/2022 8:51:00 PM

Thursday, April 28, 2022

To check a Linux kernel

 Quick tutor on how to get data about Linux kernel

# uname -r
3.10.0–1062.el7.x86_64

# cat /proc/version
Linux version 3.10.0–1062.el7.x86_64 (mockbuild@x86–040.build.eng.bos.redhat.com) (gcc version 4.8.5 20150623 (Red Hat 4.8.5–39) (GCC) ) #1 SMP Thu Jul 18 20:25:13 UTC 2019

# hostnamectl | grep Kernel
Kernel: Linux 3.10.0–1062.el7.x86_64

Tuesday, April 12, 2022

screen Linux command

 This command is useful in cases where you need to leave some command in the running state, our command history is significantly important

Check if a system already running screens

screen -ls

Create/run a new screen console:

screen -S <screen-in-name>

Re-attach the screen:

screen -r <screen-in-name>

Kill screen session

screen -XS <screen-in-name> quit

useful links:
https://quickref.me/screen

Friday, March 25, 2022

Monday, December 13, 2021

add a user to the Docker group

 if you got an error like this:

$ docker run hello-world
docker: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post http://%2Fvar%2Frun%2Fdocker.sock/v1.39/containers/create: dial unix /var/run/docker.sock: connect: permission denied.

add a user to the Docker group then

$ sudo usermod -a -G docker $USER
$ mkdir “$HOME”/.docker
$ sudo chmod g+rwx “$HOME/.docker” -R
$ sudo chmod 666 /var/run/docker.sock

Add disk image to Windows OS on Proxmox

  1) Enter into the Proxmox console 2) Select the VM -> Hardware -> Add -> Hard Disk: 3) Configure the new disk image: 1. Select th...