Páginas

sábado, 7 de diciembre de 2019

Sigan este canal, por favor

Sigan este canal, por favor:

https://m.youtube.com/channel/UCOmQKHnw9n126vfCOQc_F8w

viernes, 15 de noviembre de 2019

Compress MKV and MP4

Compress MKV (The same for MP4):

ffmpeg -i input.mkv -vf "scale=iw/2:ih/2" half_the_frame_size.mkv
ffmpeg -i input.mkv -vf "scale=iw/3:ih/3" a_third_the_frame_size.mkv
ffmpeg -i input.mkv -vf "scale=iw/4:ih/4" a_fourth_the_frame_size.mkv

sábado, 9 de noviembre de 2019

Inherit a class in Odoo 10, 11 and 12

Inherit a class in Odoo 10, 11 and 12:

Using this file as example:

https://github.com/odoo/odoo/blob/12.0/addons/mail/static/src/js/views/activity/activity_renderer.js

To inherit the class AbstractRenderer is like this:

odoo.define('mail.ActivityRendererInherited', function (require) {
"use strict";

var Abstract = require('mail.ActivityRenderer'); // name of the
                                                                              // Odoo define to inherit
var core = require('web.core');
var field_registry = require('web.field_registry');

var QWeb = core.qweb;
var _t = core._t;

var AbstractRenderer = Abstract.extend({
    /**
     * @private
     * @param {Object} data
     * @returns {jQueryElement} a <tr> element
     */
    function_name: function (data) {
       
    },
});

return {
    ActivityRenderer: ActivityRenderer
};

});

Servicio de Aplicaciones de Alta Velocidad para todas las zonas de Maracaibo (ó cualquier ciudad), por edificio ó comunidad

Si están interesados en este plan, se los dejo para que lo ojeen:

Servicio de Aplicaciones de Alta Velocidad para todas las zonas de Maracaibo (ó cualquier ciudad), por edificio ó comunidad

https://lnkd.in/eaZ_PQX

lunes, 28 de octubre de 2019

Intranet nacional en Venezuela

Intranet nacional en Venezuela!!.

Un Internet que incluya a todas las empresas a nivel nacional y que sólo lo administre Venezuela.

Esto hará más rápidas y seguras las comunicaciones.

Si hacemos esto, no sería necesaria la Internet internacional, para todos los casos.

Gana Ethereum

Gana ethereum:

https://t.me/DinoParkEthereumBot?start=42448708

jueves, 24 de octubre de 2019

IPTV con VLC

IPTV con VLC.

Esta es la lista de canales activos para ver con VLC, en Stream:

España:
Algunos no funcionan:
https://github.com/ruvelro/TV-Online-TDT-Spain

Listado funcionando 2019:
https://github.com/vk496/IPTVspain

A nivel mundial:
https://gist.github.com/nicolaslopezj/63187d1ecf215f58dfa2b38afcca11e9

Around the world:
https://raw.githubusercontent.com/iptv-org/iptv/master/index.m3u

Canales Latinos:

http://bit.ly/100canalesSPAIN
http://bit.ly/canaleslatinoss
http://bit.ly/tvypelisespanol
http://bit.ly/canalesvariadoss
http://bit.ly/paiseslatinos
http://bit.ly/LatinosCanals
http://bit.ly/RAG-TVlatinos
http://bit.ly/tvypelisespanol
http://bit.ly/TVyPeliss
http://bit.ly/espanolesIPTV
http://bit.ly/canalesfree1
http://bit.ly/SRRTVlatina

domingo, 13 de octubre de 2019

Minar Monero

Minar Monero:

Es un buen momento para minar Monero (XMR). Si tienes una buena PC ó Servidor, mucho mejor.

Usar Minergate, ayudar a minar más rápido.

Crea un cuenta en Minergate:

https://minergate.com

Descarga el Minergate-cli:

https://minergate.com/faq/how-minergate-console

Y luego, pon a minar.

minergate-cli -u correo@gmail.com --xmr 4 &

Con la App Móvil para Minergate, puedes ver todo funcionando.

Instalar repositorios inseguros en Debian

* Instalar repositorios inseguros en Debian:

Si un repositorio no está firmado, deberíamos usar esta opción. Esto podría acarrear que los paquetes no estén verificados y que funcionen, pero si estamos seguros de que los paquetes en realidad son seguros y que van a funcionar, podemos usar esta opción:

# apt-get update --allow-insecure-repositories

Amazon, Google y Facebook venezolanos

Las cosas por lo que la gente dice que USA es mejor, es porque allá hay un Amazon, un Google y un Facebook, que trabajan para USA.

Es por eso que necesitamos un Amazon, un Google y un Facebook venezolanos. Además de otras invenciones.

Necesitamos un Plan para Independizar y mejorar los servicios de Hosting, Software y Hardware en Venezuela.

Eso pasa por tener Fibra Óptica en toda Venezuela.

Renta Básica Universal

A cada ciudadano de Venezuela debería pagarsele una Renta Básica Universal incondicional, sólo por ser venezolano, lo que sería al menos un sueldo mínimo, así trabaje o no trabaje. Estamos protegiendo un Espacio-Tiempo de Venezuela y eso lo vale.

Renta Básica Universal es la Solución. Y debemos llevar los salarios a Precio Internacional.

Video referencial del experimento Finlandés:

https://youtu.be/ztzMNqrZhgc

En el caso de Venezuela se podría decir que son los bonos de la Patria, pero esto debería dársele a todos los ciudadanos y no al azar, como ahora.

sábado, 12 de octubre de 2019

Software necesario para crear una empresa y que no falte nada (sólo Software Libre y OpenSource)

Tengo 16 años en el ambiente de la Informática y 6 años desarrollando en OpenERP 7, Odoo 8, 9, 10, 11, 12 y 13, y como Consultor Senior. Estoy buscando StartUps que quieran llevar a su empresa a las nubes, yo los asesoro en hacer sus Sistemas.

Software necesario para crear una empresa y que no falte nada (sólo Software Libre y OpenSource):

Software especializado para crear granjas de servidores para distintos propósitos:

* OpenStack: Software para gestionar un Centro de Datos.
* Proxmox VE: Gestión de Máquinas Virtuales.
* GNU/Linux: Sistema Operativo donde instalar y configurar las aplicaciones que vayamos a usar. Entre los que están: CentOS, Debian, Ubuntu y RocksLinux.
* Dockers: Contenedores donde estarán las aplicaciones, ya pre configuradas, para ser usadas por usuarios y administradores.

Aplicaciones básicas para ofrecer:

* Odoo: Sistema de administración de empresas, instituciones, Framework de desarrollo e e-Commerce. https://dev-rockcesar.blogspot.com/2019/10/odoo-erp.html
* Mailu: Servidor de correos.
* Elastix: Servidor de VoIP.
* Wordpress: Blog para las instituciones.
* Gitlab: Servidor para versionado de documentos.
* MediaWiki: Wiki para las instituciones.
* OwnCloud: Servidor de documentos en la Nube.
* Diaspora: Servidor para redes sociales que hace frente a Facebook, a nivel internacional.
* PFSense: Firewall para servidores.

Odoo ERP

Las versiones de Odoo más utilizadas son (Actualizado Octubre 2019):

* Vieja API:

OpenERP7.

* Nueva API:

Odoo 8, Odoo 9, Odoo 10, Odoo 11, Odoo 12 y Odoo 13.

* Odoo 8 utiliza vieja y nueva API.

* OpenERP 7, Odoo 8, 9 y 10, utilizan Python 2.

* Odoo 11, 12 y 13, utilizan Python 3.

* Odoo es el mejor Sistema para llevar una Empresa, con vistas ERP, comprobado miles de veces. Tiene versión Privada y Libre. La versión privada la llevan Odoo S.A. y sus Partners, y la versión Libre, la llevan OCA, donde también está Odoo S.A., y algunos Partners de Odoo, además de la comunidad de Software Libre, ligada a Odoo.

* Puede manejar, Punto de Venta, Compras, Ventas, Proyectos, Contactos, Multiempresas, Multimonedas y mucho más. Está internacionalizado.

* Es por mucho, mejor que SAP, incluso en versión Libre.

Tengo 6 años desarrollando en OpenERP 7, Odoo 8, 9, 10, 11, 12 y 13, y como Consultor Senior. Estoy buscando StartUps que quieran llevar a su empresa a las nubes, yo los asesoro en hacer sus Sistemas.

Curso de Odoo:

https://dev-rockcesar.blogspot.com/2019/10/cursos-odoo.html

Cursos Odoo

* Publico un curso, que considero muy bueno, diseñado por mi, para entender cómo realizar un módulo desde cero (0):

https://drive.google.com/file/d/1faqCRqGmISt8CjcHixMwY0wmB_Nn03OO/view?usp=sharing

* Además de un curso en Udemy, que permite crear módulos, dictado por la mejor empresa de Odoo de Asia, SerpetCS. Viene con un Certificado firmado por Jay Vora y Udemy:

https://www.udemy.com/course/odoo-technical/

* Y para la parte funcional, pueden utilizar las herramientas de Odoo, que son las mejores:

https://www.odoo.com/es_ES/slides

Tengo 7 años desarrollando en OpenERP 7, Odoo 8, 9, 10, 11, 12 y 13, y como Consultor Senior.

Corrector ortográfico en PHP, JavaScript y Python

Corrector ortográfico en PHP y JavaScript:

Aunque la siguiente entrada, la escribí en el 2011, sigue siendo válido.

https://dev-rockcesar.blogspot.com/2011/10/corrector-ortografico-en-php-y.html

Corrector ortográfico en Python:

El otro corrector que presento, es pyspellchecker, y puede combinarse con Odoo, en cualquier versión, si se instala en Python 2 hasta Odoo 10, y en Python 3 desde Odoo 11 a Odoo 13.

https://pypi.org/project/pyspellchecker/

Recomendaciones de seguridad, para la Web

Recomendaciones de seguridad, para la Web.

* Usen GNU/Linux.

* Usen Tor.

* Generen claves random para las passwords:

# openssl rand -base64 32

* Apoyen el Software Libre.

miércoles, 9 de octubre de 2019

Bitcoin mining & Bitcoin Faucet

Bitcoin Faucet:



Bitcoin mining:

* Compra Hashrate. Te dan 100 GHS gratis. Click en la siguiente imagen:

https://www.virtualmining.farm/signup/?referrer=5D24E71499A2C

* Crea una Wallet en:

https://www.blockchain.com/es/wallet

* Compra Bitcoins en AirTM:


* Compra Hashrate en:

https://www.virtualmining.farm/signup/?referrer=5D24E71499A2C

Dependiendo de la cantidad de Hashrate, tendrás ganancias mensuales mejores.

Ya he cobrado, así que es real.

domingo, 8 de septiembre de 2019

Cambiar el Timezone en Debian 9 Stretch


Cambiar el Timezone en Debian 9 Stretch:

echo "America/Caracas" > /etc/timezone
ln -fs /usr/share/zoneinfo/America/Caracas /etc/localtime
dpkg-reconfigure -f noninteractive tzdata

Fuente:

https://www.illucit.com/en/linux/timezone-in-debian-9-stretch/

domingo, 25 de agosto de 2019

Prevent Files And Folders From Accidental Deletion Or Modification In Linux

Prevent Files And Folders From Accidental Deletion Or Modification In Linux
Prevent Files And Folders From Accidental Deletion Or Modification In Linux

Fuente: https://www.ostechnix.com/prevent-files-folders-accidental-deletion-modification-linux/

Some times, I accidentally “SHIFT+DELETE” my data. Yes, I am an idiot who don’t double check what I am exactly going to delete. And, I am too dumb or lazy to backup the data. Result? Data loss! They are gone in a fraction of second. I do it every now and then. If you’re anything like me, I’ve got a good news. There is a simple, yet useful commandline utility called “chattr” (abbreviation of Change Attribute) which can be used to prevent files and folders from accidental deletion or modification in Unix-like distributions. It applies/removes certain attributes to a file or folder in your Linux system. So nobody can delete or modify the files and folders either accidentally or intentionally, even as root user. Sounds useful, isn’t it? Indeed!
In this brief tutorial, we are going to see how to use chattr in real time in-order to prevent files and folders from accidental deletion in Linux.

Prevent Files And Folders From Accidental Deletion Or Modification In Linux

By default, Chattr is available in most modern Linux operating systems. Let us see some examples.
The default syntax of chattr command is:
chattr [operator] [switch] [filename]
chattr has the following operators.
  • The operator ‘+’ causes the selected attributes to be added to the existing attributes of the files;
  • The operator ‘-‘ causes them to be removed;
  • The operator ‘=’ causes them to be the only attributes that the files have.
Chattr has different attributes namely – aAcCdDeijsStTu. Each letter applies a particular attributes to a file.
  • a – append only,
  • A – no atime updates,
  • c – compressed,
  • C – no copy on write,
  • d – no dump,
  • D – synchronous directory updates,
  • e – extent format,
  • i – immutable,
  • j – data journalling,
  • P – project hierarchy,
  • s – secure deletion,
  • S – synchronous updates,
  • t – no tail-merging,
  • T – top of directory hierarchy,
  • u – undeletable.
In this tutorial, we are going to discuss the usage of two attributes, namely a, i which are used to prevent the deletion of files and folders. That’s what our topic today, isn’t? Indeed!

Prevent files from accidental deletion

Let me create a file called file.txt in my current directory.
$ touch file.txt
Now, I am going to apply “i” attribute which makes the file immutable. It means you can’t delete, modify the file, even if you’re the file owner and the root user.
$ sudo chattr +i file.txt
You can check the file attributes using command:
$ lsattr file.txt
Sample output:
----i---------e---- file.txt
Now, try to remove the file either as a normal user or with sudo privileges.
$ rm file.txt
Sample output:
rm: cannot remove 'file.txt': Operation not permitted
Let me try with sudo command:
$ sudo rm file.txt
Sample output:
rm: cannot remove 'file.txt': Operation not permitted
Let us try to append some contents in the text file.
$ echo 'Hello World!' >> file.txt
Sample output:
bash: file.txt: Operation not permitted
Try with sudo privilege:
$ sudo echo 'Hello World!' >> file.txt
Sample output:
bash: file.txt: Operation not permitted
As you noticed in the above outputs, We can’t delete or modify the file even as root user or the file owner.
To revoke attributes, just use “-i” switch as shown below.
$ sudo chattr -i file.txt
Now, the immutable attribute has been removed. You can now delete or modify the file.
$ rm file.txt
Similarly, you can restrict the directories from accidental deletion or modification as described in the next section.

Prevent folders from accidental deletion and modification

Create a directory called dir1 and a file called file.txt inside this directory.
$ mkdir dir1 && touch dir1/file.txt
Now, make this directory and its contents (file.txt) immutable using command:
$ sudo chattr -R +i dir1
Where,
  • -R – will make the dir1 and its contents immutable recursively.
  • +i – makes the directory immutable.
Now, try to delete the directory either as normal user or using sudo user.
$ rm -fr dir1
$ sudo rm -fr dir1
You will get the following output:
rm: cannot remove 'dir1/file.txt': Operation not permitted
Try to append some contents in the file using “echo” command. Did you make it? Of course, you couldn’t!
To revoke the attributes back, run:
$ sudo chattr -R -i dir1
Now, you can delete or modify the contents of this directory as usual.

Prevent files and folders from accidental deletion, but allow append operation

We know now how to prevent files and folders from accidental deletion and modification. Next, we are going to prevent files and folders from deletion, but allow the file for writing in append mode only. That means you can’t edit, modify the existing data in the file, rename the file, and delete the file. You can only open the file for writing in append mode.
To set append mode attribution to a file/directory, we do the following.
For files:
$ sudo chattr +a file.txt
For directories: 
$ sudo chattr -R +a dir1
A file/folder with the ‘a’ attribute set can only be open in append mode for writing.
Add some contents to the file(s) to check whether it works or not.
$ echo 'Hello World!' >> file.txt
$ echo 'Hello World!' >> dir1/file.txt
Check the file contents using cat command:
$ cat file.txt
$ cat dir1/file.txt
Sample output:
Hello World!
You will see that you can now be able to append the contents. It means we can modify the files and folders.
Let us try to delete the file or folder now.
$ rm file.txt
Output:
rm: cannot remove 'file.txt': Operation not permitted
Let us try to delete the folder:
$ rm -fr dir1/
Sample output:
rm: cannot remove 'dir1/file.txt': Operation not permitted
To remove the attributes, run the following commands:
For files:
$ sudo chattr -R -a file.txt
For directories: 
$ sudo chattr -R -a dir1/
Now, you can delete or modify the files and folders as usual.
For more details, refer the man pages.
man chattr

Wrapping up

Data protection is one of the main job of a System administrator. There are numerous free and commercial data protection software are available on the market. Luckily, we’ve got this built-in tool that helps us to protect the data from accidental deletion or modification. Chattr can be used as additional tool to protect the important system files and data in your Linux system.
And, that’s all for today. Hope this helps. I will be soon here with another useful article. Until then, stay tuned with OSTechNix!
Cheers!

miércoles, 3 de julio de 2019

Odoo Documentation - Documentación Odoo

Odoo Documentation.

Odoo User Documentation:

https://www.odoo.com/documentation/user/12.0/es/index.html

Odoo Administration Documentation:

https://www.odoo.com/documentation/12.0/index.html

Apps where you can upload the modules for Odoo:

https://www.odoo.com/apps

martes, 18 de junio de 2019

Reset the MySQL ROOT Password in Ubuntu 16.04

Reset the MySQL ROOT Password in Ubuntu 16.04 (Tested in ysql-server-5.7):
sudo /etc/init.d/mysql stop
sudo mkdir /var/run/mysqld/
sudo chown mysql /var/run/mysqld/
sudo mysqld_safe --skip-grant-tables &
sudo mysql -u root
use mysql;
update user set authentication_string=PASSWORD("New_Passwore_Here") where User='root';
flush privileges;
exit;
sudo /etc/init.d/mysql stop
sudo /etc/init.d/mysql start

miércoles, 5 de junio de 2019

A translator in Python using Tor Proxy - Un traductor en Python usando el Proxy de Tor

from py_translator import Translator
import sys

proxy = {
        'socks': 'socks://localhost:9050',
}
s = Translator(proxies=proxy).translate(text='Everything done', dest=sys.argv[2]).text
print(s)

Odoo module:

https://www.odoo.com/apps/modules/11.0/translator_odoo/

Repo:

https://github.com/rockcesar/odoo_addons/ 

miércoles, 13 de marzo de 2019

Buscar un valor específico en todas las tablas de la Base de Datos, con PostgreSQL

Buscar un valor específico en todas las tablas de la Base de Datos, con PostgreSQL:

CREATE OR REPLACE FUNCTION search_columns(
    needle text,
    haystack_tables name[] default '{}',
    haystack_schema name[] default '{}'
)
RETURNS table(schemaname text, tablename text, columnname text, rowctid text)
AS $$
begin
  FOR schemaname,tablename,columnname IN
      SELECT c.table_schema,c.table_name,c.column_name
      FROM information_schema.columns c
      JOIN information_schema.tables t ON
        (t.table_name=c.table_name AND t.table_schema=c.table_schema)
      WHERE (c.table_name=ANY(haystack_tables) OR haystack_tables='{}')
        AND (c.table_schema=ANY(haystack_schema) OR haystack_schema='{}')
        AND t.table_type='BASE TABLE'
  LOOP
    EXECUTE format('SELECT ctid FROM %I.%I WHERE cast(%I as text)=%L',
       schemaname,
       tablename,
       columnname,
       needle
    ) INTO rowctid;
    IF rowctid is not null THEN
      RETURN NEXT;l;
    END IF;
 END LOOP;
END;
$$ language plpgsql;

Luego ejecutar la consulta:

SELECT * FROM search_columns('value1');

lunes, 18 de febrero de 2019

Máquinas Virtuales en Linux. Alternativas para Virtualbox

Una vez de que sacaron a Virtualbox de los repositorios Debian, ahora estuve en búsqueda de las alternativas que hay en Linux, y me lleve una grata impresión. Podemos prescindir totalmente de Virtualbox. Recomiendo Gnome Boxes, Virtual Machine Manager y AQEMU, ya que todos ellos están en los repositorios Debian. Estoy experimentando con ellos:

Gnome Boxes: apt-get install gnome-boxes
Virtual Machine Manager: apt-get install virt-manager
AQEMU: apt-get install aqemu

https://www.addictivetips.com/ubuntu-linux-tips/best-virtualbox-alternatives-on-linux/