revert: Wait for chat section to be completed #83
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: CI | |
on: | |
push: | |
workflow_dispatch: | |
env: | |
FOUNDRY_PROFILE: ci-workflow | |
CARGO_TERM_COLOR: always | |
jobs: | |
push-reg: | |
name: "Push Registry" | |
runs-on: ubuntu-latest | |
if: github.ref == 'refs/heads/main' | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Run script | |
run: | | |
docker login $REGISTRY -u $REGISTRY_USER -p $REGISTRY_PASSWORD | |
docker build -t "$IMAGE:${GITHUB_SHA:0:7}" . | |
docker push "$IMAGE:${GITHUB_SHA:0:7}" | |
env: | |
REGISTRY: ${{ vars.REGISTRY }} | |
REGISTRY_PASSWORD: ${{ secrets.REGISTRY_PASSWORD }} | |
REGISTRY_USER: ${{ secrets.REGISTRY_USER }} | |
APP_NAME: ${{ vars.APP_NAME }} | |
IMAGE: ${{ vars.REGISTRY }}/${{ vars.APP_NAME }} | |
deploy-server: | |
name: "Deploy DARKUBE" | |
runs-on: ubuntu-latest | |
if: github.ref == 'refs/heads/main' | |
needs: | |
- push-reg | |
container: hamravesh.hamdocker.ir/public/darkube-cli:v1.1 | |
steps: | |
- name: Run script | |
run: darkube deploy --ref master --token ${DARKUBE_DEPLOY_TOKEN} --app-id ${DARKUBE_APP_ID} --image-tag "${GITHUB_SHA:0:7}" --job-id "$GITHUB_RUN_ID" --stateless-app true | |
env: | |
DARKUBE_DEPLOY_TOKEN: ${{ secrets.DARKUBE_DEPLOY_TOKEN }} | |
DARKUBE_APP_ID: ${{ vars.DARKUBE_APP_ID }} |