From 44897d93105e242173d99c9b5b19f9c540b7672a Mon Sep 17 00:00:00 2001 From: Samir Patel <48686912+54mir@users.noreply.github.com> Date: Wed, 22 Sep 2021 15:35:52 -0500 Subject: [PATCH 1/7] docker fix --- Dockerfile-clustertests | 2 +- Makefile | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile-clustertests b/Dockerfile-clustertests index 66fe174e9..91fde88fb 100644 --- a/Dockerfile-clustertests +++ b/Dockerfile-clustertests @@ -1,7 +1,7 @@ # This Dockerfile is used for cluster testing - it produces a much larger image # and includes all of Go as well as some utilities. -FROM golang:1.13 +FROM golang:1.16 LABEL maintainer "dev@pilosa.com" diff --git a/Makefile b/Makefile index 3db1059cc..335685187 100644 --- a/Makefile +++ b/Makefile @@ -135,7 +135,7 @@ DOCKER_COMPOSE=internal/clustertests/docker-compose.yml # pilosa image. clustertests: vendor docker-compose -f $(DOCKER_COMPOSE) down - docker-compose -f $(DOCKER_COMPOSE) build client1 + docker-compose -f $(DOCKER_COMPOSE) build docker-compose -f $(DOCKER_COMPOSE) up --exit-code-from=client1 @@ -143,7 +143,7 @@ DOCKER_COMPOSE_INDEX_KEY_REPLICATION=internal/clustertests/docker-compose-index- # Check clustertests target for more info clustertests-index-key-replication: vendor docker-compose -f $(DOCKER_COMPOSE_INDEX_KEY_REPLICATION) down - docker-compose -f $(DOCKER_COMPOSE_INDEX_KEY_REPLICATION) build client1 + docker-compose -f $(DOCKER_COMPOSE_INDEX_KEY_REPLICATION) build docker-compose -f $(DOCKER_COMPOSE_INDEX_KEY_REPLICATION) up --exit-code-from=client1 # Like clustertests, but rebuilds all images. From 3ca15cc3c47b2db9de37cb62488b70ca04f0954e Mon Sep 17 00:00:00 2001 From: Samir Patel <48686912+54mir@users.noreply.github.com> Date: Thu, 16 Sep 2021 14:52:06 -0500 Subject: [PATCH 2/7] Rename docker builds to featurebase --- Dockerfile | 4 ++-- Dockerfile.pilosa | 4 ++-- Dockerfile.runner | 4 ++-- Makefile | 14 +++++++------- docker-compose-3.yml | 8 ++++---- 5 files changed, 17 insertions(+), 17 deletions(-) diff --git a/Dockerfile b/Dockerfile index 20170e420..db864ed81 100644 --- a/Dockerfile +++ b/Dockerfile @@ -28,7 +28,7 @@ COPY . ./ COPY --from=lattice-builder /lattice/build /lattice RUN /go/bin/statik -src=/lattice -dest=/pilosa -RUN make build FLAGS="-o build/pilosa" ${MAKE_FLAGS} +RUN make build FLAGS="-o build/featurebase" ${MAKE_FLAGS} ##################### ### Pilosa runner ### @@ -40,7 +40,7 @@ LABEL maintainer "dev@molecula.com" RUN apk add --no-cache curl jq -COPY --from=pilosa-builder /pilosa/build/pilosa / +COPY --from=pilosa-builder /pilosa/build/featurebase / COPY LICENSE /LICENSE COPY NOTICE /NOTICE diff --git a/Dockerfile.pilosa b/Dockerfile.pilosa index 068279d14..c830a8862 100644 --- a/Dockerfile.pilosa +++ b/Dockerfile.pilosa @@ -10,7 +10,7 @@ WORKDIR /pilosa COPY . ./ -RUN make build FLAGS="-o build/pilosa" ${MAKE_FLAGS} +RUN make build FLAGS="-o build/featurebase" ${MAKE_FLAGS} ##################### ### Pilosa runner ### @@ -22,7 +22,7 @@ LABEL maintainer "dev@molecula.com" RUN apk add --no-cache curl jq -COPY --from=pilosa-builder /pilosa/build/pilosa / +COPY --from=pilosa-builder /pilosa/build/featurebase / COPY LICENSE /LICENSE COPY NOTICE /NOTICE diff --git a/Dockerfile.runner b/Dockerfile.runner index 3b1be7fd9..12f49e13c 100644 --- a/Dockerfile.runner +++ b/Dockerfile.runner @@ -10,7 +10,7 @@ WORKDIR /pilosa COPY . ./ -RUN make build FLAGS="-o build/pilosa" ${MAKE_FLAGS} +RUN make build FLAGS="-o build/featurebase" ${MAKE_FLAGS} FROM moleculacorp/idk as idk LABEL maintainer "dev@molecula.com" @@ -18,6 +18,6 @@ RUN apt-get update -y RUN apt-get install -y bash curl jq -COPY --from=pilosa-builder /pilosa/build/pilosa / +COPY --from=pilosa-builder /pilosa/build/featurebase / COPY testBackupRestore.sh / CMD ["bash","/testBackupRestore.sh"] diff --git a/Makefile b/Makefile index 335685187..d56d9d284 100644 --- a/Makefile +++ b/Makefile @@ -216,13 +216,13 @@ docker-build: vendor --build-arg GO_VERSION=$(GO_VERSION) \ --build-arg MAKE_FLAGS="TRIAL_DEADLINE=$(TRIAL_DEADLINE) GOOS=$(GOOS) GOARCH=$(GOARCH)" \ --target pilosa-builder \ - --tag pilosa:build . - docker create --name pilosa-build pilosa:build - mkdir -p build/pilosa-$(VERSION_ID) - docker cp pilosa-build:/pilosa/build/. ./build/pilosa-$(VERSION_ID) - cp NOTICE LICENSE ./build/pilosa-$(VERSION_ID) - docker rm pilosa-build - tar -cvz -C build -f build/pilosa-$(VERSION_ID).tar.gz pilosa-$(VERSION_ID)/ + --tag featurebase:build . + docker create --name featurebase-build featurebase:build + mkdir -p build/featurebase-$(VERSION_ID) + docker cp featurebase-build:/pilosa/build/. ./build/featurebase-$(VERSION_ID) + cp NOTICE LICENSE ./build/featurebase-$(VERSION_ID) + docker rm featurebase-build + tar -cvz -C build -f build/featurebase-$(VERSION_ID).tar.gz featurebase-$(VERSION_ID)/ # Create Docker image from Dockerfile docker-image: vendor diff --git a/docker-compose-3.yml b/docker-compose-3.yml index ef31424d0..1998fcf97 100644 --- a/docker-compose-3.yml +++ b/docker-compose-3.yml @@ -1,7 +1,7 @@ version: "3" services: pilosa0: - image: build/pilosa + image: build/featurebase build: context: . dockerfile: Dockerfile.pilosa @@ -25,7 +25,7 @@ services: timeout: 5s retries: 5 pilosa1: - image: build/pilosa + image: build/featurebase build: context: . dockerfile: Dockerfile.pilosa @@ -44,7 +44,7 @@ services: volumes: - data:/data pilosa2: - image: build/pilosa + image: build/featurebase build: context: . dockerfile: Dockerfile.pilosa @@ -63,7 +63,7 @@ services: volumes: - data:/data pilosax: - image: build/pilosa + image: build/featurebase build: context: . dockerfile: Dockerfile.pilosa From 0ec855766ca3e74d4babd07868ab1634a4f630c5 Mon Sep 17 00:00:00 2001 From: Samir Patel <48686912+54mir@users.noreply.github.com> Date: Thu, 16 Sep 2021 16:38:40 -0500 Subject: [PATCH 3/7] Rename in make docker-image --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index d56d9d284..520c57e3b 100644 --- a/Makefile +++ b/Makefile @@ -229,8 +229,8 @@ docker-image: vendor docker build \ --build-arg GO_VERSION=$(GO_VERSION) \ --build-arg MAKE_FLAGS="TRIAL_DEADLINE=$(TRIAL_DEADLINE)" \ - --tag pilosa:$(VERSION) . - @echo Created docker image: pilosa:$(VERSION) + --tag featurebase:$(VERSION) . + @echo Created docker image: featurebase:$(VERSION) # Create docker image (alias) docker: docker-image # alias From 746ffd4bd17841b899b08bbf9728b8d8c29f74f2 Mon Sep 17 00:00:00 2001 From: Samir Patel <48686912+54mir@users.noreply.github.com> Date: Thu, 16 Sep 2021 16:42:11 -0500 Subject: [PATCH 4/7] Rename in docker-tag-push --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 520c57e3b..4a89aa66c 100644 --- a/Makefile +++ b/Makefile @@ -237,7 +237,7 @@ docker: docker-image # alias # Tag and push a Docker image docker-tag-push: vendor - docker tag "pilosa:$(VERSION)" $(DOCKER_TARGET) + docker tag "featurebase:$(VERSION)" $(DOCKER_TARGET) docker push $(DOCKER_TARGET) @echo Pushed docker image: $(DOCKER_TARGET) From 4699c840bc8919ce7c4b5ed64c1be33f61e0b7f4 Mon Sep 17 00:00:00 2001 From: Samir Patel <48686912+54mir@users.noreply.github.com> Date: Wed, 22 Sep 2021 11:50:31 -0500 Subject: [PATCH 5/7] More rename to work with backup and cluster tests --- Dockerfile | 2 +- Dockerfile.pilosa | 5 +++-- docker-compose-3.yml | 8 ++++---- testBackupRestore.sh | 12 ++++++------ 4 files changed, 14 insertions(+), 13 deletions(-) diff --git a/Dockerfile b/Dockerfile index db864ed81..115855034 100644 --- a/Dockerfile +++ b/Dockerfile @@ -52,5 +52,5 @@ ENV PILOSA_DATA_DIR /data ENV PILOSA_BIND 0.0.0.0:10101 ENV PILOSA_BIND_GRPC 0.0.0.0:20101 -ENTRYPOINT ["/pilosa"] +ENTRYPOINT ["/featurebase"] CMD ["server"] diff --git a/Dockerfile.pilosa b/Dockerfile.pilosa index c830a8862..fd8629946 100644 --- a/Dockerfile.pilosa +++ b/Dockerfile.pilosa @@ -33,6 +33,7 @@ VOLUME /data ENV PILOSA_DATA_DIR /data ENV PILOSA_BIND 0.0.0.0:10101 ENV PILOSA_BIND_GRPC 0.0.0.0:20101 - -ENTRYPOINT ["/pilosa"] +RUN echo RUNNING DOCKERFILE.PILOSA +CMD echo DOCKERFILE.PILOSA +ENTRYPOINT ["/featurebase"] CMD ["server"] diff --git a/docker-compose-3.yml b/docker-compose-3.yml index 1998fcf97..ef31424d0 100644 --- a/docker-compose-3.yml +++ b/docker-compose-3.yml @@ -1,7 +1,7 @@ version: "3" services: pilosa0: - image: build/featurebase + image: build/pilosa build: context: . dockerfile: Dockerfile.pilosa @@ -25,7 +25,7 @@ services: timeout: 5s retries: 5 pilosa1: - image: build/featurebase + image: build/pilosa build: context: . dockerfile: Dockerfile.pilosa @@ -44,7 +44,7 @@ services: volumes: - data:/data pilosa2: - image: build/featurebase + image: build/pilosa build: context: . dockerfile: Dockerfile.pilosa @@ -63,7 +63,7 @@ services: volumes: - data:/data pilosax: - image: build/featurebase + image: build/pilosa build: context: . dockerfile: Dockerfile.pilosa diff --git a/testBackupRestore.sh b/testBackupRestore.sh index 8f9617e7f..6d0dbc67f 100755 --- a/testBackupRestore.sh +++ b/testBackupRestore.sh @@ -13,19 +13,19 @@ STATUS=$STATUS timeout -s TERM $TIMEOUT bash -c \ done;' echo "NOW DO STUFF" datagen --source kitchensink_keyed -e 9999 --pilosa.index sink --pilosa.batch-size 10000 --pilosa.hosts pilosa0:10101 -before=$(/pilosa chksum --host pilosa0:10101) -/pilosa backup -o backupdir --host pilosa0:10101 +before=$(/featurebase chksum --host pilosa0:10101) +/featurebase backup -o backupdir --host pilosa0:10101 curl -X DELETE -s pilosa0:10101/index/sink -/pilosa restore -s backupdir --host pilosa0:10101 -after=$(/pilosa chksum --host pilosa0:10101) +/featurebase restore -s backupdir --host pilosa0:10101 +after=$(/featurebase chksum --host pilosa0:10101) if [ "$before" = "$after" ]; then echo "PASS Cluster" else echo "FAIL Single" exit 1 fi -/pilosa restore -s backupdir --host pilosax:10101 -single=$(/pilosa chksum --host pilosax:10101) +/featurebase restore -s backupdir --host pilosax:10101 +single=$(/featurebase chksum --host pilosax:10101) if [ "$before" = "$single" ]; then echo "PASS Single" exit 0 From 839dd1cd43441130aa28d78ed83a30a842f595a7 Mon Sep 17 00:00:00 2001 From: Samir Patel <48686912+54mir@users.noreply.github.com> Date: Wed, 22 Sep 2021 16:02:02 -0500 Subject: [PATCH 6/7] Remove prints --- Dockerfile.pilosa | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Dockerfile.pilosa b/Dockerfile.pilosa index fd8629946..a24c70ec7 100644 --- a/Dockerfile.pilosa +++ b/Dockerfile.pilosa @@ -33,7 +33,6 @@ VOLUME /data ENV PILOSA_DATA_DIR /data ENV PILOSA_BIND 0.0.0.0:10101 ENV PILOSA_BIND_GRPC 0.0.0.0:20101 -RUN echo RUNNING DOCKERFILE.PILOSA -CMD echo DOCKERFILE.PILOSA + ENTRYPOINT ["/featurebase"] CMD ["server"] From 5324431ab049dfeece400b1716347731f114d66a Mon Sep 17 00:00:00 2001 From: Samir Patel <48686912+54mir@users.noreply.github.com> Date: Thu, 16 Sep 2021 16:12:57 -0500 Subject: [PATCH 7/7] Rename pilosa to featurebase --- .circleci/config.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 0ae2f1f43..30b2ef5e4 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -35,7 +35,7 @@ commands: - checkout - restore-mod-cache skip-if-root-unchanged: - description: "skips the parent job if the PR includes no changes to pilosa" + description: "skips the parent job if the PR includes no changes to featurebase" steps: - run: | ROOT_CHANGED_FILES="$(git diff --name-only HEAD $(git merge-base master HEAD) | grep -v '^lattice/')" || true @@ -202,7 +202,7 @@ jobs: version: 19.03.13 # see https://support.circleci.com/hc/en-us/articles/360050934711 - run: echo -n $DOCKER_PASS | docker login -u $DOCKER_USER --password-stdin - run: make docker GO_VERSION=1.15.8 - - run: docker run pilosa:$(git describe --tags) help + - run: docker run featurebase:$(git describe --tags) help dockerhub-upload-unstable: executor: name: golang @@ -212,8 +212,8 @@ jobs: version: 19.03.13 # see https://support.circleci.com/hc/en-us/articles/360050934711 - run: echo -n $DOCKER_PASS | docker login -u $DOCKER_USER --password-stdin - run: make docker - - run: docker run pilosa:$(git describe --tags) help - - run: make docker-tag-push DOCKER_TARGET=moleculacorp/pilosa:<< pipeline.git.branch >> + - run: docker run featurebase:$(git describe --tags) help + - run: make docker-tag-push DOCKER_TARGET=moleculacorp/featurebase:<< pipeline.git.branch >> dockerhub-upload-stable: executor: name: golang @@ -223,9 +223,9 @@ jobs: version: 19.03.13 # see https://support.circleci.com/hc/en-us/articles/360050934711 - run: echo -n $DOCKER_PASS | docker login -u $DOCKER_USER --password-stdin - run: make docker - - run: docker run pilosa:$(git describe --tags) help - - run: make docker-tag-push DOCKER_TARGET=moleculacorp/pilosa:<< pipeline.git.tag >> - - run: make docker-tag-push DOCKER_TARGET=moleculacorp/pilosa:latest + - run: docker run featurebase:$(git describe --tags) help + - run: make docker-tag-push DOCKER_TARGET=moleculacorp/featurebase:<< pipeline.git.tag >> + - run: make docker-tag-push DOCKER_TARGET=moleculacorp/featurebase:latest workflows: build: