Skip to content

Instantly share code, notes, and snippets.

View petronioamaral's full-sized avatar

Petrônio Amaral petronioamaral

View GitHub Profile
@petronioamaral
petronioamaral / ssh_get_file_another_host.md
Created August 24, 2020 16:01
ssh get file another host using scp port 23
scp -P 23 user@HOST:indexg.html /home/backup/

[File to get]
[To send file]
@petronioamaral
petronioamaral / change_ip_main_vestacp.md
Created August 25, 2020 05:22
change main ip vestacp

touch /usr/local/vesta/bin/v-change-server-ip chmod 0755 /usr/local/vesta/bin/v-change-server-ip nano /usr/local/vesta/bin/v-change-server-ip

#!/bin/sh

#script to change ips on a VestaCP server.
#usage:
# $0 <oldip> <newip>
@petronioamaral
petronioamaral / change_mount_linux.md
Created September 3, 2020 23:03
change point of mount linux centos
se a partição já existe adicione-a ao arquivo /etc/fstab e reinicie o PC, exemplo:

$ sudo nano /etc/fstab

ou

$ sudo gedit /etc/fstab

e use uma entrada parecida com essas abaixo, repeitando é lógico, o tipo do sistema de arquivos:
@petronioamaral
petronioamaral / create_trigger_mysql.md
Created November 16, 2020 17:43
create trigger mysql

`

@petronioamaral
petronioamaral / mask_phone_9or8digits.html
Last active November 25, 2020 03:32
mask to phone 9 or 8 digits brazil
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8"/>
<title>Demo Máscara Telefone</title>
</head>
<body>
Telefone: <input onkeypress="mascaraTelefone(this)"/><br />
<script>
/*
teste
dsafsdfsafs
Solution: Error executing "PutObject" on AWS HTTP error: cURL error 60 localhost site:stackoverflow.com
Folder: vendor\guzzlehttp\guzzle\src\Client.php
Change verify to false.
$defaults = [
'allow_redirects' => RedirectMiddleware::$defaultSettings,
'http_errors' => true,
'decode_content' => true,
@petronioamaral
petronioamaral / AWS_error_cURL_error_60.md
Created December 7, 2020 19:29
Solution: Error executing "PutObject" on AWS HTTP error: cURL error 60 localhost

Solution: Error executing "PutObject" on AWS HTTP error: cURL error 60 localhost

Folder: vendor\guzzlehttp\guzzle\src\Client.php

Change verify to false.

$defaults = [ 'allow_redirects' => RedirectMiddleware::$defaultSettings, 'http_errors' => true, 'decode_content' => true,

We couldn’t find that file to show.
@petronioamaral
petronioamaral / media_queries.css
Created January 11, 2021 14:50
media queries in css
/*
##Device = Desktops
##Screen = 1281px to higher resolution desktops
*/
@media (min-width: 1281px) {
/* CSS */