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> | |
| <title>test</title> | |
| <script src="https://cdn.plot.ly/plotly-latest.min.js"></script> | |
| </head> | |
| <body> | |
| <div style="display: flex; flex-flow: row wrap;"> | |
| <div style="width: 50%; height:400px;"><div id="dd4338a2-db39-4984-9ad0-911ebb98ff11" style="height: 100%; width: 100%;" class="plotly-graph-div"></div><script type="text/javascript">window.PLOTLYENV=window.PLOTLYENV || {};window.PLOTLYENV.BASE_URL="https://plot.ly";Plotly.newPlot("dd4338a2-db39-4984-9ad0-911ebb98ff11", [{"y": [5, 16, 18, 5, 7, 2, 17, 18, 1, 6, 2, 4], "x": [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11], "type": "scatter"}], {}, {"linkText": "", "showLink": true})</script></div> |
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
| #!/bin/bash | |
| # Example of cron base auto release script using a git remote origin with lock file in case of long release process | |
| # * * * * * /path/to/the/file/update_git_and_release.sh | |
| # die on non-zero status | |
| set -e; | |
| # die on undefined variable | |
| set -u; |
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
| #/etc/systemd/system/foo.service | |
| [Unit] | |
| #Description of the service | |
| Description=foo | |
| #Auto start on reboot when the target user target is availaible | |
| After=multi-user.target | |
| [Service] | |
| #Switching the working directory (not needed, just an example) |
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
| wget https://bootstrap.pypa.io/get-pip.py | |
| sudo python get-pip.py | |
| rm get-pip.py | |
| sudo pip install virtualenv | |
| #virtualenv --no-site-packages my_virtualenv_name | |
| mkdir .virtualenvs | |
| sudo pip install virtualenvwrapper | |
| export WORKON_HOME=$HOME/.virtualenvs | |
| export PROJECT_HOME=$HOME/git |
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
| # -*- coding: utf-8 -*- | |
| import pip, os | |
| from pip.commands.list import ListCommand | |
| from pip.req import parse_requirements | |
| import re | |
| import argparse | |
| class MyListCommand(ListCommand): |
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
| <?php | |
| if (isset($_SERVER['HTTP_X_FORWARDED_FOR'])) { | |
| $IParray=array_values(array_filter(explode(',',$_SERVER['HTTP_X_FORWARDED_FOR']))); | |
| $_SERVER['REMOTE_ADDR'] = reset($IParray); | |
| } | |
| if (isset($_SERVER['HTTP_X_FORWARDED_PROTO'])) { | |
| if ($_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https'){ | |
| $_SERVER['REQUEST_SCHEME'] = 'https'; | |
| $_SERVER['HTTPS']='on'; |
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
| #/usr/bin/sh | |
| sudo apt-get update | |
| sudo apt-get --yes install python-pip | |
| sudo apt-get --yes install vim | |
| sudo apt-get --yes install htop | |
| sudo apt-get --yes install ncdu | |
| sudo pip install --upgrade 'pip<7' | |
| sudo pip install --upgrade ansible | |
| sudo pip install --upgrade virtualenv virtualenvwrapper | |
| sudo apt-get dist-upgrade -V |
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
| // Use Gists to store code you would like to remember later on | |
| console.log(window); // log the "window" object to the console |
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
| <link rel="import" href="../core-scaffold/core-scaffold.html"> | |
| <link rel="import" href="../core-header-panel/core-header-panel.html"> | |
| <link rel="import" href="../core-menu/core-menu.html"> | |
| <link rel="import" href="../core-item/core-item.html"> | |
| <link rel="import" href="../core-icon-button/core-icon-button.html"> | |
| <link rel="import" href="../core-toolbar/core-toolbar.html"> | |
| <link rel="import" href="../core-menu/core-submenu.html"> | |
| <polymer-element name="my-element"> |
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
| <link rel="import" href="../core-ajax/core-ajax.html"> | |
| <link rel="import" href="../paper-tabs/paper-tabs.html"> | |
| <link rel="import" href="../paper-tabs/paper-tab.html"> | |
| <polymer-element name="my-element"> | |
| <template> | |
| <style> | |
| :host { | |
| position: relative; |