Skip to content

Commit

Permalink
Merge branch 'main' into feat/add-otel-to-service
Browse files Browse the repository at this point in the history
  • Loading branch information
sujankota authored Feb 10, 2025
2 parents 1abfeb5 + 021f2d4 commit b444eec
Show file tree
Hide file tree
Showing 21 changed files with 178 additions and 2,825 deletions.
6 changes: 3 additions & 3 deletions .github/scripts/work-init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,20 +36,20 @@ case $component in
echo "[INFO] skipping for leaf package"
;;
sdk)
rm go.work go.work.sum &&
rm -f go.work go.work.sum &&
go work init &&
go work use ./sdk &&
go work use ./service &&
go work use ./examples
;;
service)
rm go.work go.work.sum &&
rm -f go.work go.work.sum &&
go work init &&
go work use ./service &&
go work use ./examples
;;
examples)
rm go.work go.work.sum &&
rm -f go.work go.work.sum &&
go work init &&
go work use ./examples
;;
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/auto-approve-version-bumps.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ jobs:
bad_files=$(gh pr view --json files | jq '[.files[].path | select(endswith("go.mod") or endswith("go.sum") | not)] | length')
if [ "$bad_files" -ne 0 ]; then
echo "Found $bad_files files that are not go.mod or go.sum. Will not auto approve."
echo "bad_files_found=true" >> $GITHUB_ENV
echo "bad_files_found=true" >>"$GITHUB_ENV"
else
echo "bad_files_found=false" >> $GITHUB_ENV
echo "bad_files_found=false" >>"$GITHUB_ENV"
echo "Only go.mod and go.sum files found. Continuing Workflow."
fi
- uses: hmarr/auto-approve-action@v4
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ jobs:
run: |-
go mod tidy
go fmt ./...
git restore go.sum "${GITHUB_WORKSPACE}/go.work.sum"
git restore go.sum
working-directory: ${{ matrix.directory }}
- run: git diff
- run: git diff-files --ignore-submodules
Expand Down Expand Up @@ -283,7 +283,7 @@ jobs:
run: |-
cd protocol/go
go mod tidy
git restore go.sum "${GITHUB_WORKSPACE}/go.work.sum"
git restore go.sum
- run: git diff
- run: git diff-files --ignore-submodules
- name: Check that make proto-generate has run before PR submission; see above for error details
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/friendly-reminders.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
- name: Extract go version
id: go-version
run: |
echo "go-version=$(go work edit --json | jq -r '.Go')" >>$GITHUB_OUTPUT
echo "go-version=$(go work edit --json | jq -r '.Go')" >>"$GITHUB_OUTPUT"
- uses: actions/setup-go@v5
with:
go-version: ${{ steps.go-version.outputs.go-version }}
Expand All @@ -21,11 +21,11 @@ jobs:
id: go-mod-tidy
run: |
# iterate over work file, cd and run go mod tidy
for line in $(go work edit --json | jq -r '.Use.[].DiskPath'); do
(cd $line && go mod tidy)
done
while IFS="" read -r line || [ -n "$line" ]; do
(cd "$line" && go mod tidy)
done < <(go work edit --json | jq -r '.Use.[].DiskPath')
# check if any changes were made
echo $(git status --porcelain) >> $GITHUB_OUTPUT
git status --porcelain >>"$GITHUB_OUTPUT"
- name: Post comment if go.mod was changed
if: steps.go-mod-tidy.outputs.stdout != ''
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/nightly-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ jobs:
DIGEST: ${{ steps.build-and-push.outputs.digest }}
TAGS: ${{ steps.docker_meta.outputs.tags }}
run: |
images=""
images=()
for tag in ${TAGS}; do
images+="${tag}@${DIGEST} "
images+=("${tag}@${DIGEST}")
done
cosign sign --yes --recursive ${images}
cosign sign --yes --recursive "${images[@]}"
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
sdk)
echo "TO_UPDATE=['examples','service']">>"$GITHUB_OUTPUT"
;;
services)
service)
# examples does not import service, but assumes it is running separately
;;
examples)
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sonarcloud.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
- name: 'Setup Go'
uses: actions/setup-go@cdcb36043654635271a94b9a6d1392de5bb323a7
with:
go-version: '1.22.11'
go-version: '1.22.12'
check-latest: false
cache-dependency-path: |
service/go.sum
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/traffic.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:

- id: get-date
name: Set current date as env variable
run: echo "DATE=$(date +'%Y%m%d')" >> $GITHUB_OUTPUT
run: echo "DATE=$(date +'%Y%m%d')" >>"$GITHUB_OUTPUT"

- name: Get Traffic
uses: actions/github-script@v7
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/vulnerability-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,5 @@ jobs:
- name: govluncheck
uses: golang/govulncheck-action@b625fbe08f3bccbe446d94fbf87fcc875a4f50ee
with:
go-version-input: "1.22.11"
go-version-input: "1.22.12"
work-dir: ${{ matrix.directory }}
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ tmp-gen/
/sdkjava/target
/serviceapp
/service/opentdf
/go.work.sum
service/rttests/*.tdf
coverage.out
coverage.lcov
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ COPY lib/flattening lib/flattening
COPY lib/fixtures lib/fixtures
COPY service/ service/
COPY examples/ examples/
COPY go.work go.work.sum ./
COPY go.work ./
RUN cd service \
&& go mod download \
&& go mod verify
Expand Down
Loading

0 comments on commit b444eec

Please sign in to comment.