create update cache method #136
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: Main | |
on: | |
push: | |
workflow_dispatch: | |
env: | |
DOCKER_REPOSITORY_ACCESS_TOKEN: ${{ secrets.DOCKER_REPOSITORY_ACCESS_TOKEN }} | |
DOCKER_REPOSITORY_NAME: ${{ vars.DOCKER_REPOSITORY_NAME }} | |
# IMAGE_TAG: latest # $GITHUB_SHA::6 | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Set Image Tag | |
run: echo "IMAGE_TAG=$(echo $GITHUB_SHA | cut -c 1-6)" >> $GITHUB_ENV | |
- name: Helm Add Repo | |
run: helm repo add myhelmrepo https://mohammadVatandoost.github.io/helm-chart/ | |
- name: Helm lint | |
working-directory: ./deployments/helm/xds-control-plane | |
run: helm lint . | |
- name: Docker login | |
run: docker login -u $DOCKER_REPOSITORY_NAME -p $DOCKER_REPOSITORY_ACCESS_TOKEN | |
# - name: Build Example client | |
# working-directory: ./example/client | |
# run: | | |
# docker build . --tag $DOCKER_REPOSITORY_NAME/xds-grpc-client-example:$IMAGE_TAG | |
# sed -i -e "s/tag.*/tag: $IMAGE_TAG/g" ./deployments/helm/xds-grpc-client-example/values.yaml | |
# # sed -i "s~latest~$IMAGE_TAG~g" ./deployments/helm/xds-grpc-client-example/values.yaml | |
# - name: Push Example Client | |
# run: docker push $DOCKER_REPOSITORY_NAME/xds-grpc-client-example:$IMAGE_TAG | |
- name: Build Docker images | |
run: | | |
make images | |
# - name: Push Example Server | |
# run: docker push $DOCKER_REPOSITORY_NAME/xds-grpc-server-example:$IMAGE_TAG | |
- name: Push docker images | |
run: make docker/push | |
# - name: Push XDS control plane | |
# run: | | |
# docker push $DOCKER_REPOSITORY_NAME/xds-control-plane:$IMAGE_TAG | |
# sed -i -e "s/tag.*/tag: $IMAGE_TAG/g" ./deployments/helm/xds-control-plane/values.yaml | |
- name: Commit and push changes | |
uses: devops-infra/action-commit-push@v0.3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
commit_message: Version updated | |