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
echo | openssl s_client -showcerts -servername www.api.apline.pro -connect www.api.apline.pro:443 2>/dev/null | openssl x509 -inform pem -noout -text |
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
SELECT | |
table_schema as `Database`, | |
table_name AS `Table`, | |
round(((data_length + index_length) / 1024 / 1024), 2) `Size in MB` | |
FROM information_schema.TABLES | |
ORDER BY (data_length + index_length) DESC; |
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
drop table if exists appFilesX; | |
create table appFilesX like app_files; | |
drop function if exists allUpdate; | |
create function allUpdate(pathGroup varchar(255) charset utf8 collate utf8_unicode_ci, fileId INT) returns int |
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
pg_dump -U postgres -O -Fc dbname > dumpfile | |
Here we used the following options: | |
-U to specify which user will connect to the PostgreSQL database server. | |
-W or --password will force pg_dump to prompt for a password before connecting to the server. | |
-F is used to specify the format of the output file, which can be one of the following: | |
p – plain-text SQL script | |
c – custom-format archive | |
d – directory-format archive |
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
Connect to the right database first, then run: | |
$ GRANT ALL PRIVILEGES ON ALL TABLES IN SCHEMA public TO user; |
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
#!/bin/bash | |
set -o errexit | |
apt-get update | |
apt-get upgrade -y | |
apt-get install -y git wget sudo | |
git clone https://github.com/facebook/osquery.git | |
cd /osquery | |
git checkout 1.0.3 |
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 vim /etc/default/grub | |
GRUB_CMDLINE_LINUX="ipv6.disable=1 rd.lvm.lv=cl_workstation/root rd.lvm.lv=cl_workstation/swap loglevel=7 systemd.log_level=debug" | |
sudo grub2-mkconfig -o /boot/grub2/grub.cfg |
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
function getParameterByName(name, url) { | |
name = name.replace(/[\[\]]/g, "\\$&"); | |
let regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"), | |
results = regex.exec(url); | |
if (!results) return ''; | |
if (!results[2]) return ''; | |
return decodeURIComponent(results[2].replace(/\+/g, " ")); | |
} |
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
export const toQueryString = (params) => { | |
if (!params) { | |
return '' | |
} | |
if (!Object.keys(params).length) { | |
return '' | |
} |
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
widget.content.gtk-theme-override string Adwaita |
OlderNewer