Posts

Value

  Strategy    Strategic Management Journal California Management Review Harvard Business Review Sloan Management Review     Value Creation there are only two ways to consistently add and create value successfully:  either by becoming the low(est)-price champion (requiring continuous “cost innovation)”       your strategy should aim to continuously offer better value – better than before, and better than competitors. or  by focusing on superior customer value (aiming for high price, requiring continuous value innovation) As a principle it seems that we should be able to align our pricing as much and as closely as possible with the specific value bundle or value proposition we are offering. Value Capturing Capturing value means that you should be able to turn your value creation (as realized in a concrete value proposition) into a sustainable business, by means of what we usually call a “business model” Reference: Are You Creating or Capturing Value? A dynamic framework for sustainable s

overlay filesystem and containers

Containers A  container  is a process running on the host system.  This process is started by the container runtime from a container image, and the runtime provides a set of tools to manage the container process.  Namespaces virtualize the container process’s PID, network, root, and users.  Cgroups help set resource usage limits the container process can consume on the host system, and security contexts enforce permissions the container process has on the host system. A container, as a runtime object, consumes the typical resources any running process would consume on a system: storage for the file system and any saved configuration files, CPU, memory, and networking to serve traffic to/from external clients, and other containers or devices on the system. docker run container from image and connect it with shell , install necessary networking tools docker run -d -it ubuntu:22.10 bash docker run -d -it --privileged ubuntu:22.10 bash -> if you need to write to filesystem run wit priv

push detached head with git

 if you are in detached HEAD in local development and you want to push changes to remote repo git push origin HEAD:master

Pyppeteer fix for BrowserError: Browser closed unexpectedly

if you are having an error related with Pyppeteer   BrowserError: Browser closed unexpectedly   is just the error you get when Chrome crashes for whatever reason. It would be nice if pyppeteer printed out the error, but it doesn't. To track things down, it's helpful to pull up the exact command that pyppeteer runs. You can do that this way: from pyppeteer.launcher import Launcher ' '.join(Launcher().cmd) run output from command line and find missing libraries and install it.

PostgreSQL database backup with pg_dump by using .pgpass file

 It is better not to use password in commands so for taking backups from postgresql database we can store credentials in special file and give it to command so with this way it can be possible to run commands securely and password will be read from .pgpass file automatically /usr/bin/pg_dump -F c -h localhost -U yourdbuser yourdbname > /path_$(date '+%d%m%Y_%H%M%S').sql.zip cat /home/yourOSuser/.pgpass  localhost:5432:yourdbname:yourdbuser:yourdbuserpassword if order to make it work also do not forget to change connection method /var/lib/pgsql/14/data/pg_hba.conf file # "local" is for Unix domain socket connections only local   all         all    peer  ->>>> change this to md5 to login with user and restart your postgres database to reflect changes sudo service postgresql-14.service status how about restore PS: this is not regular zip file do not try to unzip this! create database first sudo -u postgres psql postgres=# create database yourdbname; postg

Django project and Perfect setup of nginx config for www to nonwww and http to https and ip to domain redirects

Here I am sharing good setup of nginx config for following requirements. before following config you need to create 2 A record for both domain to ip and www.domain to ip in your dns provider. also for django settings file you can add domain and www.domain to ALLOWED_HOSTS http to https www to nonwww https://ip to domain http://ip to domain redirects place following config to your sites-enabled config file server {   listen 80;   listen 443 ssl;   server_name yourserverip;   ssl_certificate /home/yourdomain.com.crt;   ssl_certificate_key /home/yourdomain.com.key;   add_header X-Frame-Options "SAMEORIGIN";   return 301 https://yourdomain.com$request_uri; } server {     listen 443 ssl;     server_name yourdomain.com;     ssl_certificate /home/yourdomain.com.crt;     ssl_certificate_key /home/yourdomain.com.key;     ssl_protocols TLSv1.2 TLSv1.1 TLSv1;     ssl_prefer_server_ciphers on;     ssl_ciphers "EECDH+ECDSA+AESGCM EECDH+aRSA+AESGCM EECDH+ECDSA+SHA384 EECDH+ECDSA+SHA25

Raspberry Pi wifi reconnect every 5 min

We enter this crontab entry and try to reconnect wifi every 5 mins */5 * * * * /home/sertac/wifi_reconnect.sh below you can find script content sertac@pz:~ $ cat /home/sertac/wifi_reconnect.sh ping -c2 8.8.8.8 > /dev/null if [ $? != 0 ]; then ifdown --force wlan0 sleep 5 ifup wlan0 sleep 10 systemctl restart ssh fi