This file contains hidden or 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
| # Path function, write override exist values in path | |
| _vault-patch() { | |
| path="" | |
| if tty -s; then | |
| if [ $# -le 2 ]; then | |
| echo "No arguments specified. Usage:"; | |
| echo "vault-patch secret/path field value"; | |
| return 1; | |
| fi | |
| text="\"${@:3}\"" |
This file contains hidden or 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
| <html> | |
| <head> | |
| <style> | |
| @import url(https://fonts.googleapis.com/css?family=Iceland); | |
| html, body { | |
| height: 100%; | |
| margin: 0; | |
| } |
This file contains hidden or 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
| 0 |
This file contains hidden or 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
| db.Anime.aggregate([{$project:{_id: true, title: true, "externalDbs.titles": true, startDate: true, endDate: true}}, {$unwind: "$externalDbs"}, {$unwind: "$externalDbs.titles"}, {$group: {_id: "$_id", titles: {$addToSet: "$title"}, titles: {$addToSet: "$externalDbs.titles"}}}, {$out: "Search"}]) | |
| db.Search.find({$text: {$search: 'ajin'}}) | |
| // multiple fields https://docs.mongodb.org/manual/tutorial/create-text-index-on-multiple-fields/ |
This file contains hidden or 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
| http://blog.cloudthat.com/sample-questions-for-mongodb-certified-dba-c100dba-exam/ | |
| 1. b | |
| 2. с | |
| 3. a, c | |
| 4. a, c // b | |
| 5. c, d | |
| 6. b // | c | |
| 7. d // | b | |
| 8. d // | b, c | |
| 9. a |
This file contains hidden or 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
| mkdir -p data/rs1 data/rs2 data/rs3 | |
| mongod --replSet m101 --logpath "1.log" --dbpath data/rs1 --port 27017 --smallfiles --oplogSize 64 --fork | |
| mongod --replSet m101 --logpath "2.log" --dbpath data/rs2 --port 27018 --smallfiles --oplogSize 64 --fork | |
| mongod --replSet m101 --logpath "3.log" --dbpath data/rs3 --port 27019 --smallfiles --oplogSize 64 --fork | |
| mongo --port 27017 << 'EOF' | |
| config = { _id: "m101", members:[ | |
| { _id : 0, host : "localhost:27017"}, | |
| { _id : 1, host : "localhost:27018"}, |
This file contains hidden or 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 setCookie(name, value, options) { | |
| options = options || {}; | |
| var expires = options.expires; | |
| if (typeof expires == "number" && expires) { | |
| var d = new Date(); | |
| d.setTime(d.getTime() + expires * 1000); | |
| expires = options.expires = d; | |
| } |
This file contains hidden or 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
| curl -w "Connect time: %{time_connect}\nTime to first byte: %{time_starttransfer}\nTotal time: %{time_total} \n\n" -o /dev/null http://st.torg.imgsmail.ru/freeze/new/js/glued/4a1189cb3ffc6d87d7f8cd1e4cee8161/libs.js |
This file contains hidden or 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
| FROM node | |
| RUN npm install -g gemini | |
| RUN apt-get update \ | |
| && apt-get install -y --no-install-recommends \ | |
| build-essential \ | |
| chrpath \ | |
| libssl-dev \ | |
| libxft-dev \ |
This file contains hidden or 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
| #VERSION: 1.30 | |
| #AUTHORS: BTDigg team (research@btdigg.org) | |
| # GNU GENERAL PUBLIC LICENSE | |
| # Version 3, 29 June 2007 | |
| # | |
| # <http://www.gnu.org/licenses/> | |
| # | |
| # This program is free software: you can redistribute it and/or modify | |
| # it under the terms of the GNU General Public License as published by |
NewerOlder