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
# aws cloudformation deploy --template-file KeepDbStopped.yml --stack-name stop-db --capabilities CAPABILITY_IAM --parameter-overrides DB=arn:aws:rds:us-east-1:XXX:db:XXX | |
Description: Automatically stop RDS instance every time it turns on due to exceeding the maximum allowed time being stopped | |
Parameters: | |
DB: | |
Description: ARN of database that needs to be stopped | |
Type: String | |
AllowedPattern: arn:aws:rds:[a-z0-9\-]+:[0-9]+:db:[^:]* | |
Resources: | |
DatabaseStopperFunction: | |
Type: AWS::Lambda::Function |
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
// ==UserScript== | |
// @name activesg - single court for 2 hrs | |
// @namespace blah | |
// @version 0.6.5 | |
// @description activesg court booking | |
// @match https://members.myactivesg.com/* | |
// @copyright 2017+, naresh,Gavin,Kent | |
// @require http://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js | |
// ==/UserScript== |
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
package main | |
import ( | |
"errors" | |
"fmt" | |
) | |
func main() { | |
// test out queue | |
var queue Queue |
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
database: | |
image: "postgres:alpine" | |
environment: | |
- POSTGRES_USER | |
- POSTGRES_DB |
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
version: "3" | |
services: | |
web-client: | |
build: https://github.com/youraccount/web-client.git | |
ports: | |
- "4210::5000" | |
entrypoint: "npm run dev" | |
web-server: |
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
database: | |
image: "postgres:alpine" | |
environment: | |
POSTGRES_USER: postgres | |
POSTGRES_DB: mydb | |
ports: | |
- "4201:5432" | |
# persist to a named volume | |
volumes: | |
- server_db:/var/lib/postgresql/data |
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
POSTGRES_USER=postgres | |
POSTGRES_DB=mydb |
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
database: | |
image: "postgres:alpine" | |
environment: | |
POSTGRES_USER: postgres | |
POSTGRES_DB: mydb |
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
# 1. Absoulute path | |
build: . | |
# 2. Relative path | |
build: ../path/to/app/ | |
# 3. Git repo URL | |
build: https://github.com/docker/rootfs.git | |
# 4. Git repo URL with branch |
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
# Base image is Alpine with latest stable Node installed. | |
FROM node:alpine | |
# set working directory for subsequent commands | |
WORKDIR /front-end | |
# leverage build cache by copying npm package files first | |
COPY ./package*.json ./ |
NewerOlder