migrate tag-based references to commit SHA-based references for github workflows (#30509)
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
c95968c380
Коммит
c1d4f5cb9f
61
.github/workflows/codeql-analysis.yml
поставляемый
61
.github/workflows/codeql-analysis.yml
поставляемый
@@ -3,9 +3,9 @@ name: "CodeQL"
|
|||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
# The branches below must be a subset of the branches above
|
# The branches below must be a subset of the branches above
|
||||||
branches: [ master ]
|
branches: [master]
|
||||||
schedule:
|
schedule:
|
||||||
- cron: '30 5,17 * * *'
|
- cron: "30 5,17 * * *"
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
@@ -13,7 +13,7 @@ permissions:
|
|||||||
jobs:
|
jobs:
|
||||||
analyze:
|
analyze:
|
||||||
permissions:
|
permissions:
|
||||||
security-events: write # for github/codeql-action/autobuild to send a status report
|
security-events: write # for github/codeql-action/autobuild to send a status report
|
||||||
name: Analyze
|
name: Analyze
|
||||||
if: github.repository_owner == 'mattermost'
|
if: github.repository_owner == 'mattermost'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@@ -21,38 +21,37 @@ jobs:
|
|||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
language: [ 'go', 'javascript' ]
|
language: ["go", "javascript"]
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
||||||
|
|
||||||
# Initializes the CodeQL tools for scanning.
|
# Initializes the CodeQL tools for scanning.
|
||||||
- name: Initialize CodeQL
|
- name: Initialize CodeQL
|
||||||
uses: github/codeql-action/init@v3.28.11
|
uses: github/codeql-action/init@6bb031afdd8eb862ea3fc1848194185e076637e5 # v3.28.11
|
||||||
with:
|
with:
|
||||||
languages: ${{ matrix.language }}
|
languages: ${{ matrix.language }}
|
||||||
debug: false
|
debug: false
|
||||||
config-file: ./.github/codeql/codeql-config.yml
|
config-file: ./.github/codeql/codeql-config.yml
|
||||||
|
|
||||||
- name: Build JavaScript
|
- name: Build JavaScript
|
||||||
uses: github/codeql-action/autobuild@v3.28.11
|
uses: github/codeql-action/autobuild@6bb031afdd8eb862ea3fc1848194185e076637e5 # v3.28.11
|
||||||
if: ${{ matrix.language == 'javascript' }}
|
if: ${{ matrix.language == 'javascript' }}
|
||||||
|
|
||||||
- name: Setup go
|
- name: Setup go
|
||||||
uses: actions/setup-go@v5
|
uses: actions/setup-go@v5
|
||||||
with:
|
with:
|
||||||
go-version-file: server/go.mod
|
go-version-file: server/go.mod
|
||||||
if: ${{ matrix.language == 'go' }}
|
if: ${{ matrix.language == 'go' }}
|
||||||
|
|
||||||
|
- name: Build Golang
|
||||||
|
run: |
|
||||||
|
cd server
|
||||||
|
make setup-go-work
|
||||||
|
make build-linux-amd64
|
||||||
|
if: ${{ matrix.language == 'go' }}
|
||||||
|
|
||||||
- name: Build Golang
|
# Perform Analysis
|
||||||
run: |
|
- name: Perform CodeQL Analysis
|
||||||
cd server
|
uses: github/codeql-action/analyze@6bb031afdd8eb862ea3fc1848194185e076637e5 # v3.28.11
|
||||||
make setup-go-work
|
|
||||||
make build-linux-amd64
|
|
||||||
if: ${{ matrix.language == 'go' }}
|
|
||||||
|
|
||||||
# Perform Analysis
|
|
||||||
- name: Perform CodeQL Analysis
|
|
||||||
uses: github/codeql-action/analyze@v3.28.11
|
|
||||||
|
|||||||
8
.github/workflows/esrupgrade-common.yml
поставляемый
8
.github/workflows/esrupgrade-common.yml
поставляемый
@@ -89,7 +89,7 @@ jobs:
|
|||||||
# We skip the very last line, which simply contains the date of the dump
|
# We skip the very last line, which simply contains the date of the dump
|
||||||
head -n -1 ${DUMP_SERVER_NAME} | gzip > ${DUMP_SERVER_NAME}.gz
|
head -n -1 ${DUMP_SERVER_NAME} | gzip > ${DUMP_SERVER_NAME}.gz
|
||||||
- name: Upload dump
|
- name: Upload dump
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
|
||||||
with:
|
with:
|
||||||
name: upgraded-dump-server
|
name: upgraded-dump-server
|
||||||
path: ${{ env.DUMP_SERVER_NAME }}.gz
|
path: ${{ env.DUMP_SERVER_NAME }}.gz
|
||||||
@@ -134,7 +134,7 @@ jobs:
|
|||||||
# We skip the very last line, which simply contains the date of the dump
|
# We skip the very last line, which simply contains the date of the dump
|
||||||
head -n -1 ${DUMP_SCRIPT_NAME} | gzip > ${DUMP_SCRIPT_NAME}.gz
|
head -n -1 ${DUMP_SCRIPT_NAME} | gzip > ${DUMP_SCRIPT_NAME}.gz
|
||||||
- name: Upload dump
|
- name: Upload dump
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
|
||||||
with:
|
with:
|
||||||
name: upgraded-dump-script
|
name: upgraded-dump-script
|
||||||
path: ${{ env.DUMP_SCRIPT_NAME }}.gz
|
path: ${{ env.DUMP_SCRIPT_NAME }}.gz
|
||||||
@@ -145,7 +145,7 @@ jobs:
|
|||||||
- esr-upgrade-script
|
- esr-upgrade-script
|
||||||
steps:
|
steps:
|
||||||
- name: Retrieve dumps
|
- name: Retrieve dumps
|
||||||
uses: actions/download-artifact@v4
|
uses: actions/download-artifact@cc203385981b70ca67e1cc392babf9cc229d5806 # v4.1.9
|
||||||
- name: Diff dumps
|
- name: Diff dumps
|
||||||
run: |
|
run: |
|
||||||
gzip -d upgraded-dump-server/${DUMP_SERVER_NAME}.gz
|
gzip -d upgraded-dump-server/${DUMP_SERVER_NAME}.gz
|
||||||
@@ -153,7 +153,7 @@ jobs:
|
|||||||
diff upgraded-dump-server/$DUMP_SERVER_NAME upgraded-dump-script/$DUMP_SCRIPT_NAME > $DIFF_NAME
|
diff upgraded-dump-server/$DUMP_SERVER_NAME upgraded-dump-script/$DUMP_SCRIPT_NAME > $DIFF_NAME
|
||||||
- name: Upload diff
|
- name: Upload diff
|
||||||
if: failure() # Upload the diff only if the previous step failed; i.e., if the diff is non-empty
|
if: failure() # Upload the diff only if the previous step failed; i.e., if the diff is non-empty
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
|
||||||
with:
|
with:
|
||||||
name: dumps-diff
|
name: dumps-diff
|
||||||
path: ${{ env.DIFF_NAME }}
|
path: ${{ env.DIFF_NAME }}
|
||||||
|
|||||||
4
.github/workflows/mmctl-test-template.yml
поставляемый
4
.github/workflows/mmctl-test-template.yml
поставляемый
@@ -31,9 +31,9 @@ jobs:
|
|||||||
- name: Store required variables for publishing results
|
- name: Store required variables for publishing results
|
||||||
run: |
|
run: |
|
||||||
echo "${{ inputs.name }}" > server/test-name
|
echo "${{ inputs.name }}" > server/test-name
|
||||||
echo "${{ github.event.pull_request.number }}" > server/pr-number
|
echo "${{ github.event.pull_request.number }}" > server/pr-number
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
|
uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
|
||||||
with:
|
with:
|
||||||
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
||||||
cache-dependency-path: server/go.sum
|
cache-dependency-path: server/go.sum
|
||||||
|
|||||||
18
.github/workflows/server-ci-template.yml
поставляемый
18
.github/workflows/server-ci-template.yml
поставляемый
@@ -19,7 +19,7 @@ jobs:
|
|||||||
id: go
|
id: go
|
||||||
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
|
uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
|
||||||
with:
|
with:
|
||||||
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
||||||
cache-dependency-path: |
|
cache-dependency-path: |
|
||||||
@@ -44,7 +44,7 @@ jobs:
|
|||||||
id: go
|
id: go
|
||||||
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
|
uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
|
||||||
with:
|
with:
|
||||||
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
||||||
cache-dependency-path: |
|
cache-dependency-path: |
|
||||||
@@ -69,7 +69,7 @@ jobs:
|
|||||||
id: go
|
id: go
|
||||||
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
|
uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
|
||||||
with:
|
with:
|
||||||
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
||||||
cache-dependency-path: |
|
cache-dependency-path: |
|
||||||
@@ -92,7 +92,7 @@ jobs:
|
|||||||
id: go
|
id: go
|
||||||
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
|
uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
|
||||||
with:
|
with:
|
||||||
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
||||||
cache-dependency-path: |
|
cache-dependency-path: |
|
||||||
@@ -117,7 +117,7 @@ jobs:
|
|||||||
id: go
|
id: go
|
||||||
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
|
uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
|
||||||
with:
|
with:
|
||||||
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
||||||
cache-dependency-path: |
|
cache-dependency-path: |
|
||||||
@@ -144,7 +144,7 @@ jobs:
|
|||||||
id: go
|
id: go
|
||||||
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
|
uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
|
||||||
with:
|
with:
|
||||||
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
||||||
cache-dependency-path: |
|
cache-dependency-path: |
|
||||||
@@ -195,7 +195,7 @@ jobs:
|
|||||||
id: go
|
id: go
|
||||||
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
|
uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
|
||||||
with:
|
with:
|
||||||
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
||||||
cache-dependency-path: |
|
cache-dependency-path: |
|
||||||
@@ -220,7 +220,7 @@ jobs:
|
|||||||
id: go
|
id: go
|
||||||
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
|
uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
|
||||||
with:
|
with:
|
||||||
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
||||||
cache-dependency-path: |
|
cache-dependency-path: |
|
||||||
@@ -288,7 +288,7 @@ jobs:
|
|||||||
id: go
|
id: go
|
||||||
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
|
uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
|
||||||
with:
|
with:
|
||||||
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
||||||
cache-dependency-path: |
|
cache-dependency-path: |
|
||||||
|
|||||||
4
.github/workflows/server-test-template.yml
поставляемый
4
.github/workflows/server-test-template.yml
поставляемый
@@ -29,7 +29,7 @@ jobs:
|
|||||||
working-directory: ./server
|
working-directory: ./server
|
||||||
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
run: echo GO_VERSION=$(cat .go-version) >> "${GITHUB_OUTPUT}"
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
|
uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
|
||||||
with:
|
with:
|
||||||
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
go-version: ${{ steps.go.outputs.GO_VERSION }}
|
||||||
cache-dependency-path: server/go.sum
|
cache-dependency-path: server/go.sum
|
||||||
@@ -77,4 +77,4 @@ jobs:
|
|||||||
server/gotestsum.json
|
server/gotestsum.json
|
||||||
server/report.xml
|
server/report.xml
|
||||||
server/test-name
|
server/test-name
|
||||||
server/pr-number
|
server/pr-number
|
||||||
|
|||||||
16
webapp/channels/.github/workflows/performance-benchmarks.yml
поставляемый
16
webapp/channels/.github/workflows/performance-benchmarks.yml
поставляемый
@@ -21,14 +21,14 @@ jobs:
|
|||||||
- 5432:5432
|
- 5432:5432
|
||||||
steps:
|
steps:
|
||||||
- name: Check out web app
|
- name: Check out web app
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
||||||
|
|
||||||
- uses: actions/setup-node@v3
|
- uses: actions/setup-node@cdca7365b2dadb8aad0a33bc7601856ffabcc48e # v4.3.0
|
||||||
with:
|
with:
|
||||||
node-version: 16.10.0
|
node-version: 16.10.0
|
||||||
|
|
||||||
- name: Download and install Cypress
|
- name: Download and install Cypress
|
||||||
uses: cypress-io/github-action@v5
|
uses: cypress-io/github-action@108b8684ae52e735ff7891524cbffbcd4be5b19f # v6.7.16
|
||||||
with:
|
with:
|
||||||
runTests: false
|
runTests: false
|
||||||
working-directory: e2e/cypress
|
working-directory: e2e/cypress
|
||||||
@@ -56,7 +56,7 @@ jobs:
|
|||||||
mv client-original/products mattermost/client/products
|
mv client-original/products mattermost/client/products
|
||||||
fi
|
fi
|
||||||
- name: Run the E2E tests
|
- name: Run the E2E tests
|
||||||
uses: cypress-io/github-action@v5
|
uses: cypress-io/github-action@108b8684ae52e735ff7891524cbffbcd4be5b19f # v6.7.16
|
||||||
with:
|
with:
|
||||||
browser: chrome
|
browser: chrome
|
||||||
config: video=true,videosFolder=tests/videos
|
config: video=true,videosFolder=tests/videos
|
||||||
@@ -72,28 +72,28 @@ jobs:
|
|||||||
MM_TEAMSETTINGS_ENABLEOPENSERVER: true
|
MM_TEAMSETTINGS_ENABLEOPENSERVER: true
|
||||||
- name: Upload Cypress logs
|
- name: Upload Cypress logs
|
||||||
if: ${{ always() }}
|
if: ${{ always() }}
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
|
||||||
with:
|
with:
|
||||||
name: Cypress logs
|
name: Cypress logs
|
||||||
path: e2e/cypress/tests/integration/performance/logs/
|
path: e2e/cypress/tests/integration/performance/logs/
|
||||||
retention-days: 3
|
retention-days: 3
|
||||||
- name: Upload Mattermost logs
|
- name: Upload Mattermost logs
|
||||||
if: ${{ always() }}
|
if: ${{ always() }}
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
|
||||||
with:
|
with:
|
||||||
name: Mattermost logs
|
name: Mattermost logs
|
||||||
path: e2e/cypress/mattermost/logs/mattermost.log
|
path: e2e/cypress/mattermost/logs/mattermost.log
|
||||||
retention-days: 3
|
retention-days: 3
|
||||||
- name: Upload screenshots
|
- name: Upload screenshots
|
||||||
if: ${{ failure() }}
|
if: ${{ failure() }}
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
|
||||||
with:
|
with:
|
||||||
name: Test screenshots
|
name: Test screenshots
|
||||||
path: e2e/cypress/tests/screenshots
|
path: e2e/cypress/tests/screenshots
|
||||||
retention-days: 3
|
retention-days: 3
|
||||||
- name: Upload videos
|
- name: Upload videos
|
||||||
if: ${{ always() }}
|
if: ${{ always() }}
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
|
||||||
with:
|
with:
|
||||||
name: Test Videos
|
name: Test Videos
|
||||||
path: e2e/cypress/tests/videos
|
path: e2e/cypress/tests/videos
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user