Wednesday, December 7, 2022

What are Bogon IP addresses

Some IP addresses and IP ranges are reserved for special use, such as for local or private networks, and should not appear on the public internet. These reserved ranges, along with other IP ranges that haven’t yet been allocated and therefore also shouldn’t appear on the public internet are sometimes known as bogons.


references:

https://ipinfo.io/10.254.4.185

Tuesday, December 6, 2022

How to view the docker image details

Below is step to do this.

docker image inspect [OPTIONS] IMAGE [IMAGE...]

references:

https://docs.docker.com/engine/reference/commandline/image_inspect/

Monday, December 5, 2022

How to write swagger documentation

This page gives a write to preview ui for quickly verifying the Swagger documentation 

https://editor.swagger.io/

references:

https://editor.swagger.io/

Sunday, December 4, 2022

Really good docker compose commands

To list all containers listed in docker compose file 


docker compose ps 


To get logs from all containers 


docker compose logs -f --tail 100 



To get events such as Start, kill etc from all cotnainers 


docker compose events


To list the images created by containers 


docker compose images


Below give an overall stats


docker compose ls


my-test-proj    restarting(2), running(26)



Below commands give filtered view 


docker compose ps | grep restarting

docker compose ps | grep exited

docker compose ps | grep running 

Saturday, December 3, 2022

What is Rosetta

Rosetta is not an app that you open or interact with. Rosetta works automatically in the background whenever you use an app that was built only for Mac computers with an Intel processor. It translates the app for use with Apple silicon.

In most cases, you won't notice any difference in the performance of an app that needs Rosetta. 


Which apps need Rosetta?

To identify apps that need Rosetta or can use Rosetta:


Select an app in the Finder.

From the File menu in the menu bar, choose Get Info.

See the information labeled Kind:

Application (Intel) means the app supports only Intel processors and needs Rosetta to work on a Mac with Apple silicon.

Application (Universal) means the app supports both Apple silicon and Intel processors, and uses Apple silicon by default. Universal apps don't need Rosetta.


For apps labeled Application (Universal), the Info window includes the setting “Open using Rosetta.” This setting enables a universal app such as a web browser to use plug-ins, extensions, or other add-ons that haven't been updated to support Apple silicon. If a universal app doesn't recognize an add-on that you installed for the app, you can quit the app, select this setting, and try again.


References:

https://support.apple.com/en-in/HT211861#:~:text=Rosetta%20works%20automatically%20in%20the,an%20app%20that%20needs%20Rosetta.


Why iOS Simulator shows Test mode - Google Ad

 Enable test devices (Test mode)

If you want to do more rigorous testing with production-looking ads, you can now configure your device as a test device and use your own ad unit IDs that you've created in the AdMob UI. Test devices can either be added in the AdMob UI or programmatically using the Google Mobile Ads SDK.

Follow the steps below to add your device as a test device.

Key Point: iOS simulators are automatically configured as test devices.

References:

developer.cisco.com/learning/lab/intro-netconf/step/2

`docker-compose up` times out with UnixHTTPConnectionPool


Some of the ways are: 


1. restart docker and set the below environment variables 

setting DOCKER_CLIENT_TIMEOUT and COMPOSE_HTTP_TIMEOUT environment variables:

it seems to be machine resource limitation. 

Something else my team did was to make a script that starts a batch of containers, waited for them to be healthy, and then started another batch of containers, and so on. That way the computer was not overwhelmed by all the operations that ran during startup.