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
| λ kunthar : cargo install exa | |
| Updating registry `https://github.com/rust-lang/crates.io-index` | |
| Downloading exa v0.8.0 | |
| Installing exa v0.8.0 | |
| Downloading num_cpus v1.8.0 | |
| Downloading glob v0.2.11 | |
| Downloading ansi_term v0.8.0 | |
| Downloading log v0.3.9 | |
| Downloading datetime v0.4.7 | |
| Downloading scoped_threadpool v0.1.9 |
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
| #ZOPS Auth ve PUSH Akışları | |
| - İlk olarak kullanıcı **Zops** üzerinde bir ""account"" oluşturmalıdır. [Signup](http://zops.io/signup) endpoint’ini kullanarak kendinize "account" oluşturabilirsiniz. | |
| - Mail adresinize gelen linke tıklayarak "account" oluşturmayı kabul edersiniz. Tıklanılan link, sizi kullanıcı bilgilerinizi dolduracağınız bir ekrana yönlendirir. | |
| - Gerekli alanları doldurduktan sonra ilgili "account"ta tanımlı bir admin hesabı oluşur. | |
| - Sistem üzerinde işlem yapabilmek için (proje oluşturma, "consumer" oluşturma, "consumer"ları projelere ekleme gibi) geçerli bir token'a sahip olmanız gerekir. Bu tokeni alabilmek için [SAAS loginresource](https://docs.zops.io/SAAS.html#loginresource) adresinden yararlanabilirsiniz. | |
| - Saas sistemi üzerinden geçerli token aldıktan sonra yapılacak requestlerde bu token kullanılması gerekir. | |
| - Tokeni request headerinin “AUTHORIZATION” parametre değeri olarak kullanmanız gerekir.(Sistem üzerinde User token olarak bilinen bu tokenin kullanım süresi 1 haftadır. 1 Hafta |
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
| ### Keybase proof | |
| I hereby claim: | |
| * I am kunthar on github. | |
| * I am kunthar (https://keybase.io/kunthar) on keybase. | |
| * I have a public key ASAysttxkT6dupuS8vFQ2DISCAEVB6gp4yIv-caXWGj7vQo | |
| To claim this, I am signing this object: |
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
| Openedx Notes | |
| #Firewall Rules | |
| #https://dev-notes.eu/2016/08/persistent-iptables-rules-in-ubuntu-16-04-xenial-xerus/ | |
| # setup ip tables | |
| iptables -A INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT | |
| iptables -A INPUT -p tcp --dport ssh -j ACCEPT | |
| iptables -A INPUT -p tcp --dport 80 -j ACCEPT |
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
| def check_if_signed(): | |
| try: | |
| yournum = int(input('input a number: ')) | |
| if yournum >= 0: | |
| print('Your number is unsigned.') | |
| elif yournum < 0: | |
| print('Your number is signed.') | |
| else: | |
| print('C\'mon give me numbers.') | |
| except: |
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 | |
| MAX_NO=0 | |
| echo -n "Enter Number between (6 to 11) : " | |
| read MAX_NO | |
| if ! [ $MAX_NO -ge 6 -a $MAX_NO -le 11 ] ; then | |
| echo "You should give number between 6 and 11." | |
| exit 1 | |
| fi | |
| clear | |
| for (( i=1; i<=MAX_NO; i++ )) do for (( s=MAX_NO; s>=i; s-- )) |
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: '3' | |
| services: | |
| db: | |
| image: postgres:12 | |
| environment: | |
| - POSTGRES_USER=postgres | |
| - POSTGRES_PASSWORD=postgress | |
| - POSTGRES_DB=postgres | |
| ports: |
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 python:3.6-jessie | |
| ENV LANG C.UTF-8 | |
| ENV TZ=Europe/Istanbul | |
| RUN apt-get update && apt-get install -y gcc musl-dev libpq-dev git libjpeg-dev zlib1g-dev libffi-dev libxml2-dev libxslt1-dev vim xfonts-75dpi xfonts-base | |
| RUN pip3 install --upgrade virtualenv \ | |
| && virtualenv zarupa-venv | |
| COPY entrypoint.sh /entrypoint.sh |
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 | |
| . /zarupa-venv/bin/activate | |
| #git clone https://github.com/kunthar/zarupa | |
| pip install -r /zarupa/requirements.txt | |
| pip install gunicorn | |
| export FLASK_APP=/zarupa/zarupa/server.py | |
| export FLASK_CONFIGURATION=production | |
| export POSTGRES_USER=zarupa | |
| export POSTGRES_PASSWORD= | |
| export POSTGRES_HOST= |
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
| import falcon | |
| import consul | |
| import os | |
| from graceful.authentication import Token | |
| from zopsm.lib.rest.authentication import ZopsKeyValueUserStorage | |
| from zopsm.lib.rest.response_logger import ResponseLoggerMiddleware | |
| from zopsm.roc.resources.banned_channel import BannedChannel, BannedChannelList | |
| from zopsm.roc.resources.banned_contact import BannedContact, BannedContactList | |
| from zopsm.roc.resources.channel import Channel, ChannelList | |
| from zopsm.roc.resources.contact import Contact |