applying package updates #274
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 | |
on: | |
push: | |
branches: | |
- main | |
paths-ignore: | |
- .gitignore | |
- README.md | |
- '.github/ISSUE_TEMPLATE/**' | |
jobs: | |
run: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@master | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v1 | |
- name: Install Docker Compose | |
run: | | |
sudo apt-get update | |
sudo apt-get install docker-compose | |
- name: Docker Login | |
uses: docker/login-action@v2 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Test IP Address | |
run: | | |
wget -qO- https://ipecho.net/plain ; echo | |
- name: Set Kubectl | |
uses: Azure/k8s-set-context@v1 | |
with: | |
kubeconfig: ${{ secrets.KUBE_CONFIG }} | |
- name: Test Kubectl | |
run: | | |
kubectl get nodes | |
kubectl get svc -n acedatacloud-test | |
- name: Generate Build Number | |
uses: einaregilsson/build-number@v2 | |
with: | |
token: ${{ secrets.github_token }} | |
env: | |
ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true' | |
- name: Get Build Number | |
run: | | |
BUILD_NUMBER=$(echo $BUILD_NUMBER) | |
BUILD_DATE=$(date +'%Y%m%d') | |
BUILD_TAG="${BUILD_DATE}.${BUILD_NUMBER}" | |
echo "BUILD_NUMBER=${BUILD_TAG}" >> $GITHUB_ENV | |
- name: Build Docker images | |
run: docker-compose build | |
- name: Push Docker images | |
run: docker-compose push | |
- name: Deploy | |
run: sh ./deploy/test/scripts/deploy.sh |