Skip to content

Latest commit

 

History

History
116 lines (86 loc) · 5.3 KB

File metadata and controls

116 lines (86 loc) · 5.3 KB

marketplace

As an end user, you should have little use for the contents of this directory and almost certainly want to either use the Marketplace listing directly or simple. If you're a Neo4j employee, updating the Google Marketplace listing, these notes may be helpful.

Updating the Listing

To submit an updated listing, run ./makeArchive.sh. You'll then need to upload that archive to the neo4j-deployment-packages bucket in neo4j-aura-gcp.

❯ gcloud alpha storage cp marketplace/archive.zip gs://neo4j-deployment-packages

After that you can upload the archive to the Producer Portal here and hit submit.

Open Source Worksheet

Google requires completion of an open source worksheet. Ours is here.

Build VM Image For Enterprise Edition

You only need to do this occassionally, when the underlying OS is out of date. The image has no Neo4j bits on it, so you don't need to do it when you bump the Neo4j version.

Open up a cloud shell. While you could do this on your local machine with gcloud, it's way easier to just use a cloud shell.

Now we need to decide what OS image to use. We're using the latest RHEL. You can figure out what that is by running:

gcloud compute images list

Then you're going to want to set these variables based on what you found above.

IMAGE_VERSION=v20231212
IMAGE_NAME=rhel-9-${IMAGE_VERSION}

Next, create an image for each license:

LICENSE=neo4j-enterprise-edition-v9-byol
INSTANCE=${LICENSE}-${IMAGE_VERSION}
gcloud compute instances create ${INSTANCE} \
--project "neo4j-aura-gcp" \
--zone "us-central1-f" \
--machine-type "n2-standard-8" \
--network "default" \
--maintenance-policy "MIGRATE" \
--scopes default="https://www.googleapis.com/auth/cloud-platform" \
--image "https://www.googleapis.com/compute/v1/projects/rhel-cloud/global/images/${IMAGE_NAME}" --boot-disk-size "20" \
--boot-disk-type "pd-ssd" \
--boot-disk-device-name ${INSTANCE} \
--no-boot-disk-auto-delete \
--scopes "storage-rw"

Now we're going to delete the VM. We'll be left with its boot disk. This command takes a few minutes to run and doesn't print anything.

LICENSE=neo4j-enterprise-edition-byol
INSTANCE=${LICENSE}-${IMAGE_VERSION}
gcloud compute instances delete ${INSTANCE} \
--project "neo4j-aura-gcp" \
--zone "us-central1-f"

We were previously piping yes, but that doesn't seem to be working currently, so you'll have to type "y" a few times.

gcloud compute images create ${INSTANCE} \
--project "neo4j-aura-gcp" \
--source-disk projects/neo4j-aura-gcp/zones/us-central1-f/disks/${INSTANCE} \
--licenses projects/neo4j-aura-gcp/global/licenses/neo4j-enterprise-edition-byol \
--description ADD_DESCRIPTION

Grant allAuthenticatedUsers account access to Compute Image User on the new image or else the submission will fail

Update the IMAGE_VERSION in c2d_deployment_configuration.json and instance_group.py files before making archive and submitting on portal

Build VM Image For Community Edition

You only need to do this occassionally, when the underlying OS is out of date. The image has no Neo4j bits on it, so you don't need to do it when you bump the Neo4j version.

Open up a cloud shell. While you could do this on your local machine with gcloud, it's way easier to just use a cloud shell.

Now we need to decide what OS image to use. We're using the latest RHEL. You can figure out what that is by running:

gcloud compute images list

Then you're going to want to set these variables based on what you found above.

IMAGE_VERSION=v20220406
IMAGE_NAME=rhel-9-${IMAGE_VERSION}
LICENSE=neo4j-community-edition-default-v9
INSTANCE=${LICENSE}-${IMAGE_VERSION}

Next, create an image for each license:

gcloud compute instances create ${INSTANCE} \
--project "neo4j-aura-gcp" \
--zone "us-central1-f" \
--machine-type "n2-standard-8" \
--network "default" \
--maintenance-policy "MIGRATE" \
--scopes default="https://www.googleapis.com/auth/cloud-platform" \
--image "https://www.googleapis.com/compute/v1/projects/rhel-cloud/global/images/${IMAGE_NAME}" --boot-disk-size "20" \
--boot-disk-type "pd-ssd" \
--boot-disk-device-name ${INSTANCE} \
--no-boot-disk-auto-delete \
--scopes "storage-rw"

Now we're going to delete the VM. We'll be left with its boot disk. This command takes a few minutes to run and doesn't print anything.

gcloud compute instances delete ${INSTANCE} \
--project "neo4j-aura-gcp" \
--zone "us-central1-f"

We were previously piping yes, but that doesn't seem to be working currently, so you'll have to type "y" a few times.

gcloud compute images create ${INSTANCE} \
--project "neo4j-aura-gcp" \
--source-disk projects/neo4j-aura-gcp/zones/us-central1-f/disks/${INSTANCE} \
--description neo4j-community
--licenses projects/neo4j-aura-gcp/global/licenses/neo4j-community-edition-default \

Grant allAuthenticatedUsers account access to Compute Image User on the new image or else the submission will fail

Update the IMAGE_VERSION in c2d_deployment_configuration.json and instance_group.py files before making archive and submitting on portal