-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #295 from simonsobs/develop
Release v0.3.1
- Loading branch information
Showing
98 changed files
with
7,249 additions
and
2,762 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
[flake8] | ||
max_line_length = 80 | ||
ignore = E501 | ||
in-place = true | ||
recursive = true | ||
aggressive = 2 | ||
exclude = | ||
agents/meinberg_m1000/mibs/MBG-SNMP-LTNG-MIB.py | ||
agents/meinberg_m1000/mibs/SNMPv2-MIB.py | ||
agents/meinberg_m1000/mibs/MBG-SNMP-ROOT-MIB.py |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# Please see the documentation for all configuration options: | ||
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates | ||
|
||
version: 2 | ||
updates: | ||
- package-ecosystem: "github-actions" | ||
directory: "/" | ||
schedule: | ||
interval: "daily" |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,75 +3,16 @@ name: Build Develop Images | |
on: | ||
push: | ||
branches: [ develop ] | ||
paths-ignore: | ||
- 'docs/**' | ||
- '*.rst' | ||
- '*.md' | ||
- '.flake8' | ||
- '.pre-commit-config.yaml' | ||
|
||
jobs: | ||
test: | ||
name: pytest with coverage | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Cancel Previous Runs | ||
uses: styfle/[email protected] | ||
with: | ||
access_token: ${{ github.token }} | ||
|
||
- name: Install system packages | ||
run: | | ||
sudo apt-get install -y socat | ||
- name: Set up Python 3.8 | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.8 | ||
|
||
# (start steps from pytest workflow) | ||
# Install | ||
- name: Install so3g | ||
run: | | ||
pip3 install so3g | ||
# Fetch all history for all tags and branches | ||
- name: clone socs | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Install socs | ||
run: | | ||
pip3 install -r requirements.txt | ||
pip3 install -e . | ||
# Unit Tests | ||
- name: Run unit tests | ||
working-directory: ./tests | ||
run: | | ||
COVERAGE_FILE=.coverage.unit python3 -m pytest --cov -m 'not integtest' | ||
- name: Build docker test images | ||
run: | | ||
docker-compose build socs | ||
# Integration Tests | ||
- name: Build images for integration tests | ||
run: | | ||
docker-compose build ocs-lakeshore372-simulator | ||
- name: Run integration tests | ||
working-directory: ./tests | ||
run: | | ||
COVERAGE_FILE=.coverage.int python3 -m pytest --cov -m 'integtest' | ||
# Coverage | ||
- name: Report test coverage | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
mv ./tests/.coverage.* ./ | ||
pip install coveralls | ||
coverage combine | ||
coverage report | ||
coveralls --service=github | ||
# (end steps from pytest workflow) | ||
uses: ./.github/workflows/pytest.yml | ||
|
||
build: | ||
name: build and deploy dev images | ||
|
@@ -81,7 +22,7 @@ jobs: | |
steps: | ||
# Fetch all history for all tags and branches | ||
- name: clone socs | ||
uses: actions/checkout@v2 | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
|
||
|
@@ -90,19 +31,59 @@ jobs: | |
run: | | ||
docker-compose build | ||
- name: Login to Docker Hub | ||
uses: docker/login-action@v2 | ||
with: | ||
username: ${{ secrets.REGISTRY_USER }} | ||
password: ${{ secrets.REGISTRY_PASSWORD }} | ||
|
||
- name: Build and push development docker image | ||
env: | ||
REGISTRY_PASSWORD: ${{ secrets.REGISTRY_PASSWORD }} | ||
REGISTRY_USER: ${{ secrets.REGISTRY_USER }} | ||
DOCKERHUB_ORG: "simonsobs" | ||
run: | | ||
export DOCKER_TAG=`git describe --tags --always`-dev | ||
echo "${DOCKER_TAG}" | ||
echo "${REGISTRY_PASSWORD}" | docker login -u "${REGISTRY_USER}" --password-stdin; | ||
# Tag all images for upload to the registry | ||
docker-compose config | grep 'image: ' | awk -F ': ' '{ print $2 }' | xargs -I {} docker tag {}:latest ${DOCKERHUB_ORG}/{}:${DOCKER_TAG} | ||
# Upload to docker registry | ||
docker-compose config | grep 'image: ' | awk -F ': ' '{ print $2 }' | xargs -I {} docker push ${DOCKERHUB_ORG}/{}:${DOCKER_TAG} | ||
docker-compose config | grep 'image: ' | awk -F ': ' '{ print $2 }' | xargs -I {} echo ${DOCKERHUB_ORG}/{}:${DOCKER_TAG} pushed | ||
# testing so we can catch any issues before release | ||
# if issues are found, test locally, or copy to pytest.yml for test on push | ||
wheel: | ||
name: build and test wheel | ||
needs: test | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Set up Python 3.8 | ||
uses: actions/setup-python@v3 | ||
with: | ||
python-version: 3.8 | ||
|
||
- name: clone socs | ||
uses: actions/checkout@v3 | ||
|
||
- name: install build dependencies | ||
run: | | ||
python3 -m pip install --upgrade build twine | ||
- name: build wheel | ||
run: | | ||
python3 -m build | ||
- name: install wheel | ||
run: | | ||
python3 -m pip install dist/socs*.whl | ||
- name: install testing requirements | ||
run: | | ||
pip3 install -r requirements/testing.txt | ||
- name: Run unit tests | ||
working-directory: ./tests | ||
run: | | ||
python3 -m pytest -m 'not integtest' |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: Run Tests | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- 'docs/**' | ||
- '*.rst' | ||
- '*.md' | ||
- '.flake8' | ||
- '.pre-commit-config.yaml' | ||
|
||
jobs: | ||
test: | ||
name: pytest with coverage | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- run: 'echo "No build required" ' |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: Test Docker Build | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- 'docs/**' | ||
- '*.rst' | ||
- '*.md' | ||
- '.flake8' | ||
- '.pre-commit-config.yaml' | ||
|
||
jobs: | ||
build: | ||
name: test image build | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- run: 'echo "No build required" ' |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: Test Docker Build | ||
|
||
on: | ||
pull_request: | ||
paths-ignore: | ||
- 'docs/**' | ||
- '*.rst' | ||
- '*.md' | ||
- '.flake8' | ||
- '.pre-commit-config.yaml' | ||
|
||
jobs: | ||
build: | ||
name: test image build | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
# Fetch all history for all tags and branches | ||
- name: clone socs | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
|
||
# Dockerize | ||
- name: Build docker images | ||
run: | | ||
docker-compose build |
Oops, something went wrong.