-
Notifications
You must be signed in to change notification settings - Fork 1
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
Ubuntu 2204 #2
Merged
Merged
Ubuntu 2204 #2
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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,41 @@ | ||
name: After merging PR | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
- build_test | ||
|
||
# Allow to run this workflow manually from the Actions tab | ||
workflow_dispatch: | ||
|
||
jobs: | ||
devel-tag-push: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
# TODO: Review the below list of dependencies | ||
- name: Install the Build dependencies | ||
run: | | ||
sudo apt update -y | ||
sudo apt install -y libunwind-dev | ||
sudo apt install -y --no-install-recommends python3 libtirpc3 init \ | ||
python3-pip ssh rsync lvm2 less software-properties-common \ | ||
sudo curl wget git build-essential automake autoconf automake libtool \ | ||
flex bison libssl-dev pkg-config uuid-dev acl-dev zlib1g-dev \ | ||
libxml2-dev libxml2-utils liburcu-dev xfsprogs gdb attr \ | ||
libgoogle-perftools-dev zfsutils-linux screen libsqlite3-dev sqlite3 \ | ||
debmake python3-debian debhelper dh-python \ | ||
libaio-dev libdb-dev libfuse-dev libibverbs-dev liblvm2-dev \ | ||
libncurses5-dev librdmacm-dev libreadline-dev python3-all-dev | ||
- name: Install Crystal | ||
run: | | ||
curl -fsSL https://crystal-lang.org/install.sh | sudo bash | ||
- name: Build Debian packages | ||
run: | | ||
PACKAGING_GPG_SIGNING_KEY="${{ secrets.PACKAGING_GPG_SIGNING_KEY }}" ./generate_deb_packages_ubuntu_2204.sh | ||
- name: Deploy | ||
uses: peaceiris/actions-gh-pages@v3 | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
publish_dir: ./output |
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
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
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,90 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
|
||
MOANA_BRANCH=1.0.0-beta.1 | ||
GLUSTERFS_BRANCH=kadalu_1 | ||
DISTRO_VERSION=22.04 | ||
DISTRO=ubuntu | ||
VERSION=1.0.0-beta.1 | ||
MAJOR_VERSION=1 | ||
PKG_KADALU_STORAGE_MANAGER=kadalu-storage-manager | ||
PKG_KADALU_STORAGE=kadalu-storage | ||
|
||
rm -rf build | ||
mkdir -p build | ||
|
||
# Clone and Checkout GlusterFS | ||
git clone https://github.com/kadalu/glusterfs.git build/${PKG_KADALU_STORAGE}-${VERSION} | ||
cd build/${PKG_KADALU_STORAGE}-${VERSION} | ||
git checkout -b ${GLUSTERFS_BRANCH} origin/${GLUSTERFS_BRANCH} | ||
cd ../../ | ||
|
||
# Clone and Checkout Moana | ||
git clone https://github.com/kadalu/moana.git build/${PKG_KADALU_STORAGE_MANAGER}-${VERSION} | ||
cd build/${PKG_KADALU_STORAGE_MANAGER}-${VERSION} | ||
git fetch --all --tags | ||
git checkout -b ${MOANA_BRANCH} tags/${MOANA_BRANCH} | ||
cd ../../ | ||
|
||
# Create tar | ||
cd build/ | ||
tar cvzf ${PKG_KADALU_STORAGE_MANAGER}-${VERSION}.tar.gz ${PKG_KADALU_STORAGE_MANAGER}-${VERSION} | ||
tar cvzf ${PKG_KADALU_STORAGE}-${VERSION}.tar.gz ${PKG_KADALU_STORAGE}-${VERSION} | ||
cd .. | ||
|
||
# Copy Debian meta files | ||
cp -r build/${PKG_KADALU_STORAGE_MANAGER}-${VERSION}/packaging/moana/debian build/${PKG_KADALU_STORAGE_MANAGER}-${VERSION}/ | ||
cp -r build/${PKG_KADALU_STORAGE_MANAGER}-${VERSION}/packaging/glusterfs/debian build/${PKG_KADALU_STORAGE}-${VERSION}/ | ||
|
||
# Overwrite the Changelog file | ||
cp changelogs/moana/changelog-${MAJOR_VERSION} build/${PKG_KADALU_STORAGE_MANAGER}-${VERSION}/debian/changelog | ||
cp changelogs/glusterfs/changelog-${MAJOR_VERSION} build/${PKG_KADALU_STORAGE}-${VERSION}/debian/changelog | ||
|
||
# Build Moana deb packages | ||
cd build/${PKG_KADALU_STORAGE_MANAGER}-${VERSION}/ | ||
debmake -b":python3" | ||
debuild -eVERSION=${VERSION} | ||
cd ../../ | ||
|
||
# Build GlusterFS deb packages | ||
cd build/${PKG_KADALU_STORAGE}-${VERSION}/ | ||
debmake -b":python3" | ||
debuild | ||
cd ../../ | ||
|
||
# Clone the existing repo and checkout gh-pages to get the current output directory | ||
git clone https://github.com/kadalu-tech/pkgs.git build/output | ||
cd build/output | ||
git checkout -b gh-pages origin/gh-pages | ||
cd ../../ | ||
|
||
rm -rf output | ||
mkdir output | ||
# TODO: Add previous versions when a new version is released | ||
cp -r build/output/${MAJOR_VERSION} output/${MAJOR_VERSION} | ||
|
||
output_dir=output/${MAJOR_VERSION}/${DISTRO}/${DISTRO_VERSION} | ||
rm -rf ${output_dir} | ||
mkdir -p ${output_dir} | ||
|
||
# Copy generated Deb files | ||
cp build/*.deb ${output_dir}/ | ||
|
||
# List of packages | ||
cd ${output_dir} | ||
dpkg-scanpackages --multiversion . > Packages | ||
gzip -k -f Packages | ||
|
||
# Import the Signing key from env var | ||
echo -n "$PACKAGING_GPG_SIGNING_KEY" | base64 --decode | gpg --import | ||
gpg --list-keys | ||
|
||
# Release, Release.gpg & InRelease | ||
apt-ftparchive release . > Release | ||
gpg --local-user "[email protected]" -abs -o - Release > Release.gpg | ||
gpg --local-user "[email protected]" --clearsign -o - Release > InRelease | ||
gpg --armor --export "[email protected]" > KEY.gpg | ||
|
||
echo "deb https://kadalu.tech/pkgs/${MAJOR_VERSION}/${DISTRO}/${DISTRO_VERSION} ./" > sources.list | ||
cd ../../../../ |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you add the line: "sudo apt install -y libunwind-dev"
between "sudo apt update -y" and "sudo apt install -y --no-install-recommends...." all would work.
Example and test run are here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the help.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I ran into this same issue, and this solved it for me as well (the libunwind-14 and libunwind-dev conflict). But I don't really understand why? Is that some issue with something that is depending on libunwind? And why would updating them in two different steps solve the problem? What prevents this from happening again? It's kind of awkward to have this explicit update in my CI without any real explanation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @pieter3d!
Here is the explanation. It is just a related to dependencies bug. Nobody can prevent it.