зеркало из https://github.com/Azure/azure-saas.git
remove build artifacts
This commit is contained in:
Родитель
da9b05fd77
Коммит
de324221e9
|
@ -1,87 +0,0 @@
|
|||
name: Build Artifacts
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
paths:
|
||||
- ".github/workflows/**"
|
||||
- "src/**"
|
||||
|
||||
jobs:
|
||||
build-arm-json:
|
||||
name: Build ARM JSON
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Code checkout
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Run Bicep Build
|
||||
uses: azure/CLI@v1
|
||||
with:
|
||||
azcliversion: latest
|
||||
inlineScript: |
|
||||
mkdir ./dist
|
||||
az bicep build --file src/Saas.IaC/main.bicep --outfile ./dist/main.json
|
||||
# - name: Copy Other Files
|
||||
# run: |
|
||||
# cp src/Saas.IaC/createUiDefinition.json ./dist/
|
||||
- name: Upload Artifacts
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: arm-json
|
||||
path: ./dist/**
|
||||
|
||||
build-application:
|
||||
name: Build Application
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Code checkout
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Log in to registry
|
||||
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $ --password-stdin
|
||||
|
||||
- name: Build Docker Images
|
||||
run: |
|
||||
docker-compose build
|
||||
|
||||
echo "Showing all ASDK images"
|
||||
docker images | grep asdk-
|
||||
|
||||
- name: Tag and Push Docker Images
|
||||
run: |
|
||||
# Put all images that need to be pushed here, quoted and space delimited
|
||||
IMAGES_TO_PUSH=("asdk-admin" "asdk-web" "asdk-permissions" "asdk-signup" "asdk-identity-setup")
|
||||
|
||||
for i in ${IMAGES_TO_PUSH[@]}; do
|
||||
# TODO: add version, using latest for now
|
||||
GH_TAG=ghcr.io/${{ github.repository }}/$i:latest
|
||||
GH_TAG=$(echo $GH_TAG | tr '[:upper:]' '[:lower:]')
|
||||
|
||||
echo "Tagging $i with GitHub Container Registry"
|
||||
docker tag $i $GH_TAG
|
||||
|
||||
echo "Pushing $i to GitHub Container Registry"
|
||||
docker push $GH_TAG
|
||||
done
|
||||
|
||||
create-github-release:
|
||||
name: Create GitHub Release
|
||||
runs-on: ubuntu-latest
|
||||
needs:
|
||||
- build-arm-json
|
||||
- build-application
|
||||
steps:
|
||||
- uses: actions/download-artifact@v2
|
||||
with:
|
||||
name: arm-json
|
||||
path: ./dist/
|
||||
- name: Create Release with Artifacts
|
||||
uses: marvinpinto/action-automatic-releases@latest
|
||||
with:
|
||||
repo_token: "${{ secrets.GITHUB_TOKEN }}"
|
||||
automatic_release_tag: "latest"
|
||||
title: "Generated Latest Release"
|
||||
files: |
|
||||
./dist/**
|
Загрузка…
Ссылка в новой задаче