diff --git a/.github/workflows/docker-release.yml b/.github/workflows/docker-release.yml index 547ed35..086d013 100644 --- a/.github/workflows/docker-release.yml +++ b/.github/workflows/docker-release.yml @@ -7,8 +7,8 @@ on: description: 'Name for the release' required: true type: string - soroban_cli_version: - description: 'Soroban CLI version' + stellar_cli_version: + description: 'Stellar CLI version' required: false type: string rust_version: @@ -66,7 +66,7 @@ jobs: context: ./docker push: true build-args: | - SOROBAN_CLI_VERSION=${{ inputs.soroban_cli_version }} + STELLAR_CLI_VERSION=${{ inputs.stellar_cli_version }} RUST_VERSION=${{ inputs.rust_version }} tags: | ghcr.io/${{ github.repository }}:${{ github.sha }} diff --git a/docker/Dockerfile b/docker/Dockerfile index a7e03d6..13fe149 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -31,14 +31,14 @@ RUN if [ "$RUST_VERSION" ]; then \ # Install the wasm32-unknown-unknown target RUN rustup target add wasm32-unknown-unknown -# Define the version argument for soroban-cli with a default value -ARG SOROBAN_CLI_VERSION="" +# Define the version argument for stellar-cli with a default value +ARG STELLAR_CLI_VERSION="" -# Install soroban-cli -RUN if [ -z "$SOROBAN_CLI_VERSION" ]; then \ - cargo install --locked soroban-cli --features opt; \ +# Install stellar-cli +RUN if [ -z "$STELLAR_CLI_VERSION" ]; then \ + cargo install --locked stellar-cli --features opt; \ else \ - cargo install --locked soroban-cli --features opt --version $SOROBAN_CLI_VERSION; \ + cargo install --locked stellar-cli --features opt --version $STELLAR_CLI_VERSION; \ fi # Print the version of rustc @@ -47,8 +47,8 @@ RUN rustc --version # Print the version of cargo RUN cargo --version -# Print the version of soroban-cli -RUN soroban --version +# Print the version of stellar-cli +RUN stellar --version # Specify the package to build ENV PACKAGE=${PACKAGE} diff --git a/docker/entrypoint.sh b/docker/entrypoint.sh index 1cd0ce2..f837ff4 100644 --- a/docker/entrypoint.sh +++ b/docker/entrypoint.sh @@ -35,8 +35,8 @@ rustc --version # Print Cargo version cargo --version -# Print Soroban version -soroban --version +# Print Stellar version +stellar --version # Check if the Cargo.toml file exists if [ ! -f "Cargo.toml" ]; then @@ -59,13 +59,13 @@ fi # Check if the PACKAGE is defined add it to the build command if [ "$PACKAGE" ]; then - soroban contract build --package $PACKAGE --out-dir ${OUTPUT} + stellar contract build --package $PACKAGE --out-dir ${OUTPUT} # Set the package name to the provided package name PACKAGE_NAME=$PACKAGE else # Get the package name from the Cargo.toml file PACKAGE_NAME=$(grep -m1 '^name =' Cargo.toml | cut -d '"' -f2) - soroban contract build --out-dir ${OUTPUT} + stellar contract build --out-dir ${OUTPUT} fi # Verify that the build was successful @@ -118,7 +118,7 @@ fi cd ${RELEASE_DIR} # Optimize the WASM file -soroban contract optimize --wasm ${WASM_FILE_NAME} --wasm-out ${WASM_FILE_NAME} +stellar contract optimize --wasm ${WASM_FILE_NAME} --wasm-out ${WASM_FILE_NAME} # Verify that the optimized.wasm file exists if [ ! -f "${RELEASE_DIR}/${WASM_FILE_NAME}" ]; then @@ -127,7 +127,7 @@ if [ ! -f "${RELEASE_DIR}/${WASM_FILE_NAME}" ]; then fi # Get the CLI version -CLI_VERSION=$(soroban --version | grep -oP 'soroban \K\S+') +CLI_VERSION=$(stellar --version | grep -oP 'stellar \K\S+') # Calculate the SHA256 hash of the wasm file WASM_FILE_SHA256=$(sha256sum $WASM_FILE_NAME | cut -d ' ' -f 1)