-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
Rename user/onboarding.md to Run #3463
Open
rexingQ
wants to merge
1
commit into
travis-ci:master
Choose a base branch
from
rexingQ:patch-3
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
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
--- title: Travis CI Onboarding layout: en redirect_from: - /user/getting-started/ --- This is a short guide to using Travis CI with your cloud platform-hosted code repository. If you're new to continuous integration or would like some more information on what Travis CI does, start with [Core Concepts for Beginners](/user/for-beginners/) instead. ## Prerequisites To start using Travis CI, make sure you have the following: * A [GitHub](https://github.com/), [Assembla](https://www.assembla.com/), [Bitbucket](https://bitbucket.org/), or [GitLab](https://about.gitlab.com/) account. * Owner permissions for a project hosted on [GitHub](https://help.github.com/categories/importing-your-projects-to-github/), [Assembla](https://articles.assembla.com/en/articles/1665737-advanced-user-permissions-controls), [Bitbucket](https://confluence.atlassian.com/bitbucket/transfer-repository-ownership-289964397.html), or [GitLab](https://www.tutorialspoint.com/gitlab/gitlab_user_permissions.htm). ## Get Started with Travis CI Get started with Travis CI, a continuous integration service used to test and build software projects hosted on [GitHub](https://github.com/), [Assembla](https://www.assembla.com/), [Bitbucket](https://bitbucket.org/), or [GitLab](https://about.gitlab.com/). 1. **Sign up for Travis CI**. Go to [Travis-ci.com](https://app.travis-ci.com) and [*Sign-in with your preferred account*](https://app.travis-ci.com/signin).  1. **Accept Travis CI Authorization**. Once redirected to your chosen platform, log into your account and accept Travis CI’s authorization request. If you have any doubts about the Travis CI access rights to your chosen platform, read more details here: * [GitHub Authorized OAuth App](/user/github-oauth-scopes/#travis-ci-github-oauth-app-access-rights). * [GitHub permissions used by Travis CI](/user/github-oauth-scopes). * [Assembla permissions used by Travis CI](/user/assembla-oauth-scopes/) * [BitBucket permissions used by Travis CI](/user/bb-oauth-scopes/) * [GitLab permissions used by Travis CI](/user/gl-oauth-scopes/) 1. **Select a Plan**. Choose the best plan for you, or get started with our Trial Plan.  1. **Credit Card Validation**. To commence the selected plan, you must first insert your billing information and a valid Credit Card.  > **Note**: For Trial Plans, credit card authorization may result in a small fee being held on the card for a short duration. Trial Plan users are granted a small allotment of trial credits to be used within the next 14 days. 1. **Settings configurations**. In your Travis Dashboard, click on your profile picture at the top right and select the Settings option to see a list of your available repositories. 1. **Select repositories**. Click the **Manage Repositories** button. Once directed to your chosen platform, select the repositories you want to use with Travis CI.  > Depending on your chosen platform, you can also make this selection with the authorization message by clicking the *Activate all repositories* button on the Getting Started page to activate all your repos. ### GitHub Student Developer Pack users If you use a GitHub account and are eligible for the GitHub Student Developer Pack, the Travis CI plan might not be assigned automatically. This occurs because the user already has a plan assigned in Travis CI. If you wish to use the free allowance for the GitHub Student Developer Pack instead, please [contact our support team](mailto:[email protected]), provide your GitHub handle, and request the assignment of the respective plan. ## Add a .travis.yml File The next step is to add a `.travis.yml` file to your repository to tell Travis CI what to do. The following example specifies a Ruby project built with Ruby 2.2 and the latest version of JRuby. ```yaml language: ruby rvm: - 2.2 - jruby ``` {: data-file=".travis.yml"} > The defaults for Ruby projects are `bundle install` to [install dependencies](/user/job-lifecycle/#customizing-the-installation-phase), and `rake` to build the project. Add the `.travis.yml` to a specific location in your repository. > Travis only runs builds on the commits you push *after* you've added a `.travis.yml` file. Finally, visit [Travis CI](https://app.travis-ci.com) and select your repository to check the build status page to see if your build [passes or fails](/user/job-lifecycle/#breaking-the-build) according to the return status of the build command. ### Assembla .travis.yml File Configuration <blockquote class="beta"> <p> This section documents the new Assembla option that is currently in beta. </p> </blockquote> For Assembla users, configure the `.travis.yml` as follows: 1. Git Repository: in the repositories root (`main` and branches). 2. SVN Repository: 1. In the `/trunk/` (default is `/trunk/.travis.yml`) for builds to run after commits to `trunk`. 2. In the `/branches/<branch name>/` (e.g.,`/branches/abc/.travis.yml` for branch named `abc`) for builds to run after commits to a specific branch. 3. P4 (Perforce Helix Core) Repository: 1. In the `/<depotname>/main/` (default is `/depot/main/.travis.yml`) for builds to run after submits to `/<depotname>/main`. 2. In the directory respective to specific stream `/depot/<stream name>/`.travis.yml (e.g., `/depot/abc/.travis.yml` for stream `abc`) for builds to run after submits to a specific stream. **IMPORTANT** Perforce depot/repository may be very heavy, so downloading it fully for build (e.g., terabytes of data) is often unwanted, as the source code to be built/tested is only a fraction of the whole depot size. To download it partially, a Travis CI user must define a specific subpath, which is later downloaded by the Travis CI build job. Such subpaths may be defined using the `perforce_test_path` tag within a `.travis.yml` file. If the property is not provided, the default behavior is downloading the whole depot/repository. See the example below for reference. ```yaml dist: focal language: ruby rvm: - 2.2 - jruby perforce_test_path: /your/subpath/within/repository/which/will/be/downloaded ``` {: data-file=".travis.yml"} Perforce and SVN builds are currently **available only for Linux Ubuntu** and standard amd64 CPU architecture build environments, starting from the Bionic Beaver Ubuntu distribution. ## Switch Accounts You can easily switch between your cloud platform provider accounts: 1. Click on your account icon in the top right corner on [Travis-ci.com](https://app.travis-ci.com). 2. Select the desired account and have fun using Travis CI.  ## Select a different programming language Use one of these common languages: ```yaml language: ruby ``` {: data-file=".travis.yml"} ```yaml language: java ``` {: data-file=".travis.yml"} ```yaml language: node_js ``` {: data-file=".travis.yml"} ```yaml language: python ``` {: data-file=".travis.yml"} ```yaml language: php ``` {: data-file=".travis.yml"} ```yaml language: go ``` {: data-file=".travis.yml"} If you have tests that need to run on macOS or your project uses Swift or Objective-C, use our macOS environment: ```yaml os: osx ``` {: data-file=".travis.yml"} > You do *not* necessarily need to use macOS if you develop on a Mac. > macOS is required only if you need Swift, Objective-C, or other > macOS-specific software. Travis CI supports many [programming languages](/user/languages/). ## Further Reading Find more useful information in our Tutorial pages: * [Sign up for Travis](https://youtu.be/IZJJxl9BkmA) * [Get Started with Travis CI](https://youtu.be/_Og2kydTLWk) * [Core concepts for Beginners](https://youtu.be/EER3AWu4sqM) * [Travis CI Tutorials](/user/tutorials/tutorials-overview/) Core concepts for BeginnersSkip to content Navigation Menu Code Issues 32 Validate 'setup-go' Validate 'setup-go' travis-ci#2443 Annotations 1 warning oldstable (ubuntu-latest) succeeded 1 hour ago in 12s 1s 4s 2s Run ./ with: go-version: oldstable check-latest: false token: *** cache: true Setup go version spec oldstable oldstable version resolved as 1.23.6 Found in cache @ /opt/hostedtoolcache/go/1.23.6/x64 Added go to the path Successfully set up Go version oldstable /opt/hostedtoolcache/go/1.23.6/x64/bin/go env GOMODCACHE /opt/hostedtoolcache/go/1.23.6/x64/bin/go env GOCACHE /home/runner/go/pkg/mod /home/runner/.cache/go-build Warning: Restore cache failed: Dependencies file is not found in /home/runner/work/setup-go/setup-go. Supported file pattern: go.sum go version go1.23.6 linux/amd64 go env GO111MODULE='' GOARCH='amd64' GOBIN='' GOCACHE='/home/runner/.cache/go-build' GOENV='/home/runner/.config/go/env' GOEXE='' GOEXPERIMENT='' GOFLAGS='' GOHOSTARCH='amd64' GOHOSTOS='linux' GOINSECURE='' GOMODCACHE='/home/runner/go/pkg/mod' GONOPROXY='' GONOSUMDB='' GOOS='linux' GOPATH='/home/runner/go' GOPRIVATE='' GOPROXY='https://proxy.golang.org,direct' GOROOT='/opt/hostedtoolcache/go/1.23.6/x64' GOSUMDB='sum.golang.org' GOTMPDIR='' GOTOOLCHAIN='auto' GOTOOLDIR='/opt/hostedtoolcache/go/1.23.6/x64/pkg/tool/linux_amd64' GOVCS='' GOVERSION='go1.23.6' GODEBUG='' GOTELEMETRY='local' GOTELEMETRYDIR='/home/runner/.config/go/telemetry' GCCGO='gccgo' GOAMD64='v1' AR='ar' CC='gcc' CXX='g++' CGO_ENABLED='1' GOMOD='/dev/null' GOWORK='' CGO_CFLAGS='-O2 -g' CGO_CPPFLAGS='' CGO_CXXFLAGS='-O2 -g' CGO_FFLAGS='-O2 -g' CGO_LDFLAGS='-O2 -g' PKG_CONFIG='pkg-config' GOGCCFLAGS='-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=/tmp/go-build1076634855=/tmp/go-build -gno-record-gcc-switches' 0s Run go version go version shell: /usr/bin/bash -e {0} go version go1.23.6 linux/amd64 0s Post job cleanup. /opt/hostedtoolcache/go/1.23.6/x64/bin/go env GOMODCACHE /opt/hostedtoolcache/go/1.23.6/x64/bin/go env GOCACHE /home/runner/go/pkg/mod /home/runner/.cache/go-build Warning: Cache folder path is retrieved but doesn't exist on disk: /home/runner/go/pkg/mod Primary key was not generated. Please check the log messages above for more errors or information 1s Post job cleanup. /usr/bin/git version git version 2.48.1 Temporarily overriding HOME='/home/runner/work/_temp/38ccc176-dbef-4a74-8dc7-ad24fcf8bbd4' before making global git config changes Adding repository directory to the temporary git global config as a safe directory /usr/bin/git config --global --add safe.directory /home/runner/work/setup-go/setup-go /usr/bin/git config --local --name-only --get-regexp core\.sshCommand /usr/bin/git submodule foreach --recursive sh -c "git config --local --name-only --get-regexp 'core\.sshCommand' && git config --local --unset-all 'core.sshCommand' || :" /usr/bin/git config --local --name-only --get-regexp http\.https\:\/\/github\.com\/\.extraheader http.https://github.com/.extraheader /usr/bin/git config --local --unset-all http.https://github.com/.extraheader /usr/bin/git submodule foreach --recursive sh -c "git config --local --name-only --get-regexp 'http\.https\:\/\/github\.com\/\.extraheader' && git config --local --unset-all 'http.https://github.com/.extraheader' || :" 0s Cleaning up orphan processes Validate 'setup-go' · actions/setup-go@5a083d0 Navigation Menu Code Issues 32 Validate 'setup-go' Validate 'setup-go' travis-ci#2443 Workflow file for this run .github/workflows/versions.yml at 5a083d0 name: Validate 'setup-go' on: push: branches: - main paths-ignore: - '**.md' pull_request: paths-ignore: - '**.md' schedule: - cron: 0 0 * * * jobs: stable: runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] steps: - uses: actions/checkout@v4 - name: Setup Go Stable uses: ./ with: go-version: stable - name: Verify Go run: go version oldstable: runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] steps: - uses: actions/checkout@v4 - name: Setup Go oldStable uses: ./ with: go-version: oldstable - name: Verify Go run: go version aliases-arch: runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] version: [stable, oldstable] architecture: [x64, x32] exclude: - os: macos-latest architecture: x32 - os: macos-13 architecture: x32 steps: - uses: actions/checkout@v4 - name: Setup Go ${{ matrix.version }} ${{ matrix.architecture }} uses: ./ with: go-version: ${{ matrix.version }} architecture: ${{ matrix.architecture }} - name: Verify Go run: go version local-cache: name: Setup local-cache version runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [macos-latest, windows-latest, ubuntu-latest, macos-13] go: [1.21.13, 1.22.8, 1.23.2] include: - os: windows-latest go: 1.20.14 exclude: - os: windows-latest go: 1.23.2 steps: - name: Checkout uses: actions/checkout@v4 - name: setup-go ${{ matrix.go }} uses: ./ with: go-version: ${{ matrix.go }} - name: verify go run: __tests__/verify-go.sh ${{ matrix.go }} shell: bash check-latest: runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] go-version: ['1.20', '1.21', '1.22', '1.23'] steps: - uses: actions/checkout@v4 - name: Setup Go and check latest uses: ./ with: go-version: ${{ matrix.go-version }} check-latest: true - name: Verify Go run: go version go-version-file: runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] steps: - uses: actions/checkout@v4 - name: Setup Go and check latest uses: ./ with: go-version-file: __tests__/data/go.mod - name: verify go run: __tests__/verify-go.sh 1.20.14 shell: bash go-version-file-with-gowork: runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] steps: - uses: actions/checkout@v4 - name: Setup Go and check latest uses: ./ with: go-version-file: __tests__/data/go.work - name: verify go run: __tests__/verify-go.sh 1.21 shell: bash setup-versions-from-manifest: runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [macos-latest, windows-latest, ubuntu-latest, macos-13] go: [1.20.14, 1.21.10, 1.22.8, 1.23.2] steps: - name: Checkout uses: actions/checkout@v4 - name: setup-go ${{ matrix.go }} uses: ./ with: go-version: ${{ matrix.go }} - name: verify go run: __tests__/verify-go.sh ${{ matrix.go }} shell: bash setup-versions-from-dist: runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [windows-latest, ubuntu-latest, macos-13] go: [1.11.12] steps: - name: Checkout uses: actions/checkout@v4 - name: setup-go ${{ matrix.go }} uses: ./ with: go-version: ${{ matrix.go }} - name: verify go run: __tests__/verify-go.sh ${{ matrix.go }} shell: bash architecture: runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] go-version: [1.20.14, 1.21, 1.22, 1.23] include: - os: macos-latest architecture: arm64 - os: ubuntu-latest architecture: x64 - os: windows-latest architecture: x64 - os: macos-13 architecture: x64 steps: - uses: actions/checkout@v4 - name: Setup Go and check latest uses: ./ with: go-version: ${{ matrix.go-version }} architecture: ${{ matrix.architecture }} - name: Verify Go run: go version<iframe src="https://codesandbox.io/p/devbox/pz34j4?migrateFrom=pgnt0&embed=1&file=%2Fsrc%2Fwidgets%2FHello.tsx" style="width:100%; height: 500px; border:0; border-radius: 4px; overflow:hidden;" title="magical-elbakyan-pgnt0" allow="accelerometer; ambient-light-sensor; camera; encrypted-media; geolocation; gyroscope; hid; microphone; midi; payment; usb; vr; xr-spatial-tracking" sandbox="allow-forms allow-modals allow-popups allow-presentation allow-same-origin allow-scripts" ></iframe>2025-02-24T02:17:40.4228469Z ##[group]Build container for action use: '/home/runner/work/_actions/getong/elasticsearch-action/95b501ab0c83dee0aac7c39b7cea3723bef14954/Dockerfile'. /usr/bin/docker build -t 766e2c:4af29413fd8446b986d95086372a9a40 -f "/home/runner/work/_actions/getong/elasticsearch-action/95b501ab0c83dee0aac7c39b7cea3723bef14954/Dockerfile" "/home/runner/work/_actions/getong/elasticsearch-action/95b501ab0c83dee0aac7c39b7cea3723bef14954" #0 building with "default" instance using docker driver #1 [internal] load build definition from Dockerfile #1 transferring dockerfile: 149B done #1 DONE 0.0s #2 [auth] library/docker:pull token for registry-1.docker.io #2 DONE 0.0s #3 [internal] load metadata for docker.io/library/docker:stable #3 DONE 0.6s #4 [internal] load .dockerignore #4 transferring context: 2B done #4 DONE 0.0s #5 [internal] load build context #5 transferring context: 890B done #5 DONE 0.0s #6 [1/3] FROM docker.io/library/docker:stable@sha256:fd4d028713fd05a1fb896412805daed82c4a0cc84331d8dad00cb596d7ce3e3a #6 resolve docker.io/library/docker:stable@sha256:fd4d028713fd05a1fb896412805daed82c4a0cc84331d8dad00cb596d7ce3e3a done #6 sha256:b0757c55a1fdbb59c378fd34dde3e12bd25f68094dd69546cf5ca00ddbaa7a33 4.21kB / 4.21kB done #6 sha256:0c7c675703d60dc4d757acb40557350159f600ca3d49e2e8d4c2039dd6b69457 0B / 2.04MB 0.1s #6 sha256:cc8c12a437cbe4e104dcea425e0ce277a2442603e14551d22a948e11026ae658 0B / 153B 0.1s #6 sha256:fd4d028713fd05a1fb896412805daed82c4a0cc84331d8dad00cb596d7ce3e3a 1.00kB / 1.00kB done #6 sha256:188c0c94c7c576fff0792aca7ec73d67a2f7f4cb3a6e53a84559337260b36964 2.80MB / 2.80MB 0.1s #6 sha256:8f71deccd0856d8a36db659a8c82894be97546b47c1817de27d5ee7eea860162 1.78kB / 1.78kB done #6 sha256:0c7c675703d60dc4d757acb40557350159f600ca3d49e2e8d4c2039dd6b69457 2.04MB / 2.04MB 0.1s done #6 sha256:cc8c12a437cbe4e104dcea425e0ce277a2442603e14551d22a948e11026ae658 153B / 153B 0.1s done #6 sha256:188c0c94c7c576fff0792aca7ec73d67a2f7f4cb3a6e53a84559337260b36964 2.80MB / 2.80MB 0.1s done #6 extracting sha256:188c0c94c7c576fff0792aca7ec73d67a2f7f4cb3a6e53a84559337260b36964 0.1s done #6 sha256:79aa7fa92271a7c1a46782d83623d7b9a111a2236c077aa11fe4bb289865955e 0B / 116B 0.2s #6 sha256:f092543453df2d4fbc4652f5584b56dd62987a33816ffd2a8d7ad9fad249b1ef 5.24MB / 62.89MB 0.2s #6 sha256:65b6bc45957d739e38db2da98d43e419af5fc45c46b8149f61b743dc613383e6 549B / 549B 0.2s done #6 sha256:4de832df471bbad41016f9621737b66aa5d8e575d7676661d111ea80b87e3946 1.02kB / 1.02kB 0.2s done #6 extracting sha256:0c7c675703d60dc4d757acb40557350159f600ca3d49e2e8d4c2039dd6b69457 #6 sha256:79aa7fa92271a7c1a46782d83623d7b9a111a2236c077aa11fe4bb289865955e 116B / 116B 0.2s done #6 sha256:f092543453df2d4fbc4652f5584b56dd62987a33816ffd2a8d7ad9fad249b1ef 50.33MB / 62.89MB 0.4s #6 extracting sha256:0c7c675703d60dc4d757acb40557350159f600ca3d49e2e8d4c2039dd6b69457 0.1s done #6 sha256:f092543453df2d4fbc4652f5584b56dd62987a33816ffd2a8d7ad9fad249b1ef 62.89MB / 62.89MB 0.5s done #6 extracting sha256:cc8c12a437cbe4e104dcea425e0ce277a2442603e14551d22a948e11026ae658 done #6 extracting sha256:f092543453df2d4fbc4652f5584b56dd62987a33816ffd2a8d7ad9fad249b1ef #6 extracting sha256:f092543453df2d4fbc4652f5584b56dd62987a33816ffd2a8d7ad9fad249b1ef 0.8s done #6 extracting sha256:65b6bc45957d739e38db2da98d43e419af5fc45c46b8149f61b743dc613383e6 #6 extracting sha256:65b6bc45957d739e38db2da98d43e419af5fc45c46b8149f61b743dc613383e6 done #6 extracting sha256:4de832df471bbad41016f9621737b66aa5d8e575d7676661d111ea80b87e3946 done #6 extracting sha256:79aa7fa92271a7c1a46782d83623d7b9a111a2236c077aa11fe4bb289865955e done #6 DONE 1.7s #7 [2/3] COPY entrypoint.sh /entrypoint.sh #7 DONE 0.0s #8 [3/3] RUN chmod +x /entrypoint.sh #8 DONE 0.2s #9 exporting to image #9 exporting layers #9 exporting layers 0.2s done #9 writing image sha256:82661a2b528d8edb6a1c0892427144ca7f050a53b246d5963b9f1658696cede4 done #9 naming to docker.io/library/766e2c:4af29413fd8446b986d95086372a9a40 done #9 DONE 0.2s
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
title: Travis CI Onboarding
layout: en
redirect_from:
This is a short guide to using Travis CI with your cloud platform-hosted code repository. If you're new to continuous integration or would like some more information on what Travis CI does, start with Core Concepts for Beginners instead.
Prerequisites
To start using Travis CI, make sure you have the following:
Get Started with Travis CI
Get started with Travis CI, a continuous integration service used to test and build software projects hosted on GitHub, Assembla, Bitbucket, or GitLab.
Go to Travis-ci.com and Sign-in with your preferred account.
Once redirected to your chosen platform, log into your account and accept Travis CI’s authorization request.
If you have any doubts about the Travis CI access rights to your chosen platform, read more details here:
Choose the best plan for you, or get started with our Trial Plan.
To commence the selected plan, you must first insert your billing information and a valid Credit Card.
In your Travis Dashboard, click on your profile picture at the top right and select the Settings option to see a list of your available repositories.
Click the Manage Repositories button. Once directed to your chosen platform, select the repositories you want to use with Travis CI.
GitHub Student Developer Pack users
If you use a GitHub account and are eligible for the GitHub Student Developer Pack, the Travis CI plan might not be assigned automatically. This occurs because the user already has a plan assigned in Travis CI.
If you wish to use the free allowance for the GitHub Student Developer Pack instead, please contact our support team, provide your GitHub handle, and request the assignment of the respective plan.
Add a .travis.yml File
The next step is to add a
.travis.yml
file to your repository to tell Travis CI what to do. The following example specifies a Ruby project built with Ruby 2.2 and the latest version of JRuby.{: data-file=".travis.yml"}
{: data-file=".travis.yml"}
{: data-file=".travis.yml"}
{: data-file=".travis.yml"}
{: data-file=".travis.yml"}
{: data-file=".travis.yml"}
If you have tests that need to run on macOS or your project uses Swift or Objective-C, use our macOS environment:
{: data-file=".travis.yml"}
Travis CI supports many programming languages.
Further Reading
Find more useful information in our Tutorial pages:
Navigation Menu
Code
Issues
32
Validate 'setup-go'
Validate 'setup-go' #2443
Annotations
1 warning
oldstable (ubuntu-latest)
succeeded 1 hour ago in 12s
1s
4s
2s
Run ./
with: go-version: oldstable check-latest: false token: *** cache: true Setup go version spec oldstable
oldstable version resolved as 1.23.6
Found in cache @ /opt/hostedtoolcache/go/1.23.6/x64 Added go to the path
Successfully set up Go version oldstable
/opt/hostedtoolcache/go/1.23.6/x64/bin/go env GOMODCACHE /opt/hostedtoolcache/go/1.23.6/x64/bin/go env GOCACHE /home/runner/go/pkg/mod
/home/runner/.cache/go-build
Warning: Restore cache failed: Dependencies file is not found in /home/runner/work/setup-go/setup-go. Supported file pattern: go.sum go version go1.23.6 linux/amd64
go env
GO111MODULE=''
GOARCH='amd64'
GOBIN=''
GOCACHE='/home/runner/.cache/go-build'
GOENV='/home/runner/.config/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFLAGS=''
GOHOSTARCH='amd64'
GOHOSTOS='linux'
GOINSECURE=''
GOMODCACHE='/home/runner/go/pkg/mod'
GONOPROXY=''
GONOSUMDB=''
GOOS='linux'
GOPATH='/home/runner/go'
GOPRIVATE=''
GOPROXY='https://proxy.golang.org,direct'
GOROOT='/opt/hostedtoolcache/go/1.23.6/x64'
GOSUMDB='sum.golang.org'
GOTMPDIR=''
GOTOOLCHAIN='auto'
GOTOOLDIR='/opt/hostedtoolcache/go/1.23.6/x64/pkg/tool/linux_amd64'
GOVCS=''
GOVERSION='go1.23.6'
GODEBUG=''
GOTELEMETRY='local'
GOTELEMETRYDIR='/home/runner/.config/go/telemetry'
GCCGO='gccgo'
GOAMD64='v1'
AR='ar'
CC='gcc'
CXX='g++'
CGO_ENABLED='1'
GOMOD='/dev/null'
GOWORK=''
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
PKG_CONFIG='pkg-config'
GOGCCFLAGS='-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=/tmp/go-build1076634855=/tmp/go-build -gno-record-gcc-switches'
0s
Run go version
go version
shell: /usr/bin/bash -e {0}
go version go1.23.6 linux/amd64
0s
Post job cleanup.
/opt/hostedtoolcache/go/1.23.6/x64/bin/go env GOMODCACHE /opt/hostedtoolcache/go/1.23.6/x64/bin/go env GOCACHE /home/runner/go/pkg/mod
/home/runner/.cache/go-build
Warning: Cache folder path is retrieved but doesn't exist on disk: /home/runner/go/pkg/mod Primary key was not generated. Please check the log messages above for more errors or information 1s
Post job cleanup.
/usr/bin/git version
git version 2.48.1
Temporarily overriding HOME='/home/runner/work/_temp/38ccc176-dbef-4a74-8dc7-ad24fcf8bbd4' before making global git config changes Adding repository directory to the temporary git global config as a safe directory /usr/bin/git config --global --add safe.directory /home/runner/work/setup-go/setup-go /usr/bin/git config --local --name-only --get-regexp core.sshCommand /usr/bin/git submodule foreach --recursive sh -c "git config --local --name-only --get-regexp 'core.sshCommand' && git config --local --unset-all 'core.sshCommand' || :" /usr/bin/git config --local --name-only --get-regexp http.https://github.com/.extraheader http.https://github.com/.extraheader
/usr/bin/git config --local --unset-all http.https://github.com/.extraheader /usr/bin/git submodule foreach --recursive sh -c "git config --local --name-only --get-regexp 'http.https://github.com/.extraheader' && git config --local --unset-all 'http.https://github.com/.extraheader' || :" 0s
Cleaning up orphan processes
Validate 'setup-go' · actions/setup-go@5a083d0
Navigation Menu
Code
Issues
32
Validate 'setup-go'
Validate 'setup-go' #2443
Workflow file for this run
.github/workflows/versions.yml at 5a083d0
name: Validate 'setup-go'
on:
push:
branches:
- main paths-ignore:
- '.md' pull_request: paths-ignore: - '.md' schedule:
- cron: 0 0 * * *
jobs:
stable:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] steps:
- uses: actions/checkout@v4 - name: Setup Go Stable uses: ./ with: go-version: stable - name: Verify Go run: go version
oldstable:
runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] steps:
- uses: actions/checkout@v4
- name: Setup Go oldStable uses: ./ with: go-version: oldstable - name: Verify Go run: go version
aliases-arch:
runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] version: [stable, oldstable] architecture: [x64, x32] exclude: - os: macos-latest architecture: x32 - os: macos-13 architecture: x32 steps:
- uses: actions/checkout@v4
- name: Setup Go ${{ matrix.version }} ${{ matrix.architecture }} uses: ./ with: go-version: ${{ matrix.version }} architecture: ${{ matrix.architecture }} - name: Verify Go run: go version
local-cache:
name: Setup local-cache version runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [macos-latest, windows-latest, ubuntu-latest, macos-13] go: [1.21.13, 1.22.8, 1.23.2] include: - os: windows-latest go: 1.20.14 exclude: - os: windows-latest go: 1.23.2 steps:
- name: Checkout uses: actions/checkout@v4
check-latest:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] go-version: ['1.20', '1.21', '1.22', '1.23'] steps:
- uses: actions/checkout@v4 - name: Setup Go and check latest uses: ./ with: go-version: ${{ matrix.go-version }} check-latest: true - name: Verify Go run: go version
go-version-file:
runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] steps:
- uses: actions/checkout@v4
- name: Setup Go and check latest uses: ./ with: go-version-file: tests/data/go.mod - name: verify go run: tests/verify-go.sh 1.20.14 shell: bash
go-version-file-with-gowork:
runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] steps:
- uses: actions/checkout@v4
- name: Setup Go and check latest uses: ./ with: go-version-file: tests/data/go.work - name: verify go run: tests/verify-go.sh 1.21 shell: bash
setup-versions-from-manifest:
runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [macos-latest, windows-latest, ubuntu-latest, macos-13] go: [1.20.14, 1.21.10, 1.22.8, 1.23.2] steps:
- name: Checkout uses: actions/checkout@v4
setup-versions-from-dist:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false matrix: os: [windows-latest, ubuntu-latest, macos-13] go: [1.11.12] steps:
- name: Checkout uses: actions/checkout@v4
architecture:
runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest, macos-13] go-version: [1.20.14, 1.21, 1.22, 1.23] include: - os: macos-latest architecture: arm64 - os: ubuntu-latest architecture: x64 - os: windows-latest architecture: x64 - os: macos-13 architecture: x64 steps:
- uses: actions/checkout@v4
- name: Setup Go and check latest uses: ./ with: go-version: ${{ matrix.go-version }} architecture: ${{ matrix.architecture }} - name: Verify Go run: go version<iframe src="https://codesandbox.io/p/devbox/pz34j4?migrateFrom=pgnt0&embed=1&file=%2Fsrc%2Fwidgets%2FHello.tsx" style="width:100%; height: 500px; border:0; border-radius: 4px; overflow:hidden;" title="magical-elbakyan-pgnt0" allow="accelerometer; ambient-light-sensor; camera; encrypted-media; geolocation; gyroscope; hid; microphone; midi; payment; usb; vr; xr-spatial-tracking" sandbox="allow-forms allow-modals allow-popups allow-presentation allow-same-origin allow-scripts"
/usr/bin/docker build -t 766e2c:4af29413fd8446b986d95086372a9a40 -f "/home/runner/work/_actions/getong/elasticsearch-action/95b501ab0c83dee0aac7c39b7cea3723bef14954/Dockerfile" "/home/runner/work/_actions/getong/elasticsearch-action/95b501ab0c83dee0aac7c39b7cea3723bef14954" #0 building with "default" instance using docker driver
#1 [internal] load build definition from Dockerfile #1 transferring dockerfile: 149B done
#1 DONE 0.0s
#2 [auth] library/docker:pull token for registry-1.docker.io #2 DONE 0.0s
#3 [internal] load metadata for docker.io/library/docker:stable #3 DONE 0.6s
#4 [internal] load .dockerignore
#4 transferring context: 2B done
#4 DONE 0.0s
#5 [internal] load build context
#5 transferring context: 890B done
#5 DONE 0.0s
#6 [1/3] FROM docker.io/library/docker:stable@sha256:fd4d028713fd05a1fb896412805daed82c4a0cc84331d8dad00cb596d7ce3e3a #6 resolve docker.io/library/docker:stable@sha256:fd4d028713fd05a1fb896412805daed82c4a0cc84331d8dad00cb596d7ce3e3a done #6 sha256:b0757c55a1fdbb59c378fd34dde3e12bd25f68094dd69546cf5ca00ddbaa7a33 4.21kB / 4.21kB done #6 sha256:0c7c675703d60dc4d757acb40557350159f600ca3d49e2e8d4c2039dd6b69457 0B / 2.04MB 0.1s #6 sha256:cc8c12a437cbe4e104dcea425e0ce277a2442603e14551d22a948e11026ae658 0B / 153B 0.1s #6 sha256:fd4d028713fd05a1fb896412805daed82c4a0cc84331d8dad00cb596d7ce3e3a 1.00kB / 1.00kB done #6 sha256:188c0c94c7c576fff0792aca7ec73d67a2f7f4cb3a6e53a84559337260b36964 2.80MB / 2.80MB 0.1s #6 sha256:8f71deccd0856d8a36db659a8c82894be97546b47c1817de27d5ee7eea860162 1.78kB / 1.78kB done #6 sha256:0c7c675703d60dc4d757acb40557350159f600ca3d49e2e8d4c2039dd6b69457 2.04MB / 2.04MB 0.1s done #6 sha256:cc8c12a437cbe4e104dcea425e0ce277a2442603e14551d22a948e11026ae658 153B / 153B 0.1s done #6 sha256:188c0c94c7c576fff0792aca7ec73d67a2f7f4cb3a6e53a84559337260b36964 2.80MB / 2.80MB 0.1s done #6 extracting sha256:188c0c94c7c576fff0792aca7ec73d67a2f7f4cb3a6e53a84559337260b36964 0.1s done #6 sha256:79aa7fa92271a7c1a46782d83623d7b9a111a2236c077aa11fe4bb289865955e 0B / 116B 0.2s #6 sha256:f092543453df2d4fbc4652f5584b56dd62987a33816ffd2a8d7ad9fad249b1ef 5.24MB / 62.89MB 0.2s #6 sha256:65b6bc45957d739e38db2da98d43e419af5fc45c46b8149f61b743dc613383e6 549B / 549B 0.2s done #6 sha256:4de832df471bbad41016f9621737b66aa5d8e575d7676661d111ea80b87e3946 1.02kB / 1.02kB 0.2s done #6 extracting sha256:0c7c675703d60dc4d757acb40557350159f600ca3d49e2e8d4c2039dd6b69457 #6 sha256:79aa7fa92271a7c1a46782d83623d7b9a111a2236c077aa11fe4bb289865955e 116B / 116B 0.2s done #6 sha256:f092543453df2d4fbc4652f5584b56dd62987a33816ffd2a8d7ad9fad249b1ef 50.33MB / 62.89MB 0.4s #6 extracting sha256:0c7c675703d60dc4d757acb40557350159f600ca3d49e2e8d4c2039dd6b69457 0.1s done #6 sha256:f092543453df2d4fbc4652f5584b56dd62987a33816ffd2a8d7ad9fad249b1ef 62.89MB / 62.89MB 0.5s done #6 extracting sha256:cc8c12a437cbe4e104dcea425e0ce277a2442603e14551d22a948e11026ae658 done #6 extracting sha256:f092543453df2d4fbc4652f5584b56dd62987a33816ffd2a8d7ad9fad249b1ef #6 extracting sha256:f092543453df2d4fbc4652f5584b56dd62987a33816ffd2a8d7ad9fad249b1ef 0.8s done #6 extracting sha256:65b6bc45957d739e38db2da98d43e419af5fc45c46b8149f61b743dc613383e6 #6 extracting sha256:65b6bc45957d739e38db2da98d43e419af5fc45c46b8149f61b743dc613383e6 done #6 extracting sha256:4de832df471bbad41016f9621737b66aa5d8e575d7676661d111ea80b87e3946 done #6 extracting sha256:79aa7fa92271a7c1a46782d83623d7b9a111a2236c077aa11fe4bb289865955e done #6 DONE 1.7s
#7 [2/3] COPY entrypoint.sh /entrypoint.sh
#7 DONE 0.0s
#8 [3/3] RUN chmod +x /entrypoint.sh
#8 DONE 0.2s
#9 exporting to image
#9 exporting layers
#9 exporting layers 0.2s done
#9 writing image sha256:82661a2b528d8edb6a1c0892427144ca7f050a53b246d5963b9f1658696cede4 done #9 naming to docker.io/library/766e2c:4af29413fd8446b986d95086372a9a40 done #9 DONE 0.2s