Skip to content

grant permission to execute tsc #5

grant permission to execute tsc

grant permission to execute tsc #5

Workflow file for this run

name: Build and Push Docker Image
on:
push:
branches:
- main
jobs:
build:
name: "Build and push image"
env:
DOCKER_USERNAME: ${{secrets.DOCKER_USERNAME}}
DOCKER_PASSWORD: ${{secrets.DOCKER_PASSWORD}}
ENV_FILE_CONTENT: ${{secrets.ENV_FILE_CONTENT}}
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Create .env file
run: echo "${{ env.ENV_FILE_CONTENT }}" > .env
- name: Log in to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ env.DOCKER_USERNAME }}
password: ${{ env.DOCKER_PASSWORD }}
- name: Build and push Docker image
uses: docker/build-push-action@v2
with:
context: .
push: true
tags: tiendat1011/dacn-backend:latest
file: ./Dockerfile