Skip to content

Commit 77acf8e

Browse files
committed
[chore] housekeeping
1 parent 368b6ea commit 77acf8e

File tree

4 files changed

+141
-6
lines changed

4 files changed

+141
-6
lines changed

.github/workflows/publish.yml

Lines changed: 85 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
1-
# Build binaries for macOS and Linux, publish Node.js packages, create release
21
name: build-publish-release
32

43
on:
54
push:
6-
branches:
7-
- main
5+
tags:
6+
- 'v*.*.*'
87

98
jobs:
109
publish-node-packages:
@@ -46,3 +45,86 @@ jobs:
4645
env:
4746
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4847

48+
create-release:
49+
needs: [publish-node-packages]
50+
51+
runs-on: ubuntu-latest
52+
53+
steps:
54+
- name: Checkout
55+
uses: actions/checkout@v2
56+
57+
- name: Set version
58+
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
59+
60+
- name: Set current date
61+
run: |
62+
echo "RELEASE_DATE=$(date +"%d %B %Y")" >> $GITHUB_ENV
63+
64+
- name: Get version from tag
65+
id: tag_name
66+
run: |
67+
echo ::set-output name=current_version::${GITHUB_REF#refs/tags/v}
68+
69+
- name: Get Changelog Entry
70+
id: changelog_reader
71+
uses: mindsers/changelog-reader-action@v2
72+
with:
73+
validation_level: none
74+
version: ${{ steps.tag_name.outputs.current_version }}
75+
path: ./CHANGELOG.md
76+
77+
- name: Compute checksums
78+
run: |
79+
echo "## ${{ env.RELEASE_VERSION }} (${{ env.RELEASE_DATE }})" >> checksums.md
80+
echo "${{ steps.changelog_reader.outputs.changes }}" >> checksums.md
81+
echo "" >> checksums.md
82+
echo "" >> checksums.md
83+
84+
- name: Release
85+
uses: softprops/action-gh-release@v1
86+
with:
87+
prerelease: false
88+
body_path: checksums.md
89+
files: |
90+
LICENSE
91+
env:
92+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
93+
94+
notify-community:
95+
needs: [create-release]
96+
runs-on: ubuntu-latest
97+
steps:
98+
- name: Checkout
99+
uses: actions/checkout@v2
100+
- name: Get version from tag
101+
id: tag_name
102+
run: |
103+
echo ::set-output name=current_version::${GITHUB_REF#refs/tags/v}
104+
- name: Post to the community Slack channel
105+
uses: slackapi/[email protected]
106+
with:
107+
channel-id: 'C04KT9JNRHS'
108+
payload: |
109+
{
110+
"text": "[Release] Baselime Lambda Opentelemetry for Node.JS v${{ steps.tag_name.outputs.current_version }}",
111+
"blocks": [
112+
{
113+
"type": "section",
114+
"text": {
115+
"type": "mrkdwn",
116+
"text": "*[Release] Baselime Lambda Opentelemetry for Node.JS v${{ steps.tag_name.outputs.current_version }}*"
117+
}
118+
},
119+
{
120+
"type": "section",
121+
"text": {
122+
"type": "mrkdwn",
123+
"text": "<https://github.com/Baselime/lambda-node-opentelemetry/releases/tag/v${{ steps.tag_name.outputs.current_version }}|https://github.com/Baselime/lambda-node-opentelemetry/releases/tag/v${{ steps.tag_name.outputs.current_version }}>"
124+
}
125+
}
126+
]
127+
}
128+
env:
129+
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
130+

CHANGELOG.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# Changelog
2+
3+
All notable changes to this project will be documented in this file.
4+
5+
6+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
7+
8+
## [Unreleased]
9+
10+
### Added
11+
- Changelog
12+

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2021 Baselime <[email protected]> (baselime.io)
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
# 🎸 Lambda Opentelemetry for Node.JS
1+
# Lambda Opentelemetry for Node.JS
2+
[![Documentation][docs_badge]][docs]
3+
[![Latest Release][release_badge]][release]
4+
[![License][license_badge]][license]
25

36
The `@baselime/lambda-node-opentelemetry` package instruments your lambda functions and automatically ships OTEL compatible trace data to Baselime. This is the most powerful and flexible way to instrument your node service.
47

@@ -109,8 +112,25 @@ app.setDefaultFunctionProps({
109112

110113
## Automatic Instrumentation [WIP]
111114

112-
Lambda Extension coming soon
115+
WIP.
113116

114117
## Send data to another OpenTelemetry Backend
115118

116-
Add the environment variable `COLLECTOR_URL` to send the spans somewhere else.
119+
Add the environment variable `COLLECTOR_URL` to send the spans somewhere else.
120+
121+
## License
122+
123+
&copy; Baselime Limited, 2023
124+
125+
Distributed under MIT License (`The MIT License`).
126+
127+
See [LICENSE](LICENSE) for more information.
128+
129+
<!-- Badges -->
130+
131+
[docs]: https://baselime.io/docs/
132+
[docs_badge]: https://img.shields.io/badge/docs-reference-blue.svg?style=flat-square
133+
[release]: https://github.com/baselime/lambda-node-opentelemetry/releases/latest
134+
[release_badge]: https://img.shields.io/github/release/baselime/lambda-node-opentelemetry.svg?style=flat-square&ghcache=unused
135+
[license]: https://opensource.org/licenses/MIT
136+
[license_badge]: https://img.shields.io/github/license/baselime/lambda-node-opentelemetry.svg?color=blue&style=flat-square&ghcache=unused

0 commit comments

Comments
 (0)