-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b3db705
commit b068cea
Showing
1 changed file
with
39 additions
and
0 deletions.
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 |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: Deploy MultiDocker | ||
on: | ||
push: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- run: docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }} | ||
- run: docker build -t rishikant42/react-test -f ./client/Dockerfile.dev ./client | ||
- run: docker run -e CI=true rishikant42/react-test npm test | ||
|
||
- run: docker build -t rishikant42/multi-client ./client | ||
- run: docker build -t rishikant42/multi-nginx ./nginx | ||
- run: docker build -t rishikant42/multi-server ./server | ||
- run: docker build -t rishikant42/multi-worker ./worker | ||
|
||
- run: docker push rishikant42/multi-client | ||
- run: docker push rishikant42/multi-nginx | ||
- run: docker push rishikant42/multi-server | ||
- run: docker push rishikant42/multi-worker | ||
|
||
- name: Generate deployment package | ||
run: zip -r deploy.zip . -x '*.git*' | ||
|
||
- name: Deploy to EB | ||
uses: einaregilsson/beanstalk-deploy@v18 | ||
with: | ||
aws_access_key: ${{ secrets.AWS_ACCESS_KEY }} | ||
aws_secret_key: ${{ secrets.AWS_SECRET_KEY }} | ||
application_name: multi-docker | ||
environment_name: Multi-docker-env | ||
existing_bucket_name: elasticbeanstalk-eu-west-1-337909764067 | ||
region: us-east-1 | ||
version_label: ${{ github.sha }} | ||
deployment_package: deploy.zip |