-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert "reuse built frontend in ci, merge compose files (#6674)"
Docker image node:18.1-bookworm does not resolve. After chaning to node:18-bookworm the resulting images do not match: $ docker ps --format 'table {{.Image}}\t{{.Ports}}' IMAGE PORTS redash-server 0.0.0.0:5000->5000/tcp, :::5000->5000/tcp, 0.0.0.0:5678->5678/tcp, :::5678->5678/tcp redis:7-alpine 6379/tcp pgautoupgrade/pgautoupgrade:latest 0.0.0.0:15432->5432/tcp, :::15432->5432/tcp maildev/maildev 0.0.0.0:1025->1025/tcp, :::1025->1025/tcp, 0.0.0.0:1080->1080/tcp, :::1080->1080/tcp Expected: IMAGE PORTS redash-worker 5000/tcp redash-scheduler 5000/tcp redash-server 0.0.0.0:5678->5678/tcp, :::5678->5678/tcp, 0.0.0.0:5001->5000/tcp, :::5001->5000/tcp redis:7-alpine 6379/tcp maildev/maildev 0.0.0.0:1025->1025/tcp, :::1025->1025/tcp, 0.0.0.0:1080->1080/tcp, :::1080->1080/tcp pgautoupgrade/pgautoupgrade:latest 0.0.0.0:15432->5432/tcp, :::15432->5432/tcp Reverted command used: git reset --hard 24dec19 git reset --soft HEAD@{1}
- Loading branch information
github-actions
committed
Apr 11, 2024
1 parent
95ecb8e
commit 4a7e9ef
Showing
22 changed files
with
315 additions
and
351 deletions.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
services: | ||
redash: | ||
build: ../ | ||
command: manage version | ||
depends_on: | ||
- postgres | ||
- redis | ||
ports: | ||
- "5000:5000" | ||
environment: | ||
PYTHONUNBUFFERED: 0 | ||
REDASH_LOG_LEVEL: "INFO" | ||
REDASH_REDIS_URL: "redis://redis:6379/0" | ||
POSTGRES_PASSWORD: "FmTKs5vX52ufKR1rd8tn4MoSP7zvCJwb" | ||
REDASH_DATABASE_URL: "postgresql://postgres:FmTKs5vX52ufKR1rd8tn4MoSP7zvCJwb@postgres/postgres" | ||
REDASH_COOKIE_SECRET: "2H9gNG9obnAQ9qnR9BDTQUph6CbXKCzF" | ||
redis: | ||
image: redis:7-alpine | ||
restart: unless-stopped | ||
postgres: | ||
image: pgautoupgrade/pgautoupgrade:latest | ||
command: "postgres -c fsync=off -c full_page_writes=off -c synchronous_commit=OFF" | ||
restart: unless-stopped | ||
environment: | ||
POSTGRES_HOST_AUTH_METHOD: "trust" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
x-redash-service: &redash-service | ||
build: | ||
context: ../ | ||
args: | ||
install_groups: "main" | ||
code_coverage: ${CODE_COVERAGE} | ||
x-redash-environment: &redash-environment | ||
REDASH_LOG_LEVEL: "INFO" | ||
REDASH_REDIS_URL: "redis://redis:6379/0" | ||
POSTGRES_PASSWORD: "FmTKs5vX52ufKR1rd8tn4MoSP7zvCJwb" | ||
REDASH_DATABASE_URL: "postgresql://postgres:FmTKs5vX52ufKR1rd8tn4MoSP7zvCJwb@postgres/postgres" | ||
REDASH_RATELIMIT_ENABLED: "false" | ||
REDASH_ENFORCE_CSRF: "true" | ||
REDASH_COOKIE_SECRET: "2H9gNG9obnAQ9qnR9BDTQUph6CbXKCzF" | ||
services: | ||
server: | ||
<<: *redash-service | ||
command: server | ||
depends_on: | ||
- postgres | ||
- redis | ||
ports: | ||
- "5000:5000" | ||
environment: | ||
<<: *redash-environment | ||
PYTHONUNBUFFERED: 0 | ||
scheduler: | ||
<<: *redash-service | ||
command: scheduler | ||
depends_on: | ||
- server | ||
environment: | ||
<<: *redash-environment | ||
worker: | ||
<<: *redash-service | ||
command: worker | ||
depends_on: | ||
- server | ||
environment: | ||
<<: *redash-environment | ||
PYTHONUNBUFFERED: 0 | ||
cypress: | ||
ipc: host | ||
build: | ||
context: ../ | ||
dockerfile: .ci/Dockerfile.cypress | ||
depends_on: | ||
- server | ||
- worker | ||
- scheduler | ||
environment: | ||
CYPRESS_baseUrl: "http://server:5000" | ||
CYPRESS_coverage: ${CODE_COVERAGE} | ||
PERCY_TOKEN: ${PERCY_TOKEN} | ||
PERCY_BRANCH: ${CIRCLE_BRANCH} | ||
PERCY_COMMIT: ${CIRCLE_SHA1} | ||
PERCY_PULL_REQUEST: ${CIRCLE_PR_NUMBER} | ||
COMMIT_INFO_BRANCH: ${CIRCLE_BRANCH} | ||
COMMIT_INFO_MESSAGE: ${COMMIT_INFO_MESSAGE} | ||
COMMIT_INFO_AUTHOR: ${CIRCLE_USERNAME} | ||
COMMIT_INFO_SHA: ${CIRCLE_SHA1} | ||
COMMIT_INFO_REMOTE: ${CIRCLE_REPOSITORY_URL} | ||
CYPRESS_PROJECT_ID: ${CYPRESS_PROJECT_ID} | ||
CYPRESS_RECORD_KEY: ${CYPRESS_RECORD_KEY} | ||
redis: | ||
image: redis:7-alpine | ||
restart: unless-stopped | ||
postgres: | ||
image: pgautoupgrade/pgautoupgrade:latest | ||
command: "postgres -c fsync=off -c full_page_writes=off -c synchronous_commit=OFF" | ||
restart: unless-stopped | ||
environment: | ||
POSTGRES_HOST_AUTH_METHOD: "trust" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
#!/bin/bash | ||
|
||
# This script only needs to run on the main Redash repo | ||
|
||
if [ "${GITHUB_REPOSITORY}" != "getredash/redash" ]; then | ||
echo "Skipping image build for Docker Hub, as this isn't the main Redash repository" | ||
exit 0 | ||
fi | ||
|
||
if [ "${GITHUB_REF_NAME}" != "master" ] && [ "${GITHUB_REF_NAME}" != "preview-image" ]; then | ||
echo "Skipping image build for Docker Hub, as this isn't the 'master' nor 'preview-image' branch" | ||
exit 0 | ||
fi | ||
|
||
if [ "x${DOCKER_USER}" = "x" ] || [ "x${DOCKER_PASS}" = "x" ]; then | ||
echo "Skipping image build for Docker Hub, as the login details aren't available" | ||
exit 0 | ||
fi | ||
|
||
set -e | ||
VERSION=$(jq -r .version package.json) | ||
VERSION_TAG="$VERSION.b${GITHUB_RUN_ID}.${GITHUB_RUN_NUMBER}" | ||
|
||
export DOCKER_BUILDKIT=1 | ||
export COMPOSE_DOCKER_CLI_BUILD=1 | ||
|
||
docker login -u "${DOCKER_USER}" -p "${DOCKER_PASS}" | ||
|
||
DOCKERHUB_REPO="redash/redash" | ||
DOCKER_TAGS="-t redash/redash:preview -t redash/preview:${VERSION_TAG}" | ||
|
||
# Build the docker container | ||
docker build --build-arg install_groups="main,all_ds,dev" ${DOCKER_TAGS} . | ||
|
||
# Push the container to the preview build locations | ||
docker push "${DOCKERHUB_REPO}:preview" | ||
docker push "redash/preview:${VERSION_TAG}" | ||
|
||
echo "Built: ${VERSION_TAG}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#!/bin/bash | ||
NAME=redash | ||
VERSION=$(jq -r .version package.json) | ||
FULL_VERSION=$VERSION+b$CIRCLE_BUILD_NUM | ||
FILENAME=$NAME.$FULL_VERSION.tar.gz | ||
|
||
mkdir -p /tmp/artifacts/ | ||
|
||
tar -zcv -f /tmp/artifacts/$FILENAME --exclude=".git" --exclude="optipng*" --exclude="cypress" --exclude="*.pyc" --exclude="*.pyo" --exclude="venv" * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#!/bin/bash | ||
VERSION=$(jq -r .version package.json) | ||
FULL_VERSION=${VERSION}+b${GITHUB_RUN_ID}.${GITHUB_RUN_NUMBER} | ||
|
||
sed -ri "s/^__version__ = '([A-Za-z0-9.-]*)'/__version__ = '${FULL_VERSION}'/" redash/__init__.py | ||
sed -i "s/dev/${GITHUB_SHA}/" client/app/version.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
client/.tmp/ | ||
client/dist/ | ||
node_modules/ | ||
viz-lib/node_modules/ | ||
.tmp/ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.