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
defaults: &defaults | |
docker: | |
- image: circleci/node:8 | |
version: 2 | |
jobs: | |
pre-build: | |
working_directory: ~/gatsbyBlog | |
<<: *defaults | |
steps: |
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 ubuntu | |
USER root | |
ENV BUNDLE_SILENCE_ROOT_WARNING=1 | |
RUN apt-get update && apt-get -y install curl gnupg unzip wget | |
# Install Nginx. | |
RUN set -ex && \ | |
apt-get install -y software-properties-common && \ |
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
import pytest | |
from selenium import webdriver | |
from selenium.webdriver.chrome.options import Options | |
def pytest_addoption(parser): | |
parser.addoption("--url", action="store", default="http://localhost", help="url") | |
@pytest.fixture(scope="module", autouse=True) | |
def browser(): |
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
import pytest | |
from selenium.webdriver.common.by import By | |
from selenium.webdriver.common.keys import Keys | |
@pytest.fixture(scope="module") | |
def open_url(browser,url): | |
browser.get(url) | |
browser.find_element(By.TAG_NAME, "form") | |
assert browser.title == "React App" |
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
/** | |
* Sample React Native App | |
* https://github.com/facebook/react-native | |
* | |
* @format | |
* @flow | |
*/ | |
import React, { Component } from "react"; | |
import { |
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
service: simple-data-pipline # NOTE: update this with your service name | |
provider: | |
name: aws | |
runtime: python3.6 | |
region: ap-southeast-2 | |
stage: ${opt:stage, 'dev'} | |
timeout: 300 | |
iamRoleStatements: |
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
import boto3 | |
import os | |
import pandas as pd | |
import logging | |
db_client = boto3.client('dynamodb') | |
s3 = boto3.client('s3') | |
logger = logging.getLogger() | |
logger.setLevel(logging.INFO) |
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
service: serverless-chat | |
provider: | |
name: aws | |
runtime: nodejs8.10 | |
stackName: ${self:service}-${self:provider.stage} | |
stage: ${opt:stage, 'dev'} | |
region: ${opt:region, 'ap-southeast-2'} | |
iamRoleStatements: | |
- Effect: Allow |
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 strict"; | |
const AWS = require("aws-sdk"); | |
const Bluebird = require("bluebird"); | |
AWS.config.update({ region: process.env.AWS_REGION }); | |
const DDB = new AWS.DynamoDB({ apiVersion: "2012-10-08" }); | |
AWS.config.setPromisesDependency(Bluebird); | |
require("aws-sdk/clients/apigatewaymanagementapi"); | |
const successfullResponse = { |
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
Resources: | |
CognitoUserPool: | |
Type: AWS::Cognito::UserPool | |
Properties: | |
UserPoolName: ${self:custom.poolName} | |
Schema: | |
- Name: email | |
Required: true | |
Mutable: true | |
AdminCreateUserConfig: |
OlderNewer