Skip to content

Adds workflows to build release binaries and push to S3 #315

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 9 commits into from
Apr 16, 2024

Conversation

roshkhatri
Copy link
Member

@roshkhatri roshkhatri commented Apr 12, 2024

related to

Adds workflows to build Valkey binaries and push to S3 to make it available to download from the website

I have commented the macOS build code as we need code-sign the binaries for Mac and need more info on that.

The Workflows can be triggered by pushing a release to the repo and the other option is manually by one of the Maintainers. For example:
Screenshot 2024-04-15 at 4 32 40 PM

Once the workflow triggers, it will generate a matrix of Jobs for the platforms we need to build from utils/releasetools/build-config.json and then the respective Jobs are triggered. These jobs make Valkey with respect to the platform binaries we want to release and would push to a private S3 bucket.

Copy link
Collaborator

@hpatro hpatro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. How did we test this?

@roshkhatri
Copy link
Member Author

How did we test this?

I have tested the binaries on my ec2 and the uploads are tested by pushing the binaries to private s3 bucket.
Screenshot 2024-04-12 at 8 13 14 PM

If we want to change any configurations of how we build we can make changes to the workflows to adapt that.

@roshkhatri
Copy link
Member Author

roshkhatri commented Apr 15, 2024

Screenshot 2024-04-15 at 4 32 40 PM

Now this Workflow will be triggered when a release has been published

Also updated the top comment.

Signed-off-by: Roshan Khatri <[email protected]>
Signed-off-by: Roshan Khatri <[email protected]>
with:
arch: aarch64
distro: ${{matrix.distro.target}}
install: apt-get update && apt-get install -y build-essential libssl-dev libjemalloc-dev
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are you including libejemalloc-dev? We aren't linking against it.

Copy link
Member

@madolson madolson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Took a bit of a deeper look, The code looks mostly fine, but had some minor comments.


- name: Configure AWS credentials
run: |
aws configure set region us-east-1
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the bucket was in us-west-2? Does this even matter?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But I will change to the correct location

jobs:
build-valkey:
# Capture source tarball and generate checksum for it
name: Build package ${{ matrix.distro.target }} ${{ matrix.distro.arch }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
name: Build package ${{ matrix.distro.target }} ${{ matrix.distro.arch }}
name: Build package ${{ matrix.distro.target }} ${{ matrix.distro.arch }}

@@ -0,0 +1,79 @@
name: Reusable workflow to build binary packages into S3 bucket
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't really that re-usable if it's only used for linux.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can also be used to build Nightly/Weekly build. I will remove it from the description for now, might add it later.

ref: ${{ inputs.version }}

- name: Install dependencies
run: sudo apt-get update && sudo apt-get install -y build-essential libssl-dev jq wget
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems weird we wouldn't install aws cli here as well.

run: sudo apt-get update && sudo apt-get install -y build-essential libssl-dev jq wget

- name: Set JEMALLOC Flags
run: JEMALLOC_CONFIGURE_OPTS="--with-lg-page=16"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are we configuring the lg-page to be 16? This will use more memory.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes just realized it may also increase chances of fragmentation I guess. Removing this.

Signed-off-by: Roshan Khatri <[email protected]>
Signed-off-by: Roshan Khatri <[email protected]>
@roshkhatri roshkhatri requested review from bjosv and madolson April 16, 2024 13:31
Copy link
Member

@madolson madolson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's okay to start with, then we can test it with 7.2.5 release.

@madolson madolson merged commit b16e647 into valkey-io:unstable Apr 16, 2024
zuiderkwast pushed a commit to zuiderkwast/placeholderkv that referenced this pull request Apr 17, 2024
[related to](valkey-io#230)

Adds workflows to build Valkey binaries and push to S3 to make it
available to download from the website

The Workflows can be triggered by pushing a release to the repo and the
other option is manually by one of the Maintainers.

Once the workflow triggers, it will generate a matrix of Jobs for the
platforms we need to build from `utils/releasetools/build-config.json`
and then the respective Jobs are triggered. These jobs make Valkey with
respect to the platform binaries we want to release and would push to a
private S3 bucket.

---------

Signed-off-by: Roshan Khatri <[email protected]>
PatrickJS pushed a commit to PatrickJS/placeholderkv that referenced this pull request Apr 24, 2024
[related to](valkey-io#230)

Adds workflows to build Valkey binaries and push to S3 to make it
available to download from the website

The Workflows can be triggered by pushing a release to the repo and the
other option is manually by one of the Maintainers.

Once the workflow triggers, it will generate a matrix of Jobs for the
platforms we need to build from `utils/releasetools/build-config.json`
and then the respective Jobs are triggered. These jobs make Valkey with
respect to the platform binaries we want to release and would push to a
private S3 bucket.

---------

Signed-off-by: Roshan Khatri <[email protected]>
roshkhatri added a commit to roshkhatri/valkey that referenced this pull request Jul 31, 2024
[related to](valkey-io#230)

Adds workflows to build Valkey binaries and push to S3 to make it
available to download from the website

The Workflows can be triggered by pushing a release to the repo and the
other option is manually by one of the Maintainers.

Once the workflow triggers, it will generate a matrix of Jobs for the
platforms we need to build from `utils/releasetools/build-config.json`
and then the respective Jobs are triggered. These jobs make Valkey with
respect to the platform binaries we want to release and would push to a
private S3 bucket.

---------

Signed-off-by: Roshan Khatri <[email protected]>
roshkhatri added a commit to roshkhatri/valkey that referenced this pull request Jul 31, 2024
[related to](valkey-io#230)

Adds workflows to build Valkey binaries and push to S3 to make it
available to download from the website

The Workflows can be triggered by pushing a release to the repo and the
other option is manually by one of the Maintainers.

Once the workflow triggers, it will generate a matrix of Jobs for the
platforms we need to build from `utils/releasetools/build-config.json`
and then the respective Jobs are triggered. These jobs make Valkey with
respect to the platform binaries we want to release and would push to a
private S3 bucket.

---------

Signed-off-by: Roshan Khatri <[email protected]>
@roshkhatri roshkhatri deleted the revamp-workflows branch September 3, 2024 16:18
madolson pushed a commit that referenced this pull request Sep 30, 2024
…315) (#857)

[related to](#230)

Adds workflows to build Valkey binaries and push to S3 to make it
available to download from the website

The Workflows can be triggered by pushing a release to the repo and the
other option is manually by one of the Maintainers.

Once the workflow triggers, it will generate a matrix of Jobs for the
platforms we need to build from `utils/releasetools/build-config.json`
and then the respective Jobs are triggered. These jobs make Valkey with
respect to the platform binaries we want to release and would push to a
private S3 bucket.

---------

Signed-off-by: Roshan Khatri <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants