Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 16 additions & 4 deletions .github/workflows/deploy-use-ecs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,10 @@ jobs:
- name: Set IMAGE_TAG environment variable
run: echo "IMAGE_TAG=$(echo ${{ github.sha }} | cut -c 1-7)" >> $GITHUB_ENV

- name: Set FEATURE environment variable
if: ${{ startsWith(github.event_name == 'schedule' && 'staging' || inputs.environment, 'feature') }}
run: echo "FEATURE=$(echo "${GITHUB_REF#refs/heads/feat/}")" >> "$GITHUB_ENV"

- name: Set US ACR region
if: ${{ inputs.acr-region == 'us-east-1' || inputs.environment == 'prod' || inputs.environment == 'feature prod' }}
run: |
Expand All @@ -41,16 +45,24 @@ jobs:
- uses: peter-evans/repository-dispatch@v4
with:
token: ${{ secrets.GH_TOKEN }}
repository: dream-num/helm-chart-private
repository: dream-num/runner-machine
event-type: create-ci
client-payload: >
{
"service": "documentation",
"git_ref": "${{ github.ref }}",
"instance_size": "32c64g",
"region":"us-virginia",
"image_tag": "${{ env.IMAGE_TAG }}",
"cr": "${{ env.CR }}",
"next_public_docs_source_ref": "${{ github.ref_name }}",
"next_posthog_apikey": "${{ secrets.NEXT_POSTHOG_APIKEY }}"
"next_posthog_apikey": "${{ secrets.NEXT_POSTHOG_APIKEY }}",
"machine": {
"instance_size": "16c32g",
"region":"us-virginia",
"internet_bandwidth": "100"
},
"helm_dispatch": {
"event": "${{ vars.DISPATCH_EVENT_TYPE }}",
"service": "univer-docs-site",
"feature": "${{ env.FEATURE }}"
}
}
3 changes: 2 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ push_image: create_builder
ifeq ($(PUSH_TAG), latest)
$(eval image_tag=-t $(CR)/$(NS)/$(REPOSITORY):latest)
else
$(eval image_tag=-t $(CR)/$(NS)/$(REPOSITORY):$(PUSH_TAG) -t $(CR)/$(NS)/$(REPOSITORY):latest)
$(eval image_tag=-t $(CR)/$(NS)/$(REPOSITORY):$(PUSH_TAG))
endif
$(CTR) buildx build \
--build-arg CR=$(CR) \
Expand All @@ -35,6 +35,7 @@ endif
--build-arg NEXT_PUBLIC_DOCS_SOURCE_REF=$(NEXT_PUBLIC_DOCS_SOURCE_REF) \
--builder $(BUILDER) \
--platform $(OSARCH) \
--progress=plain \
--file Dockerfile \
$(image_tag) \
--push .
Expand Down
Loading