Skip to content

Update agentstate to include task network namespace and default interface name to populate task network config #8631

Update agentstate to include task network namespace and default interface name to populate task network config

Update agentstate to include task network namespace and default interface name to populate task network config #8631

Workflow file for this run

name: Static Checks
on: [push, pull_request]
permissions: read-all
jobs:
static-check:
name: Static Analysis
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
path: src/github.com/aws/amazon-ecs-agent
- name: get GO_VERSION
id: get-go-version
run: |
cd $GITHUB_WORKSPACE/src/github.com/aws/amazon-ecs-agent
set -eou pipefail
go_version=$(cat GO_VERSION | tr -d '\n')
go_version_length=${#go_version}
go_version_re="^([0-9]+\.){1,2}([0-9]+)$"
if ! [[ $go_version_length -le 10 && $go_version =~ $go_version_re ]] ; then
echo "invalid GO version"
exit 1
fi
echo "GO_VERSION=$go_version" >> $GITHUB_OUTPUT
- uses: actions/setup-go@v3
with:
go-version: ${{ steps.get-go-version.outputs.GO_VERSION }}
- uses: actions/checkout@v3
with:
path: src/github.com/aws/amazon-ecs-agent
- name: run static checks
run: |
export GOPATH=$GITHUB_WORKSPACE
export PATH=$PATH:$(go env GOPATH)/bin
export GO111MODULE=auto
cd $GITHUB_WORKSPACE/src/github.com/aws/amazon-ecs-agent
make get-deps
make static-check
init-check:
name: Static Analysis Init
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
path: src/github.com/aws/amazon-ecs-agent
- name: get GO_VERSION
id: get-go-version
run: |
cd $GITHUB_WORKSPACE/src/github.com/aws/amazon-ecs-agent
set -eou pipefail
go_version=$(cat GO_VERSION | tr -d '\n')
go_version_length=${#go_version}
go_version_re="^([0-9]+\.){1,2}([0-9]+)$"
if ! [[ $go_version_length -le 10 && $go_version =~ $go_version_re ]] ; then
echo "invalid GO version"
exit 1
fi
echo "GO_VERSION=$go_version" >> $GITHUB_OUTPUT
- uses: actions/setup-go@v3
with:
go-version: ${{ steps.get-go-version.outputs.GO_VERSION }}
- uses: actions/checkout@v3
with:
path: src/github.com/aws/amazon-ecs-agent
- name: run static checks
run: |
export GOPATH=$GITHUB_WORKSPACE
export PATH=$PATH:$(go env GOPATH)/bin
export GO111MODULE=auto
cd $GITHUB_WORKSPACE/src/github.com/aws/amazon-ecs-agent
make get-deps-init
make static-check-init
x-platform-build:
name: Cross platform build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
path: src/github.com/aws/amazon-ecs-agent
- name: get GO_VERSION
id: get-go-version
run: |
cd $GITHUB_WORKSPACE/src/github.com/aws/amazon-ecs-agent
set -eou pipefail
go_version=$(cat GO_VERSION | tr -d '\n')
go_version_length=${#go_version}
go_version_re="^([0-9]+\.){1,2}([0-9]+)$"
if ! [[ $go_version_length -le 10 && $go_version =~ $go_version_re ]] ; then
echo "invalid GO version"
exit 1
fi
echo "GO_VERSION=$go_version" >> $GITHUB_OUTPUT
- uses: actions/setup-go@v3
with:
go-version: ${{ steps.get-go-version.outputs.GO_VERSION }}
- uses: actions/checkout@v3
with:
submodules: true
path: src/github.com/aws/amazon-ecs-agent
- name: make xplatform-build
run: |
export GOPATH=$GITHUB_WORKSPACE
export GO111MODULE=auto
cd $GITHUB_WORKSPACE/src/github.com/aws/amazon-ecs-agent
make xplatform-build