- Evan Brown - @evandbrown
- @aws_eb
- The AWS Application Management Blog - http://blogs.aws.amazon.com/application-management
- Dockerizing a Python Web App - http://blogs.aws.amazon.com/application-management/post/Tx1ZLAHMVBEDCOC/Dockerizing-a-Python-Web-App
- A PHP Sample App - https://github.com/awslabs/eb-demo-php-simple-app/tree/docker-apache
- A Python Sample App - https://github.com/awslabs/eb-py-flask-signup/tree/docker
- 5-Part Blog/Hangout Series - Develop, Deploy, and Manage with Elastic Beanstalk - http://blogs.aws.amazon.com/application-management/blog/tag/DDMSeries
- Dockerru
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
{% extends "base.html" %} | |
{% block content %} | |
<section title="Child Create" data-role="content"> | |
<h2>Child Create</h2> | |
<form action="{% url child_create slug=form.family_slug.value %}" method="POST"> | |
{{ form.errors }} | |
{% csrf_token %} | |
<ul> |
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
Show hidden characters
{ | |
"always_show_minimap_viewport": true, | |
"bold_folder_labels": true, | |
"caret_style": "solid", | |
"color_scheme": "Packages/Monokai Extended/Monokai Extended.tmTheme", | |
"draw_minimap_border": true, | |
"enable_telemetry": false, | |
"ensure_newline_at_eof_on_save": true, | |
"folder_exclude_patterns": | |
[ |
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
## Common Packages | |
# --------------- | |
sudo apt-get -y update | |
sudo apt-get -y upgrade | |
sudo apt-get -y install software-properties-common libssl-dev openssl wget | |
## Install latest Python 3 | |
# ----------------------- | |
PY_VERSION=3.4.3 | |
PY_URL="https://www.python.org/ftp/python/$PY_VERSION/Python-$PY_VERSION.tgz" |
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
// or any othe port | |
sudo netstat -ltnp | grep ':30303' | |
// will return | |
tcp6 0 0 :::30303 :::* LISTEN 844/S20geth | |
sudo kill -9 844 |
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
from django.utils.functional import SimpleLazyObject | |
from django.contrib.auth.models import AnonymousUser | |
from rest_framework.request import Request | |
from rest_framework_jwt.authentication import JSONWebTokenAuthentication | |
def get_user_jwt(request): | |
""" | |
Replacement for django session auth get_user & auth.get_user for |
Having seen @pirapira's sketch of Bamboo ( https://github.com/pirapira/bamboo/ ), which proposed to add better control about the "smart contract program flow", even across calls, I thought that this should certainly be added to Solidity, and actually, it might even be possible now to a certain degree using inline assembly.
The problem is that with many functions in a contract, it is not always clear which can be called at which stage in the contract's lifetime. Certain smart contracts would be easier to understand if written as follows:
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
pragma solidity ^0.4.2; | |
contract ethernalSale { | |
struct order { | |
uint amount; | |
address buyer; | |
} | |
mapping (uint => order) orderBook; | |
mapping (address => uint) balanceOf; |
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
# Use an official centos7 image | |
FROM centos:7 | |
RUN localedef -i fr_FR -c -f UTF-8 -A /usr/share/locale/locale.alias fr_FR.UTF-8 | |
ENV LANG fr_FR.utf8 | |
# gcc because we need regex and pyldap | |
# openldap-devel because we need pyldap | |
RUN yum update -y \ | |
&& yum install -y https://centos7.iuscommunity.org/ius-release.rpm \ |