-
-
Notifications
You must be signed in to change notification settings - Fork 259
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add recursive heroku docker pushes
this allows to build dedicated production images for each heroku process type. Additionally with this change multiple images can be deployed at once.
- Loading branch information
Jan Zaydowicz
committed
Sep 25, 2021
1 parent
d81c270
commit bdf88de
Showing
8 changed files
with
67 additions
and
1 deletion.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -91,3 +91,26 @@ jobs: | |
checkstring: "ok" | ||
procfile: "web: gunicorn index:app" | ||
- run: npm run test-action https://akhileshns-hd-test-4.herokuapp.com/ | ||
|
||
deploy-test-5: | ||
runs-on: ubuntu-latest | ||
needs: deploy-test-2 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- run: npm run setup tests/test-3/data.json | ||
- run: | | ||
git config --global user.email "[email protected]" | ||
git config --global user.name "AkhileshNS" | ||
git add -A | ||
git commit -m "Added data.json" | ||
- uses: akhileshns/heroku-deploy@master | ||
with: | ||
heroku_api_key: ${{secrets.HEROKU_API_KEY}} | ||
heroku_app_name: "akhileshns-hd-test-3" | ||
heroku_email: "[email protected]" | ||
appdir: "tests/test-5" | ||
usedocker: true | ||
dockerHerokuPushRecursive: true | ||
dockerHerokuProcessType: web | ||
healthcheck: "https://akhileshns-hd-test-3.herokuapp.com/" | ||
- run: npm run test-action https://akhileshns-hd-test-3.herokuapp.com/ |
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
FROM python:3.8.2-alpine3.11 | ||
|
||
WORKDIR /usr/src/app | ||
|
||
COPY requirements.txt ./ | ||
RUN pip install --no-cache-dir -r requirements.txt | ||
|
||
COPY . . | ||
|
||
EXPOSE 8080 | ||
|
||
CMD [ "python", "./index.py" ] |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# IMPORTS | ||
import os | ||
from flask import Flask | ||
app = Flask(__name__) | ||
port = int(os.environ.get("PORT", 8080)) | ||
|
||
@app.route('/') | ||
def hello_handler(): | ||
f = open("data.json"); | ||
return f.read() | ||
|
||
if __name__ == '__main__': | ||
app.run(debug=True, host='0.0.0.0', port=port) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
autopep8==1.4.4 | ||
Click==7.0 | ||
Flask==1.1.1 | ||
gunicorn==19.10.0 | ||
itsdangerous==1.1.0 | ||
Jinja2==2.10.3 | ||
MarkupSafe==1.1.1 | ||
pycodestyle==2.5.0 | ||
Werkzeug==0.16.0 |