Thursday, November 28, 2024

Photo Animation

 

Resources:

[1] AI Animation https://vivago.ai/video-generation

[2] Remove BG https://www.remove.bg/upload

 

Run python request over proxy

Code

import requests

proxies = {
   'http': 'http://72.10.160.172:9739',
}

url = 'https://httpbin.io/ip'
response = requests.get(url, proxies=proxies)
print(response.json())
 

 

 

References:

[1] https://www.zenrows.com/blog/python-requests-proxy#perform-requests

[2] https://free-proxy-list.net/

[3] https://stackoverflow.com/questions/57579359/use-python-sshtunnel-for-port-forwarding-rest-request

 

Friday, November 22, 2024

Ubuntu Forware port 80

 

#!/bin/bash
iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 8069
iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j REDIRECT --to-port 8070
iptables-save

 

Permanent in system by:

$sudo vi /etc/rc.local



References:

https://www.odoo.com/forum/help-1/change-to-port-80-instead-of-8069-23031

 

Wednesday, November 13, 2024

PostgreSQL json fields

select name->'es_PE',* from product_template where name->>'es_PE' like '%MEGACI%'

 

References:

[1] https://popsql.com/learn-sql/postgresql/how-to-query-a-json-column-in-postgresql

Ubuntu VGA Resolutions

 

References:

[1] https://pendrivelinux.com/vga-boot-modes-to-set-screen-resolution/

 

Ubuntu add user easily

 

 

$sudo adduser pharmaquipa
$sudo usermod -aG sudo pharmaquipa #add to sudo group

References

[1] https://www.digitalocean.com/community/tutorials/how-to-create-a-new-sudo-enabled-user-on-ubuntu

[2] https://phoenixnap.com/kb/how-to-create-sudo-user-on-ubuntu

Odoo 17 - Custom adds

    [1] Diario/Seq https://apps.odoo.com/apps/modules/17.0/sequence_for_journal