Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auto deploy the latest main branch version to fly.dev #65

Merged
merged 11 commits into from
Nov 9, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# flyctl launch added from .gitignore
**/.idea
**/.DS_Store

**/config.ini

**/venv

**/.git
**/*.pyc
**/__pycache__
**/*.egg-info
**/dist
**/build
**/.vscode

**/.env
25 changes: 25 additions & 0 deletions .github/workflows/fly.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Fly Deploy
on:
push:
branches:
- main

env:
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}
ADYEN_API_KEY: ${{ secrets.ADYEN_API_KEY }}
ADYEN_CLIENT_KEY: ${{ secrets.ADYEN_CLIENT_KEY }}
ADYEN_HMAC_KEY: ${{ secrets.ADYEN_HMAC_KEY }}
ADYEN_MERCHANT_ACCOUNT: ${{ secrets.ADYEN_MERCHANT_ACCOUNT }}
jobs:
deploy:
environment: zeOne
name: Deploy app
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: superfly/flyctl-actions/setup-flyctl@master
- run: flyctl secrets set ADYEN_API_KEY="$ADYEN_API_KEY"
- run: flyctl secrets set ADYEN_CLIENT_KEY="$ADYEN_CLIENT_KEY"
- run: flyctl secrets set ADYEN_HMAC_KEY="$ADYEN_HMAC_KEY"
- run: flyctl secrets set ADYEN_MERCHANT_ACCOUNT="$ADYEN_MERCHANT_ACCOUNT"
- run: flyctl deploy --remote-only
11 changes: 11 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
FROM python:3.9-slim

COPY app/ /app
COPY requirements.txt /app/requirements.txt

EXPOSE 8080:8080

WORKDIR /app
RUN pip install -r requirements.txt

CMD [ "python", "./app.py" ]
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
# Checkout Create
## Interactive Drop-in creation and styling tool


[Try the tool online here!](https://adyencheckout.fly.dev/).

_⚠️WARNING⚠️: Do not use real payment information online! There are test cards available at the bottom of the page_

> :warning: **This tool is being worked on and is in Alpha stage**

An external tool which allows you to build a drop-in integration and make customizations as outlined in our style sheet. Enables you to experiment and see what your checkout could potentially look like. You can then retrive the final result alongside the changes so it can be exported for your team to fully implement your vision.
Expand Down Expand Up @@ -78,4 +83,4 @@ MIT license. For more information, see the **LICENSE** file in the root director

---

*v1.1.0-alpha*
*v1.1.0-alpha*
38 changes: 38 additions & 0 deletions fly.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# fly.toml file generated for adyencheckout on 2022-11-07T16:40:06+01:00

app = "adyencheckout"
kill_signal = "SIGINT"
kill_timeout = 5
processes = []

[env]

[experimental]
allowed_public_ports = []
auto_rollback = true

[[services]]
http_checks = []
internal_port = 8080
processes = ["app"]
protocol = "tcp"
script_checks = []
[services.concurrency]
hard_limit = 25
soft_limit = 20
type = "connections"

[[services.ports]]
force_https = true
handlers = ["http"]
port = 80

[[services.ports]]
handlers = ["tls", "http"]
port = 443

[[services.tcp_checks]]
grace_period = "1s"
interval = "15s"
restart_limit = 0
timeout = "2s"
3 changes: 2 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
flask
Flask==2.2.2
Adyen == 6.0.0
python-dotenv===0.19.2
requests == 2.27.1
gunicorn==20.1.0