Skip to content

Commit

Permalink
ci: release
Browse files Browse the repository at this point in the history
  • Loading branch information
SalHe committed Jan 4, 2024
1 parent 14cc4b9 commit 146d2cd
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 15 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,13 @@ jobs:
file: ./scripts/ci-release.Dockerfile
push: false
tags: bysp:latest
build-args: |
os_image=centos:centos7
- name: Run Docker container
run: |
docker run --name bysp bysp:latest
docker run -itd -v "${PWD}:/yasqlplus" --name bysp bysp:latest
docker exec bysp /yasqlplus/scripts/ci-release-build.sh
docker cp bysp:/yasqlplus/target/release/yasqlplus ./yasqlplus-linux-compatible-x86_64
- name: Upload release
env:
Expand Down Expand Up @@ -108,8 +111,9 @@ jobs:
apt-get install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
docker build -t bysp:latest -f ./scripts/ci-release.Dockerfile .
docker run --name bysp bysp:latest
docker build --build-arg=os_image=arm64v8/centos:centos7 -t bysp:latest -f ./scripts/ci-release.Dockerfile .
docker run -itd -v "${PWD}:/yasqlplus" --name bysp bysp:latest
docker exec bysp /yasqlplus/scripts/ci-release-build.sh
docker cp bysp:/yasqlplus/target/release/yasqlplus /artifacts/yasqlplus-linux-compatible-aarch64
- name: Upload release
env:
Expand Down
4 changes: 2 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name = "yasqlplus"
authors = ["SalHe <salhe@qq.com>"]
description = "YaSQL+ is an alternative for yasql."
version = "0.1.0"
version = "0.1.1"
edition = "2021"
license = "MIT"

Expand Down
4 changes: 1 addition & 3 deletions scripts/ci-release-build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,8 @@ cat >>/etc/ld.so.conf <<EOF
/usr/lib64/clang-private
EOF

cat /etc/ld.so.conf

source /opt/rh/devtoolset-7/enable
source /opt/rh/llvm-toolset-7/enable
source /opt/rh/llvm-toolset-7.0/enable
source "$HOME/.cargo/env"

ldconfig
Expand Down
8 changes: 3 additions & 5 deletions scripts/ci-release.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
FROM centos:centos7
ARG os_image=centos:centos7
FROM ${os_image}

RUN yum install -y wget git centos-release-scl centos-release-scl-rh
RUN yum install -y devtoolset-7-gcc devtoolset-7-gcc-g++ llvm-toolset-7 gcc g++
RUN yum install -y devtoolset-7-gcc devtoolset-7-gcc-g++ llvm-toolset-7.0-clang llvm-toolset-7.0-clang-libs gcc g++
RUN sh -c "$(curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs)" -- -y

COPY ./ /yasqlplus
RUN /yasqlplus/scripts/ci-release-build.sh

ENTRYPOINT [ "bash" ]
2 changes: 1 addition & 1 deletion yasqlplus-client/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "yasqlplus-client"
version = "0.1.0"
version = "0.1.1"
edition = "2021"
license = "MIT"

Expand Down

0 comments on commit 146d2cd

Please sign in to comment.