Skip to content

Commit

Permalink
Merge pull request #56 from home-assistant/dev
Browse files Browse the repository at this point in the history
Release 1.5
  • Loading branch information
pvizeli authored Jan 8, 2020
2 parents 2542082 + b9255fb commit 052178b
Show file tree
Hide file tree
Showing 7 changed files with 152 additions and 103 deletions.
3 changes: 2 additions & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
"context": "..",
"dockerFile": "Dockerfile",
"extensions": [
"ms-python.python"
"ms-python.python",
"esbenp.prettier-vscode"
],
"settings": {
"python.pythonPath": "/usr/local/bin/python",
Expand Down
58 changes: 28 additions & 30 deletions azure-pipelines-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,38 +4,36 @@ trigger:
batch: true
branches:
include:
- master
- dev
- master
- dev
pr:
- dev
- dev
variables:
- name: versionHadolint
value: 'v1.16.3'
- name: versionHadolint
value: "v1.16.3"

jobs:
- job: "Tox"
pool:
vmImage: "ubuntu-latest"
steps:
- task: UsePythonVersion@0
displayName: "Use Python $(python.version)"
inputs:
versionSpec: "3.7"
- script: pip install tox
displayName: "Install Tox"
- script: tox
displayName: "Run Tox"

- job: 'Tox'
pool:
vmImage: 'ubuntu-latest'
steps:
- task: UsePythonVersion@0
displayName: 'Use Python $(python.version)'
inputs:
versionSpec: '3.7'
- script: pip install tox
displayName: 'Install Tox'
- script: tox
displayName: 'Run Tox'


- job: 'Hadolint'
pool:
vmImage: 'ubuntu-latest'
steps:
- script: sudo docker pull hadolint/hadolint:$(versionHadolint)
displayName: 'Install Hadolint'
- script: |
sudo docker run --rm -i \
-v $(pwd)/.hadolint.yaml:/.hadolint.yaml:ro \
hadolint/hadolint:$(versionHadolint) < Dockerfile
displayName: 'Run Hadolint'
- job: "Hadolint"
pool:
vmImage: "ubuntu-latest"
steps:
- script: sudo docker pull hadolint/hadolint:$(versionHadolint)
displayName: "Install Hadolint"
- script: |
sudo docker run --rm -i \
-v $(pwd)/.hadolint.yaml:/.hadolint.yaml:ro \
hadolint/hadolint:$(versionHadolint) < Dockerfile
displayName: "Run Hadolint"
179 changes: 114 additions & 65 deletions azure-pipelines-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,76 +3,125 @@
trigger:
tags:
include:
- '*'
- "*"
pr: none
variables:
- name: versionBuilder
value: '4.4'
- group: docker
- name: versionBuilder
value: "4.4"
- group: docker
resources:
repositories:
- repository: azure
type: github
name: 'home-assistant/ci-azure'
endpoint: 'home-assistant'

- repository: azure
type: github
name: "home-assistant/ci-azure"
endpoint: "home-assistant"

stages:
- stage: "Validate"
jobs:
- template: templates/azp-job-version.yaml@azure
parameters:
ignoreDev: true

- stage: 'Validate'
jobs:
- template: templates/azp-job-version.yaml@azure
parameters:
ignoreDev: true

- stage: 'Wheels'
jobs:
- template: templates/azp-job-wheels.yaml@azure
parameters:
jobName: 'Wheels_Alpine39'
builderVersion: 'dev-3.7-alpine3.9'
builderApk: 'build-base;libffi-dev;openssl-dev'
wheelsRequirement: 'requirements_all.txt'
preBuild:
- script: |
cat requirements.txt requirements_build.txt > requirements_all.txt
displayName: 'Prepare requirements'
- template: templates/azp-job-wheels.yaml@azure
parameters:
jobName: 'Wheels_Alpine310'
builderVersion: 'dev-3.7-alpine3.10'
builderApk: 'build-base;libffi-dev;openssl-dev'
wheelsRequirement: 'requirements_all.txt'
preBuild:
- script: |
cat requirements.txt requirements_build.txt > requirements_all.txt
displayName: 'Prepare requirements'
- stage: "Wheels"
jobs:
- template: templates/azp-job-wheels.yaml@azure
parameters:
jobName: "Wheels_37_Alpine39"
builderVersion: "dev-3.7-alpine3.9"
builderApk: "build-base;libffi-dev;openssl-dev"
wheelsRequirement: "requirements_all.txt"
preBuild:
- script: |
cat requirements.txt requirements_build.txt > requirements_all.txt
displayName: "Prepare requirements"
- template: templates/azp-job-wheels.yaml@azure
parameters:
jobName: "Wheels_37_Alpine310"
builderVersion: "dev-3.7-alpine3.10"
builderApk: "build-base;libffi-dev;openssl-dev"
wheelsRequirement: "requirements_all.txt"
preBuild:
- script: |
cat requirements.txt requirements_build.txt > requirements_all.txt
displayName: "Prepare requirements"
- template: templates/azp-job-wheels.yaml@azure
parameters:
jobName: "Wheels_37_Alpine311"
builderVersion: "dev-3.7-alpine3.11"
builderApk: "build-base;libffi-dev;openssl-dev"
wheelsRequirement: "requirements_all.txt"
preBuild:
- script: |
cat requirements.txt requirements_build.txt > requirements_all.txt
displayName: "Prepare requirements"
- template: templates/azp-job-wheels.yaml@azure
parameters:
jobName: "Wheels_38_Alpine39"
builderVersion: "dev-3.8-alpine3.9"
builderApk: "build-base;libffi-dev;openssl-dev"
wheelsRequirement: "requirements_all.txt"
preBuild:
- script: |
cat requirements.txt requirements_build.txt > requirements_all.txt
displayName: "Prepare requirements"
- template: templates/azp-job-wheels.yaml@azure
parameters:
jobName: "Wheels_38_Alpine310"
builderVersion: "dev-3.8-alpine3.10"
builderApk: "build-base;libffi-dev;openssl-dev"
wheelsRequirement: "requirements_all.txt"
preBuild:
- script: |
cat requirements.txt requirements_build.txt > requirements_all.txt
displayName: "Prepare requirements"
- template: templates/azp-job-wheels.yaml@azure
parameters:
jobName: "Wheels_38_Alpine311"
builderVersion: "dev-3.8-alpine3.11"
builderApk: "build-base;libffi-dev;openssl-dev"
wheelsRequirement: "requirements_all.txt"
preBuild:
- script: |
cat requirements.txt requirements_build.txt > requirements_all.txt
displayName: "Prepare requirements"
- stage: 'Release'
jobs:
- job: 'Release'
pool:
vmImage: 'ubuntu-latest'
strategy:
maxParallel: 2
matrix:
37-Alpine39:
buildPython: '3.7-alpine3.9'
buildArgs: ''
37-Alpine310:
buildPython: '3.7-alpine3.10'
buildArgs: '--release-tag'
steps:
- script: sudo docker login -u $(dockerUser) -p $(dockerPassword)
displayName: 'Docker hub login'
- script: sudo docker pull homeassistant/amd64-builder:$(versionBuilder)
displayName: 'Install Builder'
- script: |
sudo docker run --rm --privileged \
-v ~/.docker:/root/.docker \
-v /run/docker.sock:/run/docker.sock:rw -v $(pwd):/data:ro \
homeassistant/amd64-builder:$(versionBuilder) \
--builder-wheels $(buildPython) --all \
$(buildArgs) --version $(Build.SourceBranchName) \
-t /data --docker-hub homeassistant
displayName: 'Build Release'
- stage: "Release"
jobs:
- job: "Release"
pool:
vmImage: "ubuntu-latest"
strategy:
matrix:
37-Alpine39:
buildPython: "3.7-alpine3.9"
buildArgs: ""
37-Alpine310:
buildPython: "3.7-alpine3.10"
buildArgs: ""
37-Alpine311:
buildPython: "3.7-alpine3.11"
buildArgs: ""
38-Alpine39:
buildPython: "3.8-alpine3.9"
buildArgs: ""
38-Alpine310:
buildPython: "3.8-alpine3.10"
buildArgs: ""
38-Alpine311:
buildPython: "3.8-alpine3.11"
buildArgs: "--release-tag"
steps:
- script: sudo docker login -u $(dockerUser) -p $(dockerPassword)
displayName: "Docker hub login"
- script: sudo docker pull homeassistant/amd64-builder:$(versionBuilder)
displayName: "Install Builder"
- script: |
sudo docker run --rm --privileged \
-v ~/.docker:/root/.docker \
-v /run/docker.sock:/run/docker.sock:rw -v $(pwd):/data:ro \
homeassistant/amd64-builder:$(versionBuilder) \
--builder-wheels $(buildPython) --all \
$(buildArgs) --version $(Build.SourceBranchName) \
-t /data --docker-hub homeassistant
displayName: "Build Release"
3 changes: 2 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
click==7.0
click-pathlib==2019.6.13.1
click-pathlib==2019.12.28.7
requests==2.22.0
wheel==0.33.6
setuptools==44.0.0
4 changes: 2 additions & 2 deletions requirements_build.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Cython==0.29.13
numpy==1.17.2
Cython==0.29.14
numpy==1.18.1
6 changes: 3 additions & 3 deletions requirements_tests.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
flake8==3.7.8
pylint==2.4.2
black==19.3b0
flake8==3.7.9
pylint==2.4.4
black==19.10b0
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from setuptools import setup

VERSION = "1.4"
VERSION = "1.5"

setup(
name="builder",
Expand Down

0 comments on commit 052178b

Please sign in to comment.