This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Extensão: | |
rails: para cor; | |
ruby: para autocomplete; | |
rubocop: para corrigir erros; | |
beautify: para identaçao; | |
boxy: pra deixar o vscode bonito; | |
great icons: para deixar os icones bonitos; | |
slim para a identaçao do html slim |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
listen 80; | |
server_name app.4business.tech www.app.4business.tech; | |
return 301 http://app.4business.tech$request_uri; | |
} | |
server { | |
server_name app.4business.tech; | |
location / { | |
proxy_pass http://localhost:3000; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
touch Rubymine.desktop | |
Agora vamos dar permissão de execução para este arquivo: | |
chmod +x Rubymine.desktop | |
Depois, abro este arquivo com o editor Exemplo: | |
nano Rubymine.desktop |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo kill $(sudo lsof -t -i:3000) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt-get install docker.io | |
sudo docker run -d \ | |
--name=mariadb \ | |
--restart=always \ | |
-v /etc/localtime:/etc/localtime:ro \ | |
-u root \ | |
-e MYSQL_ROOT_PASSWORD=root \ | |
-v /storage/mariadb:/var/lib/mysql \ | |
-p 3306:3306 \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd /youapfolder | |
gem install bundler | |
curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash - | |
apt-get update | |
apt-get install nodejs -y | |
bundle update | |
rails assets:precompile RAILS_ENV=production | |
rails s -b 0.0.0.0 -e production |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Depois de carregado o Live-CD, entro no meu terminal e digito os comandos a seguir: | |
1. | |
Verificando a partição referente ao seu GNU/LINUX: | |
sudo fdisk -l | |
(caso esteja utilizando outro SO que não o Ubuntu, faço o login como ROOT) | |
2. | |
Vou montar o meu sistema de arquivos na minha partição GNU/Linux no diretório /mnt. | |
sudo mount -t ext4 /dev/sda6 /mnt | |
Neste caso o meu sistema de arquivos é EXT4 e a minha partição Linux é a sda6, troque esses campos conforme a sua configuração. | |
3. Instalação do Grub: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
If we go through Rails documenting, it clearly says — ‘With includes, | |
Active Record ensures that all of the specified associations are | |
loaded using the minimum possible number of queries’. | |
When we need data to be used from associated tables, includes must be used. | |
------------------------------- | |
Se passarmos pela documentação do Rails, ele diz claramente: | |
"Com includes, o Active Record garante que todas as associações | |
especificadas sejam carregadas usando o número mínimo possível de consultas". | |
Quando precisamos que os dados sejam usados nas tabelas associadas, | |
os includes devem ser usados. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo docker run -d \ | |
--name=postgres \ | |
-v /etc/localtime:/etc/localtime:ro \ | |
-e POSTGRES_USER=root \ | |
-e POSTGRES_PASSWORD=root \ | |
-v /storage/pgdata:/var/lib/postgresql/data \ | |
-p 5432:5432 \ | |
--restart=always \ | |
postgres |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Internacionais | |
https://nomadlist.com | |
http://www.freelance.com/en/ | |
https://remoteok.io/ | |
https://www.flexjobs.com/ | |
https://www.wfh.io/ | |
https://www.virtualvocations.com/ | |
https://weworkremotely.com/ | |
https://authenticjobs.com/ |
OlderNewer