Skip to content

Merge pull request #29 from jmgraeffe/feature/cancellable-dial-in #89

Merge pull request #29 from jmgraeffe/feature/cancellable-dial-in

Merge pull request #29 from jmgraeffe/feature/cancellable-dial-in #89

Workflow file for this run

on: [push]
name: Test
jobs:
test:
strategy:
matrix:
go-version: [1.16.x]
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: ${{ matrix.go-version }}
- name: Checkout code
uses: actions/checkout@v2
- name: Checkout SCION
run: |
# Get scion version from go modules. The sed command extracts the
# replacement if one is specified in the go.mod file.
scion_mod_version=$(go list -m github.com/scionproto/scion | sed -s 's/.*\s*=>\s*//')
scion_repo=https://${scion_mod_version% *}.git
# Extract the commit hash, which is the last part of the go modules version
scion_commit=${scion_mod_version##*[ -]}
git clone ${scion_repo} ~/scion
cd ~/scion
git checkout 5883c725f74830da9becb306a1fa5cfe2fa5017a # --quiet ${scion_commit}
- name: Build SCION
run: |
# Log tool versions provided by CircleCi
go version
python3 --version
cd ~/scion
for service in "posix-router" "cs" "dispatcher" "scion-pki" "daemon"; do
go build -o ./bin/ ./go/${service}/ && echo "Built ${service}";
done
pip3 install -U wheel setuptools
pip3 install -r ~/scion/env/pip3/requirements.txt
- name: Configure and start local SCION AS
run: |
cd ~/scion
export PYTHONPATH=python/:.
# Generate tiny4.topo
printf '#!/bin/bash\necho "0.0.0.0"' > tools/docker-ip # Some hackery to make topo scripts run
# Use IPv4 addresses for this test
python3 python/topology/generator.py -c ./topology/tiny4.topo
# Link the gen directory containing sciond_addresses.json and as_list.json
cat ~/scion/gen/sciond_addresses.json
# ln -s ~/scion/gen /home/circleci/project/gen
mkdir gen-cache
# Start all AS tiny4.topo
supervisor/supervisor.sh reload
supervisor/supervisor.sh start all
- name: Test Connections
run: go test -v ./...
env:
SCION_DAEMON_ADDRESS: "127.0.0.12:30255"