diff --git a/Makefile b/Makefile index ed2491bd86..80e0aa93d4 100644 --- a/Makefile +++ b/Makefile @@ -240,7 +240,7 @@ wait-for-keycloak: grep -m 1 "Config of Keycloak done." <(docker-compose -p $(CI_BUILD_TAG) --compatibility logs -f keycloak 2>&1) # Define a list of which Lagoon Services are needed for running any deployment testing -main-test-services = actions-handler broker logs2notifications api api-db api-redis keycloak keycloak-db ssh auth-server local-git local-api-data-watcher-pusher local-minio +main-test-services = actions-handler broker logs2notifications api api-db api-redis keycloak keycloak-db ssh auth-server local-git local-api-data-watcher-pusher local-minio local-minio-upload # List of Lagoon Services needed for webhook endpoint testing webhooks-test-services = webhook-handler webhooks2tasks backup-handler @@ -436,7 +436,7 @@ api-development: build/api build/api-db build/local-api-data-watcher-pusher buil .PHONY: ui-logs-development ui-logs-development: build/actions-handler build/api build/api-db build/local-api-data-watcher-pusher build/keycloak build/keycloak-db build/broker-single build/api-redis build/logs2notifications build/local-minio - IMAGE_REPO=$(CI_BUILD_TAG) docker-compose -p $(CI_BUILD_TAG) --compatibility up -d api api-db actions-handler local-api-data-watcher-pusher ui keycloak keycloak-db broker api-redis logs2notifications local-minio + IMAGE_REPO=$(CI_BUILD_TAG) docker-compose -p $(CI_BUILD_TAG) --compatibility up -d api api-db actions-handler local-api-data-watcher-pusher ui keycloak keycloak-db broker api-redis logs2notifications local-minio local-minio-upload ## CI targets diff --git a/docker-compose.yaml b/docker-compose.yaml index 23bc435882..e9926e68e2 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -66,6 +66,8 @@ services: - CI=${CI:-true} - REGISTRY=harbor.172.17.0.1.nip.io:18080 # Docker network bridge and forwarded port for harbor-nginx - S3_FILES_HOST=http://172.17.0.1:9000 + - S3_BAAS_ACCESS_KEY_ID=minio + - S3_BAAS_SECRET_ACCESS_KEY=minio123 - CONSOLE_LOGGING_LEVEL=trace depends_on: - api-init @@ -217,13 +219,25 @@ services: local-minio: image: minio/minio entrypoint: sh - command: -c 'mkdir -p /export/lagoon-files && mkdir -p /export/harbor-images && minio server /export --console-address ":9001" ' + command: -c 'mkdir -p /export/restores && mkdir -p /export/lagoon-files && mkdir -p /export/harbor-images && minio server /export --console-address ":9001" ' ports: - '9000:9000' - '9001:9001' environment: - MINIO_ACCESS_KEY=minio - MINIO_SECRET_KEY=minio123 + local-minio-upload: + image: minio/mc + entrypoint: sh + command: -c 'mc alias set localminio $${MINIO_SERVER_URL} $${MINIO_ACCESS_KEY} $${MINIO_SECRET_KEY}; mc ls localminio; mc cp /restores/files.tar.gz localminio/restores/high-cotton-master-files.tar.gz' + volumes: + - ./local-dev/restores:/restores + environment: + - MINIO_SERVER_URL=http://172.17.0.1:9000 + - MINIO_ACCESS_KEY=minio + - MINIO_SECRET_KEY=minio123 + depends_on: + - local-minio local-registry: image: ${IMAGE_REPO:-lagoon}/local-registry ports: diff --git a/local-dev/api-data-watcher-pusher/api-data/01-populate-api-data-general.gql b/local-dev/api-data-watcher-pusher/api-data/01-populate-api-data-general.gql index a9e899e231..061ba681e9 100644 --- a/local-dev/api-data-watcher-pusher/api-data/01-populate-api-data-general.gql +++ b/local-dev/api-data-watcher-pusher/api-data/01-populate-api-data-general.gql @@ -420,7 +420,7 @@ mutation PopulateApi { input: { backupId: "e2e1d31b4a7dfc1687f469b6673f6bf2c0aabee0cc6b3f1bdbde710a9bc6280f" status: SUCCESSFUL - restoreLocation: "/restore/e2e1d31b4a7dfc1687f469b6673f6bf2c0aabee0cc6b3f1bdbde710a9bc6280f/files.gz" + restoreLocation: "http://172.17.0.1:9000/restores/high-cotton-master-files.tar.gz" execute: false } ) { diff --git a/local-dev/restores/files.tar.gz b/local-dev/restores/files.tar.gz new file mode 100644 index 0000000000..a8911cb781 Binary files /dev/null and b/local-dev/restores/files.tar.gz differ