Re-enable postgres migration tests (#28270)
* Utilize separate image for migration tests * Re-enable migration tests * Apply Ibrahim's suggestion * Apply Saturn's suggestion
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
355dd18e52
Коммит
8e2dc45841
19
.github/workflows/migration.yml
поставляемый
19
.github/workflows/migration.yml
поставляемый
@@ -33,17 +33,16 @@ jobs:
|
|||||||
docker restart ${COMPOSE_PROJECT_NAME}-mysql-1 && sleep 10
|
docker restart ${COMPOSE_PROJECT_NAME}-mysql-1 && sleep 10
|
||||||
- name: Build test image
|
- name: Build test image
|
||||||
env:
|
env:
|
||||||
BUILD_IMAGE: mattermostdevelopment/mattermost-build-server:${{ steps.go.outputs.GO_VERSION }}
|
BUILD_IMAGE: golang:${{ steps.go.outputs.GO_VERSION }}-bookworm
|
||||||
|
PGLOADER_IMAGE: mattermost/mattermost-pgloader:v3.6.9
|
||||||
run: |
|
run: |
|
||||||
echo -e "FROM $BUILD_IMAGE\n\nRUN apt update && \
|
docker build -t $TEST_IMAGE - <<EOF
|
||||||
apt remove -y pgloader && \
|
FROM $PGLOADER_IMAGE AS pgloader
|
||||||
apt install -y sbcl unzip libsqlite3-dev make curl gawk freetds-dev libzip-dev && \
|
FROM $BUILD_IMAGE
|
||||||
git clone https://github.com/dimitri/pgloader.git && \
|
COPY --from=pgloader /usr/bin/pgloader /usr/bin/pgloader
|
||||||
cd pgloader && \
|
EOF
|
||||||
git checkout \$(git tag --list --sort=-v:refname "v*" | head -n1) && \
|
# Print out installed pgloader version
|
||||||
make && \
|
docker run --rm $TEST_IMAGE pgloader --version
|
||||||
mv build/bin/pgloader /bin" >> dockerfile_tmp
|
|
||||||
docker build -t $TEST_IMAGE - < dockerfile_tmp
|
|
||||||
- name: Generate test-data
|
- name: Generate test-data
|
||||||
run: |
|
run: |
|
||||||
docker run --net ${COMPOSE_PROJECT_NAME}_mm-test \
|
docker run --net ${COMPOSE_PROJECT_NAME}_mm-test \
|
||||||
|
|||||||
9
.github/workflows/server-ci-template.yml
поставляемый
9
.github/workflows/server-ci-template.yml
поставляемый
@@ -346,8 +346,7 @@ jobs:
|
|||||||
name: server-build-artifact
|
name: server-build-artifact
|
||||||
path: server/build/
|
path: server/build/
|
||||||
retention-days: 2
|
retention-days: 2
|
||||||
### Disabled until fixed
|
test-migration:
|
||||||
#test-migration:
|
name: MySQL to PostgreSQL Migration
|
||||||
# name: MySQL to PostgreSQL Migration
|
uses: ./.github/workflows/migration.yml
|
||||||
# uses: ./.github/workflows/migration.yml
|
secrets: inherit
|
||||||
# secrets: inherit
|
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user