🐍 Criando um servidor para o Jupyter Notebook

Crie uma nova configuração:

jupyter notebook --generate-config

No arquivo criado coloque essas duas linhas:

c.NotebookApp.allow_origin = '*' #allow all origi
c.NotebookApp.ip = '0.0.0.0' # listen on all 

E depois no terminal digite comando:

jupyter notebook --ip xx.xx.xx.xx --port 8888

Troque o xx.xx.xx.xx pelo ip da maquina.

Dica de Segurança:

Voce poderá colocar uma senha no seu Notebook digitando o comando abaixo:

c = get_config()
c.NotebookApp.password = u'sha1:6c2164fc2b22:ed55ecf07fc0f985ab46561483c0e888e8964ae6'

Voce poderá gerar sua própria senha sha1 com o seguinte código python:

from IPython.lib import passwd
password = passwd("secret")
password

Referencias:

[1] – https://testnb.readthedocs.io/en/stable/examples/Notebook/Configuring%20the%20Notebook%20and%20Server.html

[2] – https://testnb.readthedocs.io/en/stable/examples/Notebook/Configuring%20the%20Notebook%20and%20Server.html

💡Problema com Brilho e BackLight no Linux

Abra e edite o seguinte arquivo:


sudo vim /etc/default/grub
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_backlight=video"

Cria um arquivo:

sudo vim usr/share/X11/xorg.conf.d/80-backlight.con

Escreva e salve:

Section "Device"
    Identifier  "Intel Graphics"
    Driver      "intel"
    Option      "AccelMethod"     "sna"
    Option      "Backlight"       "acpi_video0"
    BusID       "PCI:0:2:0"
EndSection

Digite o seguinte comando para atualizar o Grub:

sudo update-gru

E por fim reinicie o sistema.

Referencia:

[1] – https://askubuntu.com/questions/1034305/brightness-problem-ubuntu-18-04-lts