something is wrong #6
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
name: deploy-search | |
on: | |
workflow_dispatch: | |
push: | |
branches: [ "master" ] | |
paths: | |
- 'src/SearchService/**' | |
env: | |
REGISTRY_IMAGE: amg31/search-svc | |
DOCKERFILE: src/SearchService/Dockerfile | |
DEPLOYMENT_NAME: search-svc | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: docker/setup-buildx-action@v2 | |
- name: Login to DockerHub | |
uses: docker/login-action@v2 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_PASSWORD }} | |
- name: Build and push the Docker image | |
uses: docker/build-push-action@v3 | |
with: | |
context: "{{defaultContext}}" | |
file: ${{env.DOCKERFILE}} | |
push: true | |
tags: ${{ env.REGISTRY_IMAGE }}:latest | |
# - name: Install doctl | |
# uses: digitalocean/action-doctl@v2 | |
# with: | |
# token: ${{ secrets.DIGITALOCEAN_ACCESS_TOKEN }} | |
# - name: Save DigitalOcean kubeconfig | |
# run: doctl kubernetes cluster kubeconfig save auctionnext | |
# - name: Restart Kubernetes deployment | |
# run: kubectl rollout restart deployment ${{ env.DEPLOYMENT_NAME }} |