Skip to content

Commit 5cf27b8

Browse files
authored
publish to npm and github (#43)
*Issue #, if available:* *Description of changes:* 1. Enable the release workflow to publish to npm and github. 2. Temporarily disable publishing to ECR because we have already done that. Will enable it later. By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
1 parent 6fed8fc commit 5cf27b8

File tree

1 file changed

+36
-36
lines changed

1 file changed

+36
-36
lines changed

.github/workflows/release-build.yml

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -64,45 +64,45 @@ jobs:
6464
registry: public.ecr.aws
6565

6666

67-
# Publish to public ECR
68-
- name: Build and push public ECR image
69-
uses: docker/build-push-action@v5
70-
with:
71-
push: true
72-
context: .
73-
file: ./Dockerfile
74-
platforms: linux/amd64,linux/arm64
75-
tags: |
76-
${{ env.RELEASE_PUBLIC_REPOSITORY }}:v${{ github.event.inputs.version }}
67+
# # Publish to public ECR
68+
# - name: Build and push public ECR image
69+
# uses: docker/build-push-action@v5
70+
# with:
71+
# push: true
72+
# context: .
73+
# file: ./Dockerfile
74+
# platforms: linux/amd64,linux/arm64
75+
# tags: |
76+
# ${{ env.RELEASE_PUBLIC_REPOSITORY }}:v${{ github.event.inputs.version }}
7777

78-
# Publish to private ECR
79-
- name: Build and push private ECR image
80-
uses: docker/build-push-action@v5
81-
with:
82-
push: true
83-
context: .
84-
file: ./Dockerfile
85-
platforms: linux/amd64,linux/arm64
86-
tags: |
87-
${{ env.RELEASE_PRIVATE_REPOSITORY }}:v${{ github.event.inputs.version }}
78+
# # Publish to private ECR
79+
# - name: Build and push private ECR image
80+
# uses: docker/build-push-action@v5
81+
# with:
82+
# push: true
83+
# context: .
84+
# file: ./Dockerfile
85+
# platforms: linux/amd64,linux/arm64
86+
# tags: |
87+
# ${{ env.RELEASE_PRIVATE_REPOSITORY }}:v${{ github.event.inputs.version }}
8888

89-
# # Publish to GitHub releases
90-
# - name: Create GH release
91-
# id: create_release
92-
# env:
93-
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token
94-
# run: |
95-
# gh release create --target "$GITHUB_REF_NAME" \
96-
# --title "Release v${{ github.event.inputs.version }}" \
97-
# --draft \
98-
# "v${{ github.event.inputs.version }}" \
99-
# aws-distro-opentelemetry-node-autoinstrumentation/aws-aws-distro-opentelemetry-node-autoinstrumentation-${{ github.event.inputs.version }}.tgz
89+
# Publish to GitHub releases
90+
- name: Create GH release
91+
id: create_release
92+
env:
93+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token
94+
run: |
95+
gh release create --target "$GITHUB_REF_NAME" \
96+
--title "Release v${{ github.event.inputs.version }}" \
97+
--draft \
98+
"v${{ github.event.inputs.version }}" \
99+
aws-distro-opentelemetry-node-autoinstrumentation/aws-aws-distro-opentelemetry-node-autoinstrumentation-${{ github.event.inputs.version }}.tgz
100100
101101
# Publish to npm
102-
# - name: Publish to npm
103-
# env:
104-
# NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
105-
# NPM_CONFIG_PROVENANCE: true
106-
# run: npx lerna publish from-package --no-push --no-private --no-git-tag-version --no-verify-access --yes
102+
- name: Publish to npm
103+
env:
104+
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
105+
NPM_CONFIG_PROVENANCE: true
106+
run: npx lerna publish from-package --no-push --no-private --no-git-tag-version --no-verify-access --yes
107107

108108

0 commit comments

Comments
 (0)