CI: Remove vestiges of travis and appveyor
This completes the initial transition to Github Actions by removing appveyor and travis configurations and the last vestiges of mentions of it in the ci tree. Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
This commit is contained in:
156
.travis.yml
156
.travis.yml
@@ -1,156 +0,0 @@
|
||||
dist: xenial
|
||||
services:
|
||||
- docker
|
||||
language: shell
|
||||
|
||||
git:
|
||||
depth: false
|
||||
quiet: true
|
||||
|
||||
cache:
|
||||
directories:
|
||||
- "$HOME/.cargo"
|
||||
- "$HOME/.cache/sccache"
|
||||
before_cache:
|
||||
- |
|
||||
cargo install \
|
||||
--debug \
|
||||
--force \
|
||||
--git https://github.com/matthiaskrgr/cargo-cache \
|
||||
--no-default-features \
|
||||
--features ci-autoclean \
|
||||
--bin cargo-cache \
|
||||
-- \
|
||||
cargo-cache
|
||||
- cargo cache
|
||||
|
||||
matrix:
|
||||
fast_finish: true
|
||||
include:
|
||||
# Linux builds use the `rust-slave-dist` image so we link them against a
|
||||
# "super old glibc" to ensure that it runs on as many platforms as possible.
|
||||
# These builds always run. PRs, master, staging, stable, etc.
|
||||
- &linuxalways
|
||||
os: linux
|
||||
env: TARGET=x86_64-unknown-linux-gnu
|
||||
# Most builds consuming this only run on the stable and staging branches
|
||||
- &linuxstable
|
||||
os: linux
|
||||
env: TARGET=i686-unknown-linux-gnu
|
||||
if: branch != master
|
||||
# These builds run on non-pull-requests, so master, staging, stable...
|
||||
- &linuxmaster
|
||||
os: linux
|
||||
env: SKIP_TESTS=1 TARGET=aarch64-unknown-linux-gnu
|
||||
if: type != pull_request
|
||||
|
||||
# Cross builds happen in the `rust-slave-linux-cross` image to ensure that
|
||||
# we use the right cross compilers for these targets. That image should
|
||||
# bundle all the gcc cross compilers to enable us to build OpenSSL
|
||||
# Builds which occur only on stable (and staging branches) take linuxstable
|
||||
# Those which occur on master or any other branch (but not PRs) linuxmaster
|
||||
# And those which run always (PRs, master, staging, etc) linuxalways
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=arm-unknown-linux-gnueabi }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=arm-unknown-linux-gnueabihf }
|
||||
- { <<: *linuxalways, env: SKIP_TESTS=1 TARGET=armv7-unknown-linux-gnueabihf }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=x86_64-unknown-freebsd }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=x86_64-unknown-netbsd }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=powerpc-unknown-linux-gnu }
|
||||
- { <<: *linuxmaster, env: SKIP_TESTS=1 TARGET=powerpc64-unknown-linux-gnu }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=powerpc64le-unknown-linux-gnu }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=mips-unknown-linux-gnu }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=mipsel-unknown-linux-gnu }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=mips64-unknown-linux-gnuabi64 }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=mips64el-unknown-linux-gnuabi64 }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=s390x-unknown-linux-gnu }
|
||||
- { <<: *linuxmaster, env: SKIP_TESTS=1 TARGET=x86_64-unknown-linux-musl }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=arm-linux-androideabi }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=armv7-linux-androideabi }
|
||||
- { <<: *linuxalways, env: SKIP_TESTS=1 TARGET=aarch64-linux-android }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=i686-linux-android }
|
||||
- { <<: *linuxstable, env: SKIP_TESTS=1 TARGET=x86_64-linux-android }
|
||||
|
||||
# On OSX we want to target 10.7 so we ensure that the appropriate
|
||||
# environment variable is set to tell the linker what we want.
|
||||
#
|
||||
# TODO: figure out why `xcode9.3`, the first image with OSX 10.13, breaks.
|
||||
# Unclear why!
|
||||
- &mac
|
||||
os: osx
|
||||
osx_image: xcode9.2
|
||||
if: type != pull_request
|
||||
env: MACOSX_DEPLOYMENT_TARGET=10.7 TARGET=x86_64-apple-darwin
|
||||
- <<: *mac
|
||||
if: branch != master
|
||||
env: MACOSX_DEPLOYMENT_TARGET=10.7 TARGET=i686-apple-darwin
|
||||
|
||||
- name: rustfmt/clippy/rustup-init.sh/shellcheck
|
||||
language: shell
|
||||
before_install:
|
||||
- sh ./rustup-init.sh --default-toolchain=beta --profile=minimal -y -c rustfmt -c clippy
|
||||
- export PATH="$HOME/.cargo/bin:$PATH"
|
||||
script:
|
||||
- |
|
||||
docker run \
|
||||
--volume "$TRAVIS_BUILD_DIR":/checkout:ro \
|
||||
--workdir /checkout \
|
||||
--rm \
|
||||
-it \
|
||||
centos:6 \
|
||||
sh ./ci/raw_init.sh;
|
||||
- shellcheck -s dash -- rustup-init.sh;
|
||||
- git ls-files -- '*.sh' | xargs shellcheck -s dash -e SC1090;
|
||||
- git ls-files -- '*.bash' | xargs shellcheck -s bash -e SC1090;
|
||||
- cargo fmt --all -- --check;
|
||||
- cargo check --all --all-targets
|
||||
- git ls-files -- '*.rs' | xargs touch
|
||||
- cargo clippy --all --all-targets
|
||||
before_deploy:
|
||||
deploy:
|
||||
|
||||
- &windows
|
||||
os: windows
|
||||
env: TARGET=x86_64-pc-windows-msvc EXE_EXT=.exe
|
||||
services: nil
|
||||
language: bash
|
||||
if: branch == disabled-for-now
|
||||
|
||||
before_install:
|
||||
- sh ./rustup-init.sh --default-toolchain=stable --profile=minimal -y
|
||||
- export PATH="$HOME/.cargo/bin:$PATH"
|
||||
- rustup target add "$TARGET"
|
||||
|
||||
install:
|
||||
- export CARGO_TARGET_DIR="$TRAVIS_BUILD_DIR/target"
|
||||
|
||||
script:
|
||||
- mkdir -p target/"$TARGET";
|
||||
- |
|
||||
case "$TARGET" in
|
||||
*-linux-android*) DOCKER=android ;; # Android uses a local docker image
|
||||
*-apple-darwin) ;;
|
||||
*-pc-windows-*) ;;
|
||||
*) DOCKER="$TARGET" ;;
|
||||
esac
|
||||
- |
|
||||
if [ -n "$DOCKER" ]; then
|
||||
bash ci/build-run-docker.bash "$DOCKER" "$TARGET" "$SKIP_TESTS";
|
||||
else
|
||||
bash ci/run.bash;
|
||||
fi
|
||||
|
||||
before_deploy:
|
||||
- bash ci/prepare-deploy-travis.bash
|
||||
|
||||
deploy:
|
||||
- provider: s3
|
||||
bucket: dev-static-rust-lang-org
|
||||
skip_cleanup: true
|
||||
local_dir: deploy
|
||||
upload_dir: rustup
|
||||
acl: public_read
|
||||
region: us-west-1
|
||||
access_key_id: $AWS_ACCESS_KEY_ID
|
||||
secret_access_key: $AWS_SECRET_ACCESS_KEY
|
||||
on:
|
||||
branch: stable
|
||||
141
appveyor.yml
141
appveyor.yml
@@ -1,141 +0,0 @@
|
||||
image: Visual Studio 2017
|
||||
|
||||
branches:
|
||||
# whitelist
|
||||
only:
|
||||
- master
|
||||
- stable
|
||||
- auto
|
||||
cache:
|
||||
- '%USERPROFILE%\.cargo\'
|
||||
- target
|
||||
# before cache
|
||||
after_test:
|
||||
- powershell -File ci/prepare-deploy-appveyor.ps1
|
||||
- set CARGO_TARGET_DIR=%APPVEYOR_BUILD_FOLDER%\target
|
||||
- cargo install
|
||||
--debug
|
||||
--force
|
||||
--git https://github.com/matthiaskrgr/cargo-cache
|
||||
--no-default-features
|
||||
--features ci-autoclean
|
||||
--bin cargo-cache
|
||||
--
|
||||
cargo-cache
|
||||
- cargo cache
|
||||
|
||||
environment:
|
||||
global:
|
||||
RUSTFLAGS: -Ctarget-feature=+crt-static
|
||||
RUST_BACKTRACE: 1
|
||||
matrix:
|
||||
- TARGET: x86_64-pc-windows-msvc
|
||||
ALLOW_PR: 1
|
||||
- TARGET: i686-pc-windows-msvc
|
||||
- TARGET: x86_64-pc-windows-gnu
|
||||
MINGW_DIR: mingw64
|
||||
- TARGET: i686-pc-windows-gnu
|
||||
MINGW_DIR: mingw32
|
||||
access_token:
|
||||
secure: q8Wqx0brgfpOYFQqWauvucE2h0o1WYb41a3gKaCKV9QiE4eTz6qLNlqyC3mdsp4Q
|
||||
|
||||
matrix:
|
||||
fast_finish: true # set this flag to immediately finish build once one of the jobs fails.
|
||||
|
||||
install:
|
||||
# If this is a PR and we're not allowed to test PRs, skip the whole build.
|
||||
# Also if we're on the master branch no need to run the full test suite, so
|
||||
# just do a smoke test.
|
||||
- if defined APPVEYOR_PULL_REQUEST_NUMBER if NOT defined ALLOW_PR appveyor exit
|
||||
- if "%APPVEYOR_REPO_BRANCH%" == "master" if NOT defined ALLOW_PR appveyor exit
|
||||
|
||||
# Install MSYS2 and MINGW (32-bit & 64-bit)
|
||||
- ps: |
|
||||
# Check if MSYS2 was restored from cache
|
||||
if($env:MINGW_DIR) {
|
||||
if($env:MINGW_DIR -eq "mingw32") {
|
||||
# Download and install MINGW (32-bit)
|
||||
Write-Host "Installing MinGW (32-bit)..." -ForegroundColor Cyan
|
||||
Write-Host "Downloading installation package..."
|
||||
appveyor-retry appveyor DownloadFile https://ci-mirrors.rust-lang.org/rustc/i686-4.9.2-release-win32-dwarf-rt_v4-rev4.7z -FileName mingw.7z
|
||||
} elseif($env:MINGW_DIR -eq "mingw64") {
|
||||
# Download and install MINGW (64-bit)
|
||||
Write-Host "Installing MinGW (64-bit)..." -ForegroundColor Cyan
|
||||
Write-Host "Downloading installation package..."
|
||||
appveyor-retry appveyor DownloadFile https://ci-mirrors.rust-lang.org/rustc/x86_64-4.9.2-release-win32-seh-rt_v4-rev4.7z -FileName mingw.7z
|
||||
}
|
||||
Write-Host "Extracting installation package..."
|
||||
7z x -y mingw.7z -oC:\msys64 | Out-Null
|
||||
del mingw.7z
|
||||
} else {
|
||||
Write-Host "MSYS2 not required" -ForegroundColor Green
|
||||
}
|
||||
|
||||
# Install rust, x86_64-pc-windows-msvc host
|
||||
- appveyor-retry appveyor DownloadFile https://win.rustup.rs/ -FileName rustup-init.exe
|
||||
- rustup-init.exe -y --default-host=x86_64-pc-windows-msvc --profile=minimal
|
||||
- set PATH=%PATH%;%USERPROFILE%\.cargo\bin
|
||||
- del rustup-init.exe
|
||||
|
||||
# Install the target we're compiling for
|
||||
- rustup target add %TARGET%
|
||||
|
||||
# add mingw to PATH if necessary
|
||||
- if defined MINGW_DIR set PATH=C:\msys64\%MINGW_DIR%\bin;C:\msys64\usr\bin;%PATH%
|
||||
# And if mingw, re-put appveyor's git in place
|
||||
- if defined MINGW_DIR set PATH=C:\Program Files\Git\cmd;%PATH%
|
||||
|
||||
# let's see what we got
|
||||
- where gcc rustc cargo
|
||||
- rustc -vV
|
||||
- cargo -V
|
||||
|
||||
# Build settings, not to be confused with "before_build" and "after_build".
|
||||
build: false
|
||||
|
||||
build_script:
|
||||
- cargo build --release --target %TARGET% --locked
|
||||
- cargo run --release --target %TARGET% --locked -- --dump-testament
|
||||
|
||||
test_script:
|
||||
# The rest of this relies on the set of things to test not changing
|
||||
# because I have no idea how to script it. TODO: Get someone to script it?
|
||||
- cargo test --release --target %TARGET% -p download
|
||||
- cargo test --release --target %TARGET% --bin rustup-init
|
||||
- cargo test --release --target %TARGET% --lib --all
|
||||
- cargo test --release --target %TARGET% --doc --all
|
||||
- cargo test --release --target %TARGET% --test cli-exact
|
||||
- cargo test --release --target %TARGET% --test cli-inst-interactive
|
||||
- cargo test --release --target %TARGET% --test cli-misc
|
||||
- cargo test --release --target %TARGET% --test cli-rustup
|
||||
- cargo test --release --target %TARGET% --test cli-self-upd
|
||||
- cargo test --release --target %TARGET% --test cli-v1
|
||||
- cargo test --release --target %TARGET% --test cli-v2
|
||||
- cargo test --release --target %TARGET% --test dist_install
|
||||
- cargo test --release --target %TARGET% --test dist_manifest
|
||||
- cargo test --release --target %TARGET% --test dist -- --test-threads 1
|
||||
- cargo test --release --target %TARGET% --test dist_transactions
|
||||
|
||||
|
||||
artifacts:
|
||||
- path: dist\$(TARGET)\rustup-init.exe
|
||||
name: rustup-init
|
||||
- path: dist\$(TARGET)\rustup-init.exe.sha256
|
||||
name: rustup-init-sha
|
||||
- path: dist\$(TARGET)\rustup-setup.exe
|
||||
name: rustup-setup
|
||||
- path: dist\$(TARGET)\rustup-setup.exe.sha256
|
||||
name: rustup-setup-sha
|
||||
|
||||
deploy:
|
||||
- provider: S3
|
||||
skip_cleanup: true
|
||||
access_key_id: $(AWS_ACCESS_KEY_ID)
|
||||
secret_access_key: $(AWS_SECRET_ACCESS_KEY)
|
||||
bucket: dev-static-rust-lang-org
|
||||
set_public: true
|
||||
region: us-west-1
|
||||
artifact: rustup-init,rustup-init-sha,rustup-setup,rustup-setup-sha
|
||||
folder: rustup
|
||||
on:
|
||||
branch: stable
|
||||
@@ -169,12 +169,11 @@ jobs:
|
||||
if: github.event_name == 'push' && github.ref == 'refs/heads/stable'
|
||||
- name: Prepare the dist
|
||||
run: |
|
||||
.\ci\prepare-deploy-appveyor.ps1
|
||||
.\ci\prepare-deploy.ps1
|
||||
shell: powershell
|
||||
if: github.event_name == 'push' && github.ref == 'refs/heads/stable'
|
||||
- name: Deploy build to dev-static dist tree for release team
|
||||
run: |
|
||||
# TODO: Endpoint etc?
|
||||
aws s3 cp --recursive dist s3://dev-static-rust-lang-org/rustup/dist
|
||||
shell: powershell
|
||||
env:
|
||||
|
||||
@@ -1,61 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
script_dir=$(cd "$(dirname "$0")" && pwd)
|
||||
root_dir="${script_dir}/.."
|
||||
|
||||
. "${script_dir}/shared.bash"
|
||||
|
||||
set -e
|
||||
# Disable cause it makes shared script not to work properly
|
||||
#set -x
|
||||
|
||||
mkdir -p target
|
||||
mkdir -p "${HOME}"/.cargo
|
||||
mkdir -p "${HOME}"/.cache/sccache
|
||||
|
||||
DOCKER="$1"
|
||||
TARGET="$2"
|
||||
SKIP_TESTS="$3"
|
||||
|
||||
travis_fold start "fetch.image.${TARGET}"
|
||||
travis_time_start
|
||||
travis_do_cmd bash ci/fetch-rust-docker.bash "${TARGET}"
|
||||
travis_time_finish
|
||||
travis_fold end "fetch.image.${TARGET}"
|
||||
|
||||
if [ -f "ci/docker/$DOCKER/Dockerfile" ]; then
|
||||
travis_fold start "build.Dockerfile.${DOCKER}"
|
||||
travis_time_start
|
||||
travis_do_cmd docker build -t "$DOCKER" -f "ci/docker/${DOCKER}/Dockerfile" .
|
||||
travis_time_finish
|
||||
travis_fold end "build.Dockerfile.${DOCKER}"
|
||||
fi
|
||||
|
||||
# shellcheck disable=SC2016
|
||||
docker run \
|
||||
--entrypoint sh \
|
||||
--user "$(id -u)":"$(id -g)" \
|
||||
--volume "$(rustc --print sysroot)":/rustc-sysroot:ro \
|
||||
--volume "${root_dir}":/checkout:ro \
|
||||
--volume "${root_dir}"/target:/checkout/target \
|
||||
--workdir /checkout \
|
||||
--env TARGET="${TARGET}" \
|
||||
--env SKIP_TESTS="${SKIP_TESTS}" \
|
||||
--volume "${HOME}/.cargo:/cargo" \
|
||||
--env CARGO_HOME=/cargo \
|
||||
--env CARGO_TARGET_DIR=/checkout/target \
|
||||
--env LIBZ_SYS_STATIC=1 \
|
||||
--volume "${HOME}"/.cache/sccache:/sccache \
|
||||
--env SCCACHE_DIR=/sccache \
|
||||
--tty \
|
||||
--init \
|
||||
--rm \
|
||||
"${DOCKER}" \
|
||||
-c 'PATH="${PATH}":/rustc-sysroot/bin bash ci/run.bash'
|
||||
|
||||
# check that rustup-init was built with ssl support
|
||||
# see https://github.com/rust-lang/rustup/issues/1051
|
||||
if ! (nm target/"${TARGET}"/release/rustup-init | grep -q Curl_ssl_version); then
|
||||
echo "Missing ssl support!!!!" >&2
|
||||
exit 1
|
||||
fi
|
||||
@@ -1,41 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -u -e
|
||||
|
||||
# Not every build sets EXE_EXT since it is empty for non .exe builds
|
||||
# So this sets it explicitly to the empty string if it's unset.
|
||||
EXE_EXT=${EXE_EXT:=}
|
||||
|
||||
if [ "$TRAVIS_PULL_REQUEST" = "true" ] || [ "$TRAVIS_BRANCH" = "auto" ]; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Copy rustup-init to rustup-setup for backwards compatibility
|
||||
cp target/"$TARGET"/release/rustup-init"${EXE_EXT}" target/"$TARGET"/release/rustup-setup"${EXE_EXT}"
|
||||
|
||||
# Generate hashes
|
||||
if [ "$TRAVIS_OS_NAME" = "osx" ]; then
|
||||
find target/"$TARGET"/release/ -maxdepth 1 -type f -exec sh -c 'fn="$1"; shasum -a 256 -b "$fn" > "$fn".sha256' sh {} \;
|
||||
else
|
||||
find target/"$TARGET"/release/ -maxdepth 1 -type f -exec sh -c 'fn="$1"; sha256sum -b "$fn" > "$fn".sha256' sh {} \;
|
||||
fi
|
||||
|
||||
# The directory for deployment artifacts
|
||||
dest="deploy"
|
||||
|
||||
# Prepare bins for upload
|
||||
bindest="$dest/dist/$TARGET"
|
||||
mkdir -p "$bindest/"
|
||||
cp target/"$TARGET"/release/rustup-init"${EXE_EXT}" "$bindest/"
|
||||
cp target/"$TARGET"/release/rustup-init"${EXE_EXT}".sha256 "$bindest/"
|
||||
cp target/"$TARGET"/release/rustup-setup"${EXE_EXT}" "$bindest/"
|
||||
cp target/"$TARGET"/release/rustup-setup"${EXE_EXT}".sha256 "$bindest/"
|
||||
|
||||
if [ "$TARGET" != "x86_64-unknown-linux-gnu" ]; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
cp rustup-init.sh "$dest/"
|
||||
|
||||
# Prepare website for upload
|
||||
cp -R www "$dest/www"
|
||||
@@ -1,10 +1,3 @@
|
||||
if ($env:APPVEYOR_PULL_REQUEST_NUMBER) {
|
||||
exit 0
|
||||
}
|
||||
|
||||
if ($env:APPVEYOR_REPO_BRANCH -eq "auto") {
|
||||
exit 0
|
||||
}
|
||||
|
||||
# Copy rustup-init to rustup-setup for backwards compatibility
|
||||
cp target\${env:TARGET}\release\rustup-init.exe target\${env:TARGET}\release\rustup-setup.exe
|
||||
Reference in New Issue
Block a user