-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (35 loc) · 1.11 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: Test & Deploy
on:
push:
branches:
- main
jobs:
test-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout Latest Repo
uses: actions/checkout@master
# Zip Dockerfile for upload
- name: Generate Deployment Package
run: zip -r deploy.zip * -x "*.git*"
- name: Get timestamp
uses: gerred/actions/current-time@master
id: current-time
- name: Run string replace
uses: frabert/replace-string-action@master
id: format-time
with:
pattern: '[:\.]+'
string: "${{ steps.current-time.outputs.time }}"
replace-with: '-'
flags: 'g'
- name: Deploy to EB
uses: einaregilsson/beanstalk-deploy@v22
with:
aws_access_key: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws_secret_key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
application_name: proteus-live3
environment_name: kafka3
version_label: "kafka-test1-deployment-${{ steps.format-time.outputs.replaced }}"
region: us-east-1
deployment_package: deploy.zip