#!/bin/bash # # Copyright (c) 2022 Wind River Systems, Inc. # # SPDX-License-Identifier: Apache-2.0 # set -e source $(dirname "$0")/lib/job_utils.sh load_build_env remote_cli_dir="$WORKSPACE_ROOT/std/build-remote-cli" oidc_auth="$REPO_ROOT/cgcs-root/stx/oidc-auth-armada-app/oidc-auth-tools/oidcauthtools/oidcauthtools/oidc_auth.py" dst_dir="$PUBLISH_DIR/outputs/remote-cli" notice "publishing remote-cli to $dst_dir" maybe_run mkdir -p "$dst_dir" if [[ -d "$remote_cli_dir" ]] || $DRY_RUN ; then maybe_run find "$remote_cli_dir" -mindepth 1 -maxdepth 1 -name '*.tgz' -exec \ cp -v -f --preserve=timestamps -t "$dst_dir" '{}' '+' fi if [[ -f "$oidc_auth" ]] || $DRY_RUN ; then maybe_run cp -v -f --preserve=mode,timestamps "$oidc_auth" "$dst_dir/oidc-auth" maybe_run chmod +x "$dst_dir/oidc-auth" fi