Compare commits
84 Commits
| Author | SHA1 | Date |
|---|---|---|
|
|
a0efc4190e | |
|
|
a9f12ff2eb | |
|
|
4380217e36 | |
|
|
37f20da5b1 | |
|
|
554bc21904 | |
|
|
5a59d4643a | |
|
|
93eb6c1aee | |
|
|
85eb07f88b | |
|
|
144ebcbb3b | |
|
|
8d0f77d34e | |
|
|
6c77283c0b | |
|
|
107816c105 | |
|
|
af7a391ad2 | |
|
|
23f4e22953 | |
|
|
445e0005de | |
|
|
361c456747 | |
|
|
e6f19beba9 | |
|
|
931e04ebed | |
|
|
c115f2370e | |
|
|
3f583288c8 | |
|
|
ca0b3ca8de | |
|
|
a5c87ca97e | |
|
|
706cc0aa37 | |
|
|
6922f1be13 | |
|
|
397e2c4c1f | |
|
|
1d3fae5092 | |
|
|
05d073e562 | |
|
|
f578739521 | |
|
|
e555fd4c2e | |
|
|
8b295755fc | |
|
|
9587bb96e9 | |
|
|
56d5b54615 | |
|
|
5cada884d7 | |
|
|
d382a39c45 | |
|
|
951d22c4ed | |
|
|
d40a876b9f | |
|
|
2bb5e714d7 | |
|
|
8e5b9ece16 | |
|
|
63002dde72 | |
|
|
729e5b5656 | |
|
|
12d8b3314d | |
|
|
7ebf705745 | |
|
|
1e650bc0a1 | |
|
|
ed99e16a9b | |
|
|
fe9de929b0 | |
|
|
1ff8a71359 | |
|
|
d15ec399ff | |
|
|
22332d0bb6 | |
|
|
7cf1f8fbef | |
|
|
30f066f819 | |
|
|
26ae425f9a | |
|
|
96c061d580 | |
|
|
4c96116999 | |
|
|
9711d39acc | |
|
|
2790c68add | |
|
|
fb21d43836 | |
|
|
5b60d83552 | |
|
|
58c92f92ac | |
|
|
9c6cfdb261 | |
|
|
f9fe688f7b | |
|
|
4371dff5b5 | |
|
|
8fe368b66b | |
|
|
510422f36a | |
|
|
b29c86006e | |
|
|
5e3a9b85d8 | |
|
|
57533b4b2f | |
|
|
a66df8d042 | |
|
|
7d6bf91a27 | |
|
|
9bbeca9204 | |
|
|
c325ab170c | |
|
|
cf1afcd9d3 | |
|
|
65d8b36f8f | |
|
|
a230c36c04 | |
|
|
5f1e19be9b | |
|
|
865135fbe7 | |
|
|
1cb0aba7d7 | |
|
|
0f32d114e4 | |
|
|
7af7532e6a | |
|
|
add8bfd42a | |
|
|
d093eb362e | |
|
|
f2c0d804a6 | |
|
|
02bec376a0 | |
|
|
9a833f437e | |
|
|
020f808f28 |
|
|
@ -0,0 +1,25 @@
|
|||
name: Erase old versions
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- clean_*
|
||||
repository_dispatch:
|
||||
types: [clean]
|
||||
|
||||
jobs:
|
||||
do_clean:
|
||||
name: Remove old versions
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Remove old untagged and dev_* versions
|
||||
run: |
|
||||
cd tools
|
||||
python3 garbage_collector.py ${{ secrets.PKG_TOKEN }}
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
name: Tag images to make them visible
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- deploy_*
|
||||
repository_dispatch:
|
||||
types: [deploy]
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Log in to the Container registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Generate official tags
|
||||
run: |
|
||||
cd deploy
|
||||
./build.sh
|
||||
|
|
@ -1,35 +0,0 @@
|
|||
name: Docker Hub upload (normal)
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- b*
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Extract metadata (tags, labels) for Docker
|
||||
id: meta
|
||||
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
|
||||
with:
|
||||
images: setsoft/kicad_auto
|
||||
|
||||
- name: Build and push Docker image
|
||||
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
|
||||
with:
|
||||
# context: tools/dev_image
|
||||
push: true
|
||||
tags: setsoft/kicad_auto:latest
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
name: KiBot (KiCad 5) Docker image
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- ki5_*
|
||||
repository_dispatch:
|
||||
types: [build_k5]
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Log in to the Container registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Build and push Docker image
|
||||
run: |
|
||||
cd ki5
|
||||
./build.sh
|
||||
|
|
@ -0,0 +1,42 @@
|
|||
name: KiBot (KiCad 5 deps) Docker image
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- ki5p_*
|
||||
repository_dispatch:
|
||||
types: [build_k5p]
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Log in to the Container registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Build and push Docker image
|
||||
run: |
|
||||
cd ki5_pre
|
||||
./build.sh
|
||||
|
||||
- name: Trigger KiCad-Auto image build
|
||||
run: |
|
||||
curl -X POST -u "${{secrets.PAT_USERNAME}}:${{secrets.PAT_TOKEN}}" -H "Accept: application/vnd.github.v3+json" -H "Content-Type: application/json" https://api.github.com/repos/INTI-CMNB/kicad_auto/dispatches --data '{"event_type": "build_k5"}'
|
||||
|
|
@ -1,35 +1,38 @@
|
|||
name: Docker Hub upload (KiCad 6)
|
||||
name: KiBot (KiCad 6) Docker image
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- ki6_*
|
||||
repository_dispatch:
|
||||
types: [build_k6]
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v2
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Extract metadata (tags, labels) for Docker
|
||||
id: meta
|
||||
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
|
||||
- name: Log in to the Container registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
images: setsoft/kicad_auto
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Build and push Docker image
|
||||
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
|
||||
with:
|
||||
context: ki6
|
||||
push: true
|
||||
tags: setsoft/kicad_auto:ki6
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
run: |
|
||||
cd ki6
|
||||
./build.sh
|
||||
|
|
|
|||
|
|
@ -0,0 +1,42 @@
|
|||
name: KiBot (KiCad 6 deps) Docker image
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- ki6p_*
|
||||
repository_dispatch:
|
||||
types: [build_k6p]
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Log in to the Container registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Build and push Docker image
|
||||
run: |
|
||||
cd ki6_pre
|
||||
./build.sh
|
||||
|
||||
- name: Trigger KiCad-Auto image build
|
||||
run: |
|
||||
curl -X POST -u "${{secrets.PAT_USERNAME}}:${{secrets.PAT_TOKEN}}" -H "Accept: application/vnd.github.v3+json" -H "Content-Type: application/json" https://api.github.com/repos/INTI-CMNB/kicad_auto/dispatches --data '{"event_type": "build_k6"}'
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
name: KiBot (KiCad 7) Docker image
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- ki7_*
|
||||
repository_dispatch:
|
||||
types: [build_k7]
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Log in to the Container registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Build and push Docker image
|
||||
run: |
|
||||
cd ki7
|
||||
./build.sh
|
||||
|
|
@ -0,0 +1,42 @@
|
|||
name: KiBot (KiCad 7 deps) Docker image
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- ki7p_*
|
||||
repository_dispatch:
|
||||
types: [build_k7p]
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Log in to the Container registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Build and push Docker image
|
||||
run: |
|
||||
cd ki7_pre
|
||||
./build.sh
|
||||
|
||||
- name: Trigger KiCad-Auto image build
|
||||
run: |
|
||||
curl -X POST -u "${{secrets.PAT_USERNAME}}:${{secrets.PAT_TOKEN}}" -H "Accept: application/vnd.github.v3+json" -H "Content-Type: application/json" https://api.github.com/repos/INTI-CMNB/kicad_auto/dispatches --data '{"event_type": "build_k7"}'
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
name: KiBot (KiCad 8) Docker image
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- ki8_*
|
||||
repository_dispatch:
|
||||
types: [build_k8]
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Log in to the Container registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Build and push Docker image
|
||||
run: |
|
||||
cd ki8
|
||||
./build.sh
|
||||
|
|
@ -0,0 +1,42 @@
|
|||
name: KiBot (KiCad 8 deps) Docker image
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- ki8p_*
|
||||
repository_dispatch:
|
||||
types: [build_k8p]
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Log in to the Container registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Build and push Docker image
|
||||
run: |
|
||||
cd ki8_pre
|
||||
./build.sh
|
||||
|
||||
- name: Trigger KiCad-Auto image build
|
||||
run: |
|
||||
curl -X POST -u "${{secrets.PAT_USERNAME}}:${{secrets.PAT_TOKEN}}" -H "Accept: application/vnd.github.v3+json" -H "Content-Type: application/json" https://api.github.com/repos/INTI-CMNB/kicad_auto/dispatches --data '{"event_type": "build_k8"}'
|
||||
|
|
@ -0,0 +1,55 @@
|
|||
name: Docker Hub upload (normal)
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- b*
|
||||
repository_dispatch:
|
||||
types: [build_mk6]
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub and GitHub Packages
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Log in to the Container registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Extract metadata (tags, labels) for Docker
|
||||
id: meta
|
||||
uses: docker/metadata-action@v4
|
||||
with:
|
||||
images: |
|
||||
setsoft/kicad_auto
|
||||
ghcr.io/${{ github.repository }}
|
||||
ghcr.io/inti-cmnb/kicad6_auto
|
||||
tags: |
|
||||
type=raw,manjaro_k6
|
||||
|
||||
- name: Build and push Docker images
|
||||
uses: docker/build-push-action@v3
|
||||
with:
|
||||
context: manjaro
|
||||
push: true
|
||||
tags: |
|
||||
setsoft/kicad_auto:manjaro_k6
|
||||
ghcr.io/inti-cmnb/kicad_auto:manjaro_k6
|
||||
ghcr.io/inti-cmnb/kicad6_auto:manjaro
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
|
|
@ -1,35 +1,57 @@
|
|||
name: Docker Hub upload (nightly)
|
||||
name: Docker Hub upload (KiCad 7 nightly)
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- n*
|
||||
repository_dispatch:
|
||||
types: [build_ng]
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
name: Push Docker image to Docker Hub and GitHub Packages
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v2
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Log in to the Container registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Extract metadata (tags, labels) for Docker
|
||||
id: meta
|
||||
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
|
||||
uses: docker/metadata-action@v4
|
||||
with:
|
||||
images: setsoft/kicad_auto
|
||||
images: |
|
||||
setsoft/kicad_auto
|
||||
ghcr.io/${{ github.repository }}
|
||||
tags: |
|
||||
type=raw,nightly
|
||||
|
||||
- name: Build and push Docker image
|
||||
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
|
||||
- name: Build and push Docker images
|
||||
uses: docker/build-push-action@v3
|
||||
with:
|
||||
context: nightly
|
||||
push: true
|
||||
tags: setsoft/kicad_auto:nightly
|
||||
tags: |
|
||||
setsoft/kicad_auto:nightly
|
||||
ghcr.io/inti-cmnb/kicad_auto:nightly
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
|
||||
- name: Trigger KiCad-Auto-Test image build
|
||||
run: |
|
||||
curl -X POST -u "${{secrets.PAT_USERNAME}}:${{secrets.PAT_TOKEN}}" -H "Accept: application/vnd.github.v3+json" -H "Content-Type: application/json" https://api.github.com/repos/INTI-CMNB/kicad_auto_test/dispatches --data '{"event_type": "build_ng"}'
|
||||
|
|
|
|||
19
Dockerfile
19
Dockerfile
|
|
@ -1,19 +0,0 @@
|
|||
FROM setsoft/kicad_debian:latest
|
||||
MAINTAINER Salvador E. Tropea <set@ieee.org>
|
||||
LABEL Description="KiCad with KiBot and other automation scripts"
|
||||
|
||||
RUN sed -i -e's/ main/ main contrib non-free/g' /etc/apt/sources.list && \
|
||||
apt-get update && \
|
||||
apt-get -y install -t buster-backports make wget curl rar bzip2 librsvg2-bin && \
|
||||
apt-get -y install --no-install-recommends imagemagick python3-qrcodegen git poppler-utils && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/KiAuto/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/KiBoM/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/InteractiveHtmlBom/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/PcbDraw/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/KiCost/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/KiBot/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
apt -y install --no-install-recommends ./*.deb && \
|
||||
apt-get -y remove curl wget && \
|
||||
apt-get -y autoremove && \
|
||||
rm /*.deb && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 9.9 KiB |
88
README.md
88
README.md
|
|
@ -2,25 +2,77 @@
|
|||
|
||||
Docker image for KiCad automation scripts suitable for CI/CD
|
||||
|
||||
The main objetive is to use it as a base for [KiCad automation in CI/CD environments](https://github.com/INTI-CMNB/kicad_ci_test).
|
||||
The main objetive is to use it as a base for [KiCad automation in CI/CD environments](https://github.com/INTI-CMNB/KiBot).
|
||||
|
||||
The images are uploaded to [Docker Hub](https://hub.docker.com/r/setsoft/kicad_auto).
|
||||
The images are uploaded to [Docker Hub](https://hub.docker.com/r/setsoft/kicad_auto) and GitHub:
|
||||
[KiCad 5](https://github.com/INTI-CMNB/kicad_auto/pkgs/container/kicad5_auto),
|
||||
[KiCad 6](https://github.com/INTI-CMNB/kicad_auto/pkgs/container/kicad6_auto),
|
||||
[KiCad 7](https://github.com/INTI-CMNB/kicad_auto/pkgs/container/kicad7_auto),
|
||||
[KiCad 8](https://github.com/INTI-CMNB/kicad_auto/pkgs/container/kicad8_auto) and
|
||||
[Old compatibility names](https://github.com/INTI-CMNB/kicad_auto/pkgs/container/kicad_auto),
|
||||
|
||||
This image is based on [setsoft/kicad_debian](https://github.com/INTI-CMNB/kicad_debian) and adds some automation tools to it:
|
||||
This image is based on [kicad_debian](https://github.com/INTI-CMNB/kicad_debian) and adds some automation tools to it:
|
||||
|
||||
* [Kiplot](https://github.com/INTI-CMNB/kiplot) generate gerbers, drill and position files
|
||||
* [kicad-automation-scripts](https://github.com/INTI-CMNB/kicad-automation-scripts) runs DRC/ERC, prints schematics and PCB
|
||||
* [KiBot](https://github.com/INTI-CMNB/KiBot) generate gerbers, drill, position files, etc.
|
||||
* [KiAuto](https://github.com/INTI-CMNB/KiAuto) runs DRC/ERC, prints schematics, PCB, etc.
|
||||
* [KiBoM](https://github.com/INTI-CMNB/KiBoM) generates HTML and CSV BoMs
|
||||
* [InteractiveHtmlBom](https://github.com/INTI-CMNB/InteractiveHtmlBom) generates interactive HTML BoMs
|
||||
* [PcbDraw](https://github.com/INTI-CMNB/PcbDraw) generates 2D renders of the PCB
|
||||
* [KiCost](https://github.com/hildogjr/KiCost) generates BoMs with prices
|
||||
* [KiCad Git filters](https://github.com/INTI-CMNB/kicad-git-filters) helps to reduce unneeded commits for KiCad files when using git
|
||||
* [KiDiff](https://github.com/INTI-CMNB/KiDiff) a tool to see differences between PCBs and schematics, can be used as git plugin
|
||||
* [KiKit](https://github.com/yaqwsx/KiKit) stencil and panelization tools
|
||||
|
||||
The available tags are:
|
||||
The relation between the packages that contains the images is as depicted in the following image:
|
||||
|
||||
* **10.3-5.1.5** is KiCad 5.1.5 on Debian 10.3 with Kiplot 0.2.4, kicad-automation-scripts 1.3.1, KiBoM 1.6.3 and interactivehtmlbom 2.3.1
|
||||
* **10.4-5.1.6** is KiCad 5.1.6 on Debian 10.4 with KiBot 0.7.0, kicad-automation-scripts 1.4.2, KiBoM 1.8.0, interactivehtmlbom 2.3.3 and PcbDraw 0.6.0-2
|
||||
* **10.4-5.1.9** (same as **latest**) is KiCad 5.1.9 on Debian 10.4 with KiBot 0.11.0, KiAuto 1.6.4, KiBoM 1.8.0, interactivehtmlbom 2.4.1 and PcbDraw 0.9.0-1
|
||||
* **bullseye-6.0.0-RC1-20211204** (same as **nightly**) is KiCad 6.0.0 RC1 (20211204) on Debian bullseye with KiBot 0.11.0, kicad-automation-scripts 1.6.4, KiBoM 1.8.0, interactivehtmlbom 2.4.1 and PcbDraw 0.9.0-1
|
||||
* **ki6.0.0_Ubuntu21.10** (same as **ki6**) KiCad 6.0.0 (final release) on is Ubuntu Impish with KiBot 0.11.0, kicad-automation-scripts 1.6.4, KiBoM 1.8.0, interactivehtmlbom 2.4.1 and PcbDraw 0.9.0-1
|
||||

|
||||
|
||||
|
||||
Here are some of the available images:
|
||||
|
||||
## KiCad 5
|
||||
|
||||
| Name | KiBot | KiCad | Debian | KiAuto | KiBoM | iBoM | KiCost | DK plug | PcbDraw | KiDiff |
|
||||
| :---------------------------------------- | ------ | ----- | ------ | ------ | ------- | -------- | ------ | ------- | ------- | -----: |
|
||||
| setsoft/kicad_auto:10.3-5.1.5 | 0.2.4 | 5.1.5 | 10.3 | 1.3.1 | 1.6.3 | 2.3.1 | -- | -- | -- | -- |
|
||||
| setsoft/kicad_auto:10.4-5.1.6 | 0.7.0 | 5.1.6 | 10.4 | 1.4.2 | 1.8.0 | 2.3.3 | -- | -- | 0.6.0-2 | -- |
|
||||
| ghcr.io/inti-cmnb/kicad5_auto:1.2.0 | 1.2.0 | 5.1.9 | 10.4 | 1.6.15 | 1.8.0 | 2.5.0 | 1.1.10 | 0.1.1 | 0.9.0-3 | -- |
|
||||
| ghcr.io/inti-cmnb/kicad5_auto:1.3.0 | 1.3.0 | 5.1.9 | 11.5 | 2.0.6 | 1.8.0-2 | 2.5.0 | 1.1.12 | 0.1.2 | 0.9.0-4 | 2.4.2 |
|
||||
| ghcr.io/inti-cmnb/kicad5_auto:1.4.0 | 1.4.0 | 5.1.9 | 11.5 | 2.0.6 | 1.8.0-3 | 2.5.0-2 | 1.1.15 | 0.1.2 | 0.9.0-5 | 2.4.3 |
|
||||
| ghcr.io/inti-cmnb/kicad5_auto:1.5.1 | 1.5.1 | 5.1.9 | 11.6 | 2.1.1 | 1.8.0-3 | 2.5.0-2 | 1.1.15 | 0.1.2 | 0.9.0-5 | 2.4.3 |
|
||||
| ghcr.io/inti-cmnb/kicad5_auto:1.6.0 | 1.6.0 | 5.1.9 | 11.6 | 2.2.1 | 1.8.0-3 | 2.5.0-3 | 1.1.15 | 0.1.2 | -- | 2.4.5 |
|
||||
| ghcr.io/inti-cmnb/kicad5_auto:1.6.1 | 1.6.1 | 5.1.9 | 11.6 | 2.2.1 | 1.8.0-3 | 2.5.0-3 | 1.1.15 | 0.1.2 | -- | 2.4.5 |
|
||||
| ghcr.io/inti-cmnb/kicad5_auto:1.6.2 | 1.6.2 | 5.1.9 | 11.6 | 2.2.6 | 1.9.0 | 2.6.0 | 1.1.17 | 0.1.2 | -- | 2.4.7 |
|
||||
| ghcr.io/inti-cmnb/kicad5_auto:1.6.3 | 1.6.3 | 5.1.9 | 11.6 | 2.2.8 | 1.9.1 | 2.8.1 | 1.1.18 | 0.1.2 | -- | 2.5.3 |
|
||||
| ghcr.io/inti-cmnb/kicad5_auto:1.6.4 | 1.6.4 | 5.1.9 | 11.6 | 2.3.0 | 1.9.1 | 2.8.1 | 1.1.18 | 0.1.2 | -- | 2.5.3 |
|
||||
|
||||
## KiCad 6
|
||||
|
||||
| Name | KiBot | KiCad | Debian | KiAuto | KiBoM | iBoM | KiCost | DK plug | PcbDraw | KiDiff | KiKit |
|
||||
| :---------------------------------------- | ------ | ------ | ------ | ------ | ------- | -------- | ------ | ------- | ------- | ------ | ------: |
|
||||
| setsoft/kicad_auto:ki6.0.0_Ubuntu21.10 | 0.11.0 | 6.0.0 | U21.10 | 1.6.5 | 1.8.0 | 2.4.1 | 1.1.15 | 0.1.2 | 0.9.0-1 | -- | -- |
|
||||
| ghcr.io/inti-cmnb/kicad6_auto:1.2.0 | 1.2.0 | 6.0.5 | 11.3 | 1.6.15 | 1.8.0-2 | 2.5.0 | 1.1.10 | 0.1.1 | 0.9.0-3 | -- | -- |
|
||||
| ghcr.io/inti-cmnb/kicad6_auto:1.3.0 | 1.3.0 | 6.0.7 | 11.5 | 2.0.6 | 1.8.0-2 | 2.5.0 | 1.1.12 | 0.1.2 | 0.9.0-4 | 2.4.2 | -- |
|
||||
| ghcr.io/inti-cmnb/kicad6_auto:1.5.1 | 1.5.1 | 6.0.10 | 11.6 | 2.1.1 | 1.8.0-3 | 2.5.0-2 | 1.1.15 | 0.1.2 | 0.9.0-5 | 2.4.3 | 1.2.0 |
|
||||
| ghcr.io/inti-cmnb/kicad6_auto:1.6.0 | 1.6.0 | 6.0.11 | 11.6 | 2.2.1 | 1.8.0-3 | 2.5.0-3 | 1.1.15 | 0.1.2 | -- | 2.4.5 | 1.3.0-5 |
|
||||
| ghcr.io/inti-cmnb/kicad6_auto:1.6.1 | 1.6.1 | 6.0.11 | 11.6 | 2.2.1 | 1.8.0-3 | 2.5.0-3 | 1.1.15 | 0.1.2 | -- | 2.4.5 | 1.3.0-5 |
|
||||
| ghcr.io/inti-cmnb/kicad6_auto:1.6.2 | 1.6.2 | 6.0.11 | 11.6 | 2.2.6 | 1.9.0 | 2.6.0 | 1.1.17 | 0.1.2 | -- | 2.4.7 | 1.3.0-7 |
|
||||
| ghcr.io/inti-cmnb/kicad6_auto:1.6.3 | 1.6.3 | 6.0.11 | 12.1 | 2.2.8 | 1.9.1 | 2.8.1 | 1.1.18 | 0.1.2 | -- | 2.5.3 | 1.4.0 |
|
||||
| ghcr.io/inti-cmnb/kicad6_auto:1.6.4 | 1.6.4 | 6.0.11 | 12.1 | 2.3.0 | 1.9.1 | 2.8.1 | 1.1.18 | 0.1.2 | -- | 2.5.3 | 1.5.1 |
|
||||
|
||||
## KiCad 7
|
||||
|
||||
| Name | KiBot | KiCad | Debian | KiAuto | KiBoM | iBoM | KiCost | DK plug | KiDiff | KiKit |
|
||||
| :---------------------------------------- | ------ | ------- | ------ | ------ | ------- | -------- | ------ | ------- | ------ | ------: |
|
||||
| ghcr.io/inti-cmnb/kicad7_auto:1.6.1 | 1.6.1 | 7.0.1.1 | 11.6 | 2.2.1 | 1.8.0-3 | 2.5.0-3 | 1.1.15 | 0.1.2 | 2.4.5 | 1.3.0-5 |
|
||||
| ghcr.io/inti-cmnb/kicad7_auto:1.6.2 | 1.6.2 | 7.0.5.1 | 11.6 | 2.2.6 | 1.9.0 | 2.6.0 | 1.1.17 | 0.1.2 | 2.4.7 | 1.3.0-7 |
|
||||
| ghcr.io/inti-cmnb/kicad7_auto:1.6.3 | 1.6.3 | 7.0.10 | 12.1 | 2.2.8 | 1.9.1 | 2.8.1 | 1.1.18 | 0.1.2 | 2.5.3 | 1.4.0 |
|
||||
| ghcr.io/inti-cmnb/kicad7_auto:1.6.4 | 1.6.4 | 7.0.11 | 12.1 | 2.3.0 | 1.9.1 | 2.9.0 | 1.1.18 | 0.1.2 | 2.5.3 | 1.5.1 |
|
||||
|
||||
## KiCad 8
|
||||
|
||||
| Name | KiBot | KiCad | Debian | KiAuto | KiBoM | iBoM | KiCost | DK plug | KiDiff | KiKit |
|
||||
| :---------------------------------------- | ------ | ------- | ------ | ------ | ------- | -------- | ------ | ------- | ------ | ------: |
|
||||
| ghcr.io/inti-cmnb/kicad8_auto:1.6.4 | 1.6.4 | 8.0.1 | sid | 2.3.0 | 1.9.1 | 2.9.0 | 1.1.18 | 0.1.2 | 2.5.3 | 1.5.1 |
|
||||
|
||||
You can run it using a script like this:
|
||||
|
||||
|
|
@ -39,15 +91,5 @@ docker run --rm -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
|||
--volume="/home/$USER/.cache/kicad:/home/$USER/.cache/kicad:rw" \
|
||||
--volume="/etc/passwd:/etc/passwd:ro" \
|
||||
--volume="/etc/shadow:/etc/shadow:ro" \
|
||||
setsoft/kicad_auto:10.3-5.1.5 /bin/bash -c "cd workdir/$SUBDIR; kiplot"
|
||||
ghcr.io/inti-cmnb/kicad7_auto:1.6.4 /bin/bash -c "cd workdir/$SUBDIR; kibot"
|
||||
```
|
||||
|
||||
To create the docker image run the [build.sh](https://github.com/INTI-CMNB/kicad_auto/blob/master/build.sh) script.
|
||||
This script will download the latest KiPlot and needed tools.
|
||||
|
||||
The [run.sh](https://github.com/INTI-CMNB/kicad_auto/blob/master/run.sh) script is an example of how to run KiPlot using this image locally.
|
||||
You must edit the file to define the place where your KiCad project is located.
|
||||
The **WORKDIR** variable indicates the directory where your project and libraries are located.
|
||||
The **SUBDIR** variable is the subdir inside **WORKDIR** that contains the schematic and PCB files.
|
||||
|
||||
|
||||
|
|
|
|||
2
build.sh
2
build.sh
|
|
@ -1,2 +0,0 @@
|
|||
#!/bin/sh
|
||||
docker build -f Dockerfile -t setsoft/kicad_auto:10.4-5.1.6 .
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
#!/bin/sh
|
||||
set -e
|
||||
# KiCad 6, tag the generic ki6 as latest and also for Docker Hub
|
||||
docker pull ghcr.io/inti-cmnb/kicad_auto:ki6
|
||||
docker tag ghcr.io/inti-cmnb/kicad_auto:ki6 setsoft/kicad_auto:ki6
|
||||
docker tag ghcr.io/inti-cmnb/kicad_auto:ki6 ghcr.io/inti-cmnb/kicad6_auto:latest
|
||||
docker push setsoft/kicad_auto:ki6
|
||||
docker push ghcr.io/inti-cmnb/kicad6_auto:latest
|
||||
# KiCad 7
|
||||
docker pull ghcr.io/inti-cmnb/kicad_auto:ki7
|
||||
docker tag ghcr.io/inti-cmnb/kicad_auto:ki7 setsoft/kicad_auto:ki7
|
||||
docker tag ghcr.io/inti-cmnb/kicad_auto:ki7 ghcr.io/inti-cmnb/kicad7_auto:latest
|
||||
docker push setsoft/kicad_auto:ki7
|
||||
docker push ghcr.io/inti-cmnb/kicad7_auto:latest
|
||||
# KiCad 8
|
||||
docker pull ghcr.io/inti-cmnb/kicad_auto:ki8
|
||||
docker tag ghcr.io/inti-cmnb/kicad_auto:ki8 setsoft/kicad_auto:ki8
|
||||
docker tag ghcr.io/inti-cmnb/kicad_auto:ki8 ghcr.io/inti-cmnb/kicad8_auto:latest
|
||||
docker push setsoft/kicad_auto:ki8
|
||||
docker push ghcr.io/inti-cmnb/kicad8_auto:latest
|
||||
# KiCad 5
|
||||
docker pull ghcr.io/inti-cmnb/kicad_auto:ki5
|
||||
docker tag ghcr.io/inti-cmnb/kicad_auto:ki5 setsoft/kicad_auto:latest
|
||||
docker tag ghcr.io/inti-cmnb/kicad_auto:ki5 ghcr.io/inti-cmnb/kicad5_auto:latest
|
||||
docker push setsoft/kicad_auto:latest
|
||||
docker push ghcr.io/inti-cmnb/kicad5_auto:latest
|
||||
|
||||
|
|
@ -0,0 +1,70 @@
|
|||
#!/usr/bin/python3
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2023 Salvador E. Tropea
|
||||
# Copyright (c) 2023 Instituto Nacional de Tecnologïa Industrial
|
||||
# License: GPLv3
|
||||
# Simple Git Hub release downloader
|
||||
import argparse
|
||||
import json
|
||||
import os
|
||||
import requests
|
||||
import sys
|
||||
from time import sleep
|
||||
from urllib.parse import unquote
|
||||
|
||||
|
||||
USER_AGENT = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Firefox/102.0'
|
||||
|
||||
|
||||
def error(msg):
|
||||
print(msg)
|
||||
exit(3)
|
||||
|
||||
|
||||
def get_request(url):
|
||||
retry = 4
|
||||
while retry:
|
||||
r = requests.get(url, timeout=20, allow_redirects=True, headers={'User-Agent': USER_AGENT})
|
||||
if r.status_code == 200:
|
||||
return r
|
||||
if r.status_code == 403:
|
||||
# GitHub returns 403 randomly (saturated?)
|
||||
sleep(1 << (4-retry))
|
||||
retry -= 1
|
||||
else:
|
||||
retry = 0
|
||||
error(f'Failed to get release info, status {r.status_code}')
|
||||
|
||||
|
||||
def download(url, skip):
|
||||
fname = unquote(os.path.basename(url))
|
||||
for s in skip:
|
||||
if fname.startswith(s):
|
||||
print(f"Skipping `{fname}`")
|
||||
return
|
||||
if os.path.isfile(fname):
|
||||
print(f"`{fname}` already downloaded, won't overwrite")
|
||||
return
|
||||
print(f"Downloading `{fname}`")
|
||||
res = get_request(url)
|
||||
print(f"Saving `{fname}`")
|
||||
with open(fname, 'wb') as f:
|
||||
f.write(res.content)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
parser = argparse.ArgumentParser(description='Debian package downloader for GitHub releases')
|
||||
|
||||
parser.add_argument('project', help='The user/project to fetch')
|
||||
parser.add_argument('--skip', '-s', help='Skip files starting with', type=str, nargs='+', default=[])
|
||||
parser.add_argument('--release', '-r', help='Release to download', type=str, default='latest')
|
||||
args = parser.parse_args()
|
||||
|
||||
if args.release != 'latest':
|
||||
args.release = 'tags/'+args.release
|
||||
url = 'https://api.github.com/repos/'+args.project+'/releases/'+args.release
|
||||
print(f"Downloading `{args.release}` release of `{args.project}` ({url})")
|
||||
res = get_request(url)
|
||||
r = res.json()
|
||||
for a in r['assets']:
|
||||
download(a['browser_download_url'], args.skip)
|
||||
|
|
@ -0,0 +1 @@
|
|||
IT=6
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
FROM ghcr.io/inti-cmnb/kicad5_auto:latest_deps
|
||||
MAINTAINER Salvador E. Tropea <set@ieee.org>
|
||||
LABEL Description="KiCad 5 w/KiBot and other automation scripts"
|
||||
LABEL org.opencontainers.image.description "KiCad 5 w/KiBot and other automation scripts"
|
||||
|
||||
# Install all the tools, dependencies are already installed
|
||||
RUN apt-get update && \
|
||||
dl_deb.py INTI-CMNB/KiBoM && \
|
||||
dl_deb.py INTI-CMNB/kicad-git-filters && \
|
||||
dl_deb.py set-soft/kicost-digikey-api-v3 && \
|
||||
dl_deb.py hildogjr/KiCost && \
|
||||
dl_deb.py INTI-CMNB/InteractiveHtmlBom && \
|
||||
dl_deb.py INTI-CMNB/KiAuto && \
|
||||
dl_deb.py INTI-CMNB/kidiff && \
|
||||
dl_deb.py INTI-CMNB/KiBot && \
|
||||
apt -y install --no-install-recommends ./*.deb && \
|
||||
apt-get -y autoremove && \
|
||||
rm /*.deb && \
|
||||
rm -rf /var/lib/apt/lists/* /var/cache/debconf/templates.dat-old /var/lib/dpkg/status-old
|
||||
|
||||
ARG iteration
|
||||
ENV KIBOT_ITERATION=$iteration
|
||||
|
||||
RUN kibot --version | sed 's/.* \([0-9]\+\.[0-9]\+\.[0-9]\+\) .*/\1/' | tr -d '\n' > /etc/kiauto_tag && \
|
||||
echo -n -${KIBOT_ITERATION}_k >> /etc/kiauto_tag && \
|
||||
kicad_version.py >> /etc/kiauto_tag && \
|
||||
echo -n _d >> /etc/kiauto_tag && \
|
||||
cat /etc/debian_version | tr -d '\n' >> /etc/kiauto_tag
|
||||
|
|
@ -0,0 +1,20 @@
|
|||
#!/bin/sh
|
||||
set -e
|
||||
. ../iteration.sh
|
||||
docker build -f Dockerfile --build-arg iteration=${IT} -t ghcr.io/inti-cmnb/kicad5_auto:latest .
|
||||
TG1=`docker run --rm ghcr.io/inti-cmnb/kicad5_auto:latest kibot --version | sed 's/.* \([0-9]\+\.[0-9]\+\.[0-9]\+\) .*/\1/' | tr -d '\n'`
|
||||
TG2=k`docker run --rm ghcr.io/inti-cmnb/kicad5_auto:latest kicad_version.py`
|
||||
TG3=d`docker run --rm ghcr.io/inti-cmnb/kicad5_auto:latest cat /etc/debian_version | tr -d '\n'`
|
||||
docker tag ghcr.io/inti-cmnb/kicad5_auto:latest ghcr.io/inti-cmnb/kicad5_auto:${TG1}-${IT}_${TG2}_${TG3}
|
||||
docker tag ghcr.io/inti-cmnb/kicad5_auto:latest ghcr.io/inti-cmnb/kicad5_auto:${TG1}
|
||||
docker tag ghcr.io/inti-cmnb/kicad5_auto:latest ghcr.io/inti-cmnb/kicad_auto:ki5
|
||||
docker tag ghcr.io/inti-cmnb/kicad5_auto:latest ghcr.io/inti-cmnb/kicad_auto:latest
|
||||
docker push ghcr.io/inti-cmnb/kicad5_auto:${TG1}-${IT}_${TG2}_${TG3}
|
||||
docker push ghcr.io/inti-cmnb/kicad5_auto:${TG1}
|
||||
docker push ghcr.io/inti-cmnb/kicad_auto:ki5
|
||||
docker push ghcr.io/inti-cmnb/kicad_auto:latest
|
||||
# Leave the following for the deploy:
|
||||
#docker tag ghcr.io/inti-cmnb/kicad5_auto:latest setsoft/kicad_auto:latest
|
||||
#docker push ghcr.io/inti-cmnb/kicad5_auto:latest
|
||||
#docker push setsoft/kicad_auto:latest
|
||||
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
docker run --rm -it ghcr.io/inti-cmnb/kicad_auto:ki5 /bin/bash
|
||||
|
|
@ -10,4 +10,4 @@ docker run --rm -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
|||
--volume="/etc/passwd:/etc/passwd:ro" \
|
||||
--volume="/etc/shadow:/etc/shadow:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
setsoft/kicad_auto:dev /bin/bash
|
||||
ghcr.io/inti-cmnb/kicad_auto:ki5 /bin/bash
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
FROM ghcr.io/inti-cmnb/kicad5_debian:latest
|
||||
MAINTAINER Salvador E. Tropea <set@ieee.org>
|
||||
LABEL Description="Layer used for new dependencies"
|
||||
LABEL org.opencontainers.image.description "Layer used for new dependencies"
|
||||
|
||||
RUN apt-get update && \
|
||||
echo "Use wget to download some stuff" && \
|
||||
apt -y install --no-install-recommends wget && \
|
||||
echo "XLSX Writer 3 fixes some important limitations in URLs (used by KiBoM, KiCost, KiBot, etc.)" && \
|
||||
wget http://http.us.debian.org/debian/pool/main/x/xlsxwriter/python3-xlsxwriter_3.0.2-2_all.deb && \
|
||||
apt -y install --no-install-recommends ./*.deb && \
|
||||
apt-get -y remove wget && \
|
||||
apt-get -y autoremove && \
|
||||
rm /*.deb && \
|
||||
rm -rf /var/lib/apt/lists/* /var/cache/debconf/templates.dat-old /var/lib/dpkg/status-old
|
||||
|
||||
# Fix for the .deb downloader, should be removed in the next OS iteration
|
||||
COPY dl_deb.py /usr/bin/
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
#!/bin/sh
|
||||
set -e
|
||||
cp ../dl_deb.py .
|
||||
docker build -f Dockerfile -t ghcr.io/inti-cmnb/kicad5_auto:latest_deps .
|
||||
TG1=`docker run --rm ghcr.io/inti-cmnb/kicad5_auto:latest_deps kicad_version.py`
|
||||
TG2=d`docker run --rm ghcr.io/inti-cmnb/kicad5_auto:latest_deps cat /etc/debian_version | tr -d '\n'`
|
||||
docker tag ghcr.io/inti-cmnb/kicad5_auto:latest_deps ghcr.io/inti-cmnb/kicad5_auto:${TG1}_${TG2}_deps
|
||||
docker push ghcr.io/inti-cmnb/kicad5_auto:${TG1}_${TG2}_deps
|
||||
docker push ghcr.io/inti-cmnb/kicad5_auto:latest_deps
|
||||
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
docker run --rm -it ghcr.io/inti-cmnb/kicad5_auto:latest_deps /bin/bash
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
#!/bin/sh
|
||||
export USER_ID=$(id -u)
|
||||
export GROUP_ID=$(id -g)
|
||||
docker run --rm -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
||||
--user $USER_ID:$GROUP_ID \
|
||||
--env NO_AT_BRIDGE=1 \
|
||||
--workdir="/home/$USER" \
|
||||
--volume="/etc/group:/etc/group:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
--volume="/etc/passwd:/etc/passwd:ro" \
|
||||
--volume="/etc/shadow:/etc/shadow:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
ghcr.io/inti-cmnb/kicad5_auto:latest_deps /bin/bash
|
||||
|
|
@ -1,20 +1,30 @@
|
|||
FROM setsoft/kicad_debian:ki6
|
||||
FROM ghcr.io/inti-cmnb/kicad6_auto:latest_deps
|
||||
MAINTAINER Salvador E. Tropea <set@ieee.org>
|
||||
LABEL Description="KiCad with KiBot and other automation scripts"
|
||||
LABEL Description="KiCad 6 w/KiBot and other automation scripts"
|
||||
LABEL org.opencontainers.image.description "KiCad 6 w/KiBot and other automation scripts"
|
||||
|
||||
RUN sed -i -e's/ main/ main contrib non-free/g' /etc/apt/sources.list && \
|
||||
apt-get update && \
|
||||
apt-get -y install -t bullseye-backports curl && \
|
||||
apt-get -y install make wget curl rar bzip2 librsvg2-bin && \
|
||||
apt-get -y install --no-install-recommends imagemagick python3-qrcodegen git poppler-utils && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/KiAuto/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/KiBoM/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/InteractiveHtmlBom/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/PcbDraw/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/KiCost/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/KiBot/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
# Install all the tools, dependencies are already installed
|
||||
RUN apt-get update && \
|
||||
dl_deb.py INTI-CMNB/KiBoM && \
|
||||
dl_deb.py INTI-CMNB/kicad-git-filters && \
|
||||
dl_deb.py set-soft/kicost-digikey-api-v3 && \
|
||||
dl_deb.py hildogjr/KiCost && \
|
||||
dl_deb.py INTI-CMNB/InteractiveHtmlBom && \
|
||||
dl_deb.py set-soft/pcbnewTransition && \
|
||||
dl_deb.py INTI-CMNB/KiKit --skip kikit-doc && \
|
||||
dl_deb.py INTI-CMNB/KiAuto && \
|
||||
dl_deb.py INTI-CMNB/kidiff && \
|
||||
dl_deb.py INTI-CMNB/KiBot && \
|
||||
apt -y install --no-install-recommends ./*.deb && \
|
||||
apt-get -y remove curl wget && \
|
||||
apt-get -y autoremove && \
|
||||
rm /*.deb && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
rm -rf /var/lib/apt/lists/* /var/cache/debconf/templates.dat-old /var/lib/dpkg/status-old
|
||||
|
||||
ARG iteration
|
||||
ENV KIBOT_ITERATION=$iteration
|
||||
|
||||
RUN kibot --version | sed 's/.* \([0-9]\+\.[0-9]\+\.[0-9]\+\) .*/\1/' | tr -d '\n' > /etc/kiauto_tag && \
|
||||
echo -n -${KIBOT_ITERATION}_k >> /etc/kiauto_tag && \
|
||||
kicad_version.py >> /etc/kiauto_tag && \
|
||||
echo -n _d >> /etc/kiauto_tag && \
|
||||
cat /etc/debian_version | tr -d '\n' >> /etc/kiauto_tag
|
||||
|
|
|
|||
18
ki6/build.sh
18
ki6/build.sh
|
|
@ -1,2 +1,18 @@
|
|||
#!/bin/sh
|
||||
docker build -f Dockerfile -t setsoft/kicad_auto:ki6 .
|
||||
set -e
|
||||
. ../iteration.sh
|
||||
docker build -f Dockerfile --build-arg iteration=${IT} -t ghcr.io/inti-cmnb/kicad6_auto:latest .
|
||||
TG1=`docker run --rm ghcr.io/inti-cmnb/kicad6_auto:latest kibot --version | sed 's/.* \([0-9]\+\.[0-9]\+\.[0-9]\+\) .*/\1/' | tr -d '\n'`
|
||||
TG2=k`docker run --rm ghcr.io/inti-cmnb/kicad6_auto:latest kicad_version.py`
|
||||
TG3=d`docker run --rm ghcr.io/inti-cmnb/kicad6_auto:latest cat /etc/debian_version | tr -d '\n'`
|
||||
docker tag ghcr.io/inti-cmnb/kicad6_auto:latest ghcr.io/inti-cmnb/kicad6_auto:${TG1}-${IT}_${TG2}_${TG3}
|
||||
docker tag ghcr.io/inti-cmnb/kicad6_auto:latest ghcr.io/inti-cmnb/kicad6_auto:${TG1}
|
||||
docker tag ghcr.io/inti-cmnb/kicad6_auto:latest ghcr.io/inti-cmnb/kicad_auto:ki6
|
||||
docker push ghcr.io/inti-cmnb/kicad6_auto:${TG1}-${IT}_${TG2}_${TG3}
|
||||
docker push ghcr.io/inti-cmnb/kicad6_auto:${TG1}
|
||||
docker push ghcr.io/inti-cmnb/kicad_auto:ki6
|
||||
# Leave the following for the deploy:
|
||||
#docker tag ghcr.io/inti-cmnb/kicad6_auto:latest setsoft/kicad_auto:ki6
|
||||
#docker push ghcr.io/inti-cmnb/kicad6_auto:latest
|
||||
#docker push setsoft/kicad_auto:ki6
|
||||
|
||||
|
|
|
|||
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
docker run --rm -it ghcr.io/inti-cmnb/kicad_auto:ki6 /bin/bash
|
||||
|
|
@ -10,4 +10,4 @@ docker run --rm -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
|||
--volume="/etc/passwd:/etc/passwd:ro" \
|
||||
--volume="/etc/shadow:/etc/shadow:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
setsoft/kicad_auto:ki6 /bin/bash
|
||||
ghcr.io/inti-cmnb/kicad_auto:ki6 /bin/bash
|
||||
|
|
|
|||
|
|
@ -0,0 +1,18 @@
|
|||
FROM ghcr.io/inti-cmnb/kicad6_debian:latest
|
||||
MAINTAINER Salvador E. Tropea <set@ieee.org>
|
||||
LABEL Description="Layer used for new dependencies"
|
||||
LABEL org.opencontainers.image.description "Layer used for new dependencies"
|
||||
|
||||
RUN apt-get update && \
|
||||
echo "Use wget to download some stuff" && \
|
||||
apt -y install --no-install-recommends wget && \
|
||||
echo "XLSX Writer 3 fixes some important limitations in URLs (used by KiBoM, KiCost, KiBot, etc.)" && \
|
||||
wget http://http.us.debian.org/debian/pool/main/x/xlsxwriter/python3-xlsxwriter_3.0.2-2_all.deb && \
|
||||
apt -y install --no-install-recommends ./*.deb && \
|
||||
apt-get -y remove wget && \
|
||||
apt-get -y autoremove && \
|
||||
rm /*.deb && \
|
||||
rm -rf /var/lib/apt/lists/* /var/cache/debconf/templates.dat-old /var/lib/dpkg/status-old
|
||||
|
||||
# Fix for the .deb downloader, should be removed in the next OS iteration
|
||||
COPY dl_deb.py /usr/bin/
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
#!/bin/sh
|
||||
set -e
|
||||
cp ../dl_deb.py .
|
||||
docker build -f Dockerfile -t ghcr.io/inti-cmnb/kicad6_auto:latest_deps .
|
||||
TG1=`docker run --rm ghcr.io/inti-cmnb/kicad6_auto:latest_deps kicad_version.py`
|
||||
TG2=d`docker run --rm ghcr.io/inti-cmnb/kicad6_auto:latest_deps cat /etc/debian_version | tr -d '\n'`
|
||||
docker tag ghcr.io/inti-cmnb/kicad6_auto:latest_deps ghcr.io/inti-cmnb/kicad6_auto:${TG1}_${TG2}_deps
|
||||
docker push ghcr.io/inti-cmnb/kicad6_auto:${TG1}_${TG2}_deps
|
||||
docker push ghcr.io/inti-cmnb/kicad6_auto:latest_deps
|
||||
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
docker run --rm -it ghcr.io/inti-cmnb/kicad6_auto:latest_deps /bin/bash
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
#!/bin/sh
|
||||
export USER_ID=$(id -u)
|
||||
export GROUP_ID=$(id -g)
|
||||
docker run --rm -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
||||
--user $USER_ID:$GROUP_ID \
|
||||
--env NO_AT_BRIDGE=1 \
|
||||
--workdir="/home/$USER" \
|
||||
--volume="/etc/group:/etc/group:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
--volume="/etc/passwd:/etc/passwd:ro" \
|
||||
--volume="/etc/shadow:/etc/shadow:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
ghcr.io/inti-cmnb/kicad6_auto:latest_deps /bin/bash
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
FROM ghcr.io/inti-cmnb/kicad7_auto:latest_deps
|
||||
MAINTAINER Salvador E. Tropea <set@ieee.org>
|
||||
LABEL Description="KiCad 7 w/KiBot and other automation scripts"
|
||||
LABEL org.opencontainers.image.description "KiCad 7 w/KiBot and other automation scripts"
|
||||
|
||||
# Install all the tools, dependencies are already installed
|
||||
RUN apt-get update && \
|
||||
dl_deb.py INTI-CMNB/KiBoM && \
|
||||
dl_deb.py INTI-CMNB/kicad-git-filters && \
|
||||
dl_deb.py set-soft/kicost-digikey-api-v3 && \
|
||||
dl_deb.py hildogjr/KiCost && \
|
||||
dl_deb.py INTI-CMNB/InteractiveHtmlBom && \
|
||||
dl_deb.py set-soft/pcbnewTransition && \
|
||||
dl_deb.py INTI-CMNB/KiKit --skip kikit-doc && \
|
||||
dl_deb.py INTI-CMNB/KiAuto && \
|
||||
dl_deb.py INTI-CMNB/kidiff && \
|
||||
dl_deb.py INTI-CMNB/KiBot && \
|
||||
apt -y install --no-install-recommends ./*.deb && \
|
||||
apt-get -y autoremove && \
|
||||
rm /*.deb && \
|
||||
rm -rf /var/lib/apt/lists/* /var/cache/debconf/templates.dat-old /var/lib/dpkg/status-old
|
||||
|
||||
ARG iteration
|
||||
ENV KIBOT_ITERATION=$iteration
|
||||
|
||||
RUN kibot --version | sed 's/.* \([0-9]\+\.[0-9]\+\.[0-9]\+\) .*/\1/' | tr -d '\n' > /etc/kiauto_tag && \
|
||||
echo -n -${KIBOT_ITERATION}_k >> /etc/kiauto_tag && \
|
||||
kicad_version.py >> /etc/kiauto_tag && \
|
||||
echo -n _d >> /etc/kiauto_tag && \
|
||||
cat /etc/debian_version | tr -d '\n' >> /etc/kiauto_tag
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
#!/bin/sh
|
||||
set -e
|
||||
. ../iteration.sh
|
||||
docker build -f Dockerfile --build-arg iteration=${IT} -t ghcr.io/inti-cmnb/kicad7_auto:latest .
|
||||
TG1=`docker run --rm ghcr.io/inti-cmnb/kicad7_auto:latest kibot --version | sed 's/.* \([0-9]\+\.[0-9]\+\.[0-9]\+\) .*/\1/' | tr -d '\n'`
|
||||
TG2=k`docker run --rm ghcr.io/inti-cmnb/kicad7_auto:latest kicad_version.py`
|
||||
TG3=d`docker run --rm ghcr.io/inti-cmnb/kicad7_auto:latest cat /etc/debian_version | tr -d '\n'`
|
||||
docker tag ghcr.io/inti-cmnb/kicad7_auto:latest ghcr.io/inti-cmnb/kicad7_auto:${TG1}-${IT}_${TG2}_${TG3}
|
||||
docker tag ghcr.io/inti-cmnb/kicad7_auto:latest ghcr.io/inti-cmnb/kicad7_auto:${TG1}
|
||||
docker tag ghcr.io/inti-cmnb/kicad7_auto:latest ghcr.io/inti-cmnb/kicad_auto:ki7
|
||||
docker push ghcr.io/inti-cmnb/kicad7_auto:${TG1}-${IT}_${TG2}_${TG3}
|
||||
docker push ghcr.io/inti-cmnb/kicad7_auto:${TG1}
|
||||
docker push ghcr.io/inti-cmnb/kicad_auto:ki7
|
||||
# Leave the following for the deploy:
|
||||
#docker tag ghcr.io/inti-cmnb/kicad7_auto:latest setsoft/kicad_auto:ki7
|
||||
#docker push ghcr.io/inti-cmnb/kicad7_auto:latest
|
||||
#docker push setsoft/kicad_auto:ki7
|
||||
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
docker run --rm -it ghcr.io/inti-cmnb/kicad_auto:ki7 /bin/bash
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
#!/bin/sh
|
||||
export USER_ID=$(id -u)
|
||||
export GROUP_ID=$(id -g)
|
||||
docker run -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
||||
docker run --rm -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
||||
--user $USER_ID:$GROUP_ID \
|
||||
--env NO_AT_BRIDGE=1 \
|
||||
--workdir="/home/$USER" \
|
||||
|
|
@ -10,4 +10,4 @@ docker run -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
|||
--volume="/etc/passwd:/etc/passwd:ro" \
|
||||
--volume="/etc/shadow:/etc/shadow:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
setsoft/kicad_auto:latest kicad
|
||||
ghcr.io/inti-cmnb/kicad_auto:ki7 /bin/bash
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
FROM ghcr.io/inti-cmnb/kicad7_debian:latest
|
||||
MAINTAINER Salvador E. Tropea <set@ieee.org>
|
||||
LABEL Description="Layer used for new dependencies"
|
||||
LABEL org.opencontainers.image.description "Layer used for new dependencies"
|
||||
|
||||
RUN apt-get update && \
|
||||
echo "Use wget to download some stuff" && \
|
||||
apt -y install --no-install-recommends wget && \
|
||||
echo "XLSX Writer 3 fixes some important limitations in URLs (used by KiBoM, KiCost, KiBot, etc.)" && \
|
||||
wget http://http.us.debian.org/debian/pool/main/x/xlsxwriter/python3-xlsxwriter_3.0.2-2_all.deb && \
|
||||
apt -y install --no-install-recommends ./*.deb && \
|
||||
apt-get -y remove wget && \
|
||||
apt-get -y autoremove && \
|
||||
rm /*.deb && \
|
||||
rm -rf /var/lib/apt/lists/* /var/cache/debconf/templates.dat-old /var/lib/dpkg/status-old
|
||||
|
||||
# Fix for the .deb downloader, should be removed in the next OS iteration
|
||||
COPY dl_deb.py /usr/bin/
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
#!/bin/sh
|
||||
set -e
|
||||
cp ../dl_deb.py .
|
||||
docker build -f Dockerfile -t ghcr.io/inti-cmnb/kicad7_auto:latest_deps .
|
||||
TG1=`docker run --rm ghcr.io/inti-cmnb/kicad7_auto:latest_deps kicad_version.py`
|
||||
TG2=d`docker run --rm ghcr.io/inti-cmnb/kicad7_auto:latest_deps cat /etc/debian_version | tr -d '\n'`
|
||||
docker tag ghcr.io/inti-cmnb/kicad7_auto:latest_deps ghcr.io/inti-cmnb/kicad7_auto:${TG1}_${TG2}_deps
|
||||
docker push ghcr.io/inti-cmnb/kicad7_auto:${TG1}_${TG2}_deps
|
||||
docker push ghcr.io/inti-cmnb/kicad7_auto:latest_deps
|
||||
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
docker run --rm -it ghcr.io/inti-cmnb/kicad7_auto:latest_deps /bin/bash
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
#!/bin/sh
|
||||
export USER_ID=$(id -u)
|
||||
export GROUP_ID=$(id -g)
|
||||
docker run --rm -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
||||
--user $USER_ID:$GROUP_ID \
|
||||
--env NO_AT_BRIDGE=1 \
|
||||
--workdir="/home/$USER" \
|
||||
--volume="/etc/group:/etc/group:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
--volume="/etc/passwd:/etc/passwd:ro" \
|
||||
--volume="/etc/shadow:/etc/shadow:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
ghcr.io/inti-cmnb/kicad7_auto:latest_deps /bin/bash
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
FROM ghcr.io/inti-cmnb/kicad8_auto:latest_deps
|
||||
MAINTAINER Salvador E. Tropea <set@ieee.org>
|
||||
LABEL Description="KiCad 8 w/KiBot and other automation scripts"
|
||||
LABEL org.opencontainers.image.description "KiCad 8 w/KiBot and other automation scripts"
|
||||
|
||||
# Install all the tools, dependencies are already installed
|
||||
RUN apt-get update && \
|
||||
dl_deb.py INTI-CMNB/KiBoM && \
|
||||
dl_deb.py INTI-CMNB/kicad-git-filters && \
|
||||
dl_deb.py set-soft/kicost-digikey-api-v3 && \
|
||||
dl_deb.py hildogjr/KiCost && \
|
||||
dl_deb.py INTI-CMNB/InteractiveHtmlBom && \
|
||||
dl_deb.py set-soft/pcbnewTransition && \
|
||||
dl_deb.py INTI-CMNB/KiKit --skip kikit-doc && \
|
||||
dl_deb.py INTI-CMNB/KiAuto && \
|
||||
dl_deb.py INTI-CMNB/kidiff && \
|
||||
dl_deb.py INTI-CMNB/KiBot && \
|
||||
apt -y install --no-install-recommends ./*.deb && \
|
||||
apt-get -y autoremove && \
|
||||
rm /*.deb && \
|
||||
rm -rf /var/lib/apt/lists/* /var/cache/debconf/templates.dat-old /var/lib/dpkg/status-old
|
||||
|
||||
ARG iteration
|
||||
ENV KIBOT_ITERATION=$iteration
|
||||
|
||||
RUN kibot --version | sed 's/.* \([0-9]\+\.[0-9]\+\.[0-9]\+\) .*/\1/' | tr -d '\n' > /etc/kiauto_tag && \
|
||||
echo -n -${KIBOT_ITERATION}_k >> /etc/kiauto_tag && \
|
||||
kicad_version.py >> /etc/kiauto_tag && \
|
||||
echo -n _d >> /etc/kiauto_tag && \
|
||||
cat /etc/debian_version | tr -d '\n' >> /etc/kiauto_tag
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
#!/bin/sh
|
||||
set -e
|
||||
. ../iteration.sh
|
||||
docker build -f Dockerfile --build-arg iteration=${IT} -t ghcr.io/inti-cmnb/kicad8_auto:latest .
|
||||
TG1=`docker run --rm ghcr.io/inti-cmnb/kicad8_auto:latest kibot --version | sed 's/.* \([0-9]\+\.[0-9]\+\.[0-9]\+\) .*/\1/' | tr -d '\n'`
|
||||
TG2=k`docker run --rm ghcr.io/inti-cmnb/kicad8_auto:latest kicad_version.py`
|
||||
TG3=d_sid
|
||||
docker tag ghcr.io/inti-cmnb/kicad8_auto:latest ghcr.io/inti-cmnb/kicad8_auto:${TG1}-${IT}_${TG2}_${TG3}
|
||||
docker tag ghcr.io/inti-cmnb/kicad8_auto:latest ghcr.io/inti-cmnb/kicad8_auto:${TG1}
|
||||
docker tag ghcr.io/inti-cmnb/kicad8_auto:latest ghcr.io/inti-cmnb/kicad_auto:ki8
|
||||
docker push ghcr.io/inti-cmnb/kicad8_auto:${TG1}-${IT}_${TG2}_${TG3}
|
||||
docker push ghcr.io/inti-cmnb/kicad8_auto:${TG1}
|
||||
docker push ghcr.io/inti-cmnb/kicad_auto:ki8
|
||||
# Leave the following for the deploy:
|
||||
#docker tag ghcr.io/inti-cmnb/kicad8_auto:latest setsoft/kicad_auto:ki8
|
||||
#docker push ghcr.io/inti-cmnb/kicad8_auto:latest
|
||||
#docker push setsoft/kicad_auto:ki8
|
||||
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
docker run --rm -it ghcr.io/inti-cmnb/kicad_auto:ki8 /bin/bash
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
#!/bin/sh
|
||||
export USER_ID=$(id -u)
|
||||
export GROUP_ID=$(id -g)
|
||||
docker run -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
||||
docker run --rm -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
||||
--user $USER_ID:$GROUP_ID \
|
||||
--env NO_AT_BRIDGE=1 \
|
||||
--workdir="/home/$USER" \
|
||||
|
|
@ -10,4 +10,4 @@ docker run -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
|||
--volume="/etc/passwd:/etc/passwd:ro" \
|
||||
--volume="/etc/shadow:/etc/shadow:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
setsoft/kicad_auto:ki6 kicad
|
||||
ghcr.io/inti-cmnb/kicad_auto:ki8 /bin/bash
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
FROM ghcr.io/inti-cmnb/kicad8_debian:latest
|
||||
MAINTAINER Salvador E. Tropea <set@ieee.org>
|
||||
LABEL Description="Layer used for new dependencies"
|
||||
LABEL org.opencontainers.image.description "Layer used for new dependencies"
|
||||
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
#!/bin/sh
|
||||
set -e
|
||||
cp ../dl_deb.py .
|
||||
docker build -f Dockerfile -t ghcr.io/inti-cmnb/kicad8_auto:latest_deps .
|
||||
TG1=`docker run --rm ghcr.io/inti-cmnb/kicad8_auto:latest_deps kicad_version.py`
|
||||
TG2=d_sid
|
||||
docker tag ghcr.io/inti-cmnb/kicad8_auto:latest_deps ghcr.io/inti-cmnb/kicad8_auto:${TG1}_${TG2}_deps
|
||||
docker push ghcr.io/inti-cmnb/kicad8_auto:${TG1}_${TG2}_deps
|
||||
docker push ghcr.io/inti-cmnb/kicad8_auto:latest_deps
|
||||
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
docker run --rm -it ghcr.io/inti-cmnb/kicad8_auto:latest_deps /bin/bash
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
#!/bin/sh
|
||||
export USER_ID=$(id -u)
|
||||
export GROUP_ID=$(id -g)
|
||||
docker run --rm -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
||||
--user $USER_ID:$GROUP_ID \
|
||||
--env NO_AT_BRIDGE=1 \
|
||||
--workdir="/home/$USER" \
|
||||
--volume="/etc/group:/etc/group:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
--volume="/etc/passwd:/etc/passwd:ro" \
|
||||
--volume="/etc/shadow:/etc/shadow:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
ghcr.io/inti-cmnb/kicad8_auto:latest_deps /bin/bash
|
||||
|
|
@ -0,0 +1,36 @@
|
|||
FROM manjarolinux/base
|
||||
MAINTAINER Salvador E. Tropea <set@ieee.org>
|
||||
LABEL Description="KiCad with KiBot and other automation scripts"
|
||||
|
||||
RUN pacman -Syyu --noconfirm && \
|
||||
pacman -S yay binutils python-pip --noconfirm && \
|
||||
su builder -c "yay -S --noconfirm rar" && \
|
||||
pacman -S kicad kicad-library ghostscript gsfonts imagemagick librsvg pandoc texlive-core --noconfirm && \
|
||||
pacman -S recordmydesktop xdotool xclip libxslt python-psutil python-xvfbwrapper --noconfirm && \
|
||||
pip install KiAuto && \
|
||||
pacman -S python-xlsxwriter --noconfirm && \
|
||||
git clone https://github.com/INTI-CMNB/KiBoM.git && \
|
||||
cd KiBoM/ && \
|
||||
pip install . && \
|
||||
cd .. && \
|
||||
rm -r KiBoM/ && \
|
||||
git clone https://github.com/INTI-CMNB/InteractiveHtmlBom.git && \
|
||||
cd InteractiveHtmlBom/ && \
|
||||
pip install . && \
|
||||
cd .. && \
|
||||
rm -r InteractiveHtmlBom/ && \
|
||||
pip install KiDiff && \
|
||||
pacman -S python-numpy python-lxml python-mistune1 python-pybars3 python-wand python-yaml python-pcbnewtransition python-scipy --noconfirm && \
|
||||
su builder -c "yay -S python-svgpathtools-git --noconfirm" && \
|
||||
git clone https://github.com/INTI-CMNB/PcbDraw.git && \
|
||||
cd PcbDraw/ && \
|
||||
git submodule update --init --recursive && \
|
||||
git checkout v0.9.0_maintain && \
|
||||
pip install . && \
|
||||
cd .. && \
|
||||
rm -r PcbDraw/ && \
|
||||
pacman -S python-inflection python-pyopenssl python-tldextract python-dateutil --noconfirm && \
|
||||
pip install kicost_digikey_api_v3 dependencies && \
|
||||
pacman -S python-beautifulsoup4 python-tqdm python-validators python-colorama python-pillow --noconfirm && \
|
||||
pip install kicost && \
|
||||
pip install kibot
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
docker build -f Dockerfile -t setsoft/kicad_auto:manjaro_k6 .
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
docker run --rm -it setsoft/kicad_auto:manjaro_k6 /bin/bash
|
||||
|
|
@ -10,4 +10,4 @@ docker run --rm -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
|||
--volume="/etc/passwd:/etc/passwd:ro" \
|
||||
--volume="/etc/shadow:/etc/shadow:ro" \
|
||||
--volume="/home/$USER:/home/$USER:rw" \
|
||||
setsoft/kicad_auto:latest /bin/bash
|
||||
setsoft/kicad_auto:manjaro_k6 /bin/bash
|
||||
|
|
@ -1,19 +1,33 @@
|
|||
FROM setsoft/kicad_debian:nightly
|
||||
FROM ghcr.io/inti-cmnb/kicad_debian:nightly
|
||||
MAINTAINER Salvador E. Tropea <set@ieee.org>
|
||||
LABEL Description="KiCad with KiBot and other automation scripts"
|
||||
|
||||
RUN sed -i -e's/ main/ main contrib non-free/g' /etc/apt/sources.list && \
|
||||
apt-get update && \
|
||||
apt-get -y install make wget curl rar bzip2 librsvg2-bin && \
|
||||
apt-get -y install --no-install-recommends imagemagick python3-qrcodegen git poppler-utils && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/KiAuto/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/KiBoM/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/InteractiveHtmlBom/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/PcbDraw/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/KiCost/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
curl -s https://api.github.com/repos/INTI-CMNB/KiBot/releases/latest | grep "browser_download_url.*deb" | cut -d : -f 2,3 | tr -d \" | wget -i - && \
|
||||
apt-get -y install -t bullseye-backports curl && \
|
||||
apt-get -y install --no-install-recommends -t bullseye-backports git && \
|
||||
apt-get -y install make wget curl rar bzip2 librsvg2-bin ghostscript && \
|
||||
apt-get -y install --no-install-recommends imagemagick python3-qrcodegen poppler-utils && \
|
||||
dl_deb.py INTI-CMNB/KiAuto && \
|
||||
dl_deb.py INTI-CMNB/KiBoM && \
|
||||
dl_deb.py INTI-CMNB/InteractiveHtmlBom && \
|
||||
dl_deb.py INTI-CMNB/PcbDraw && \
|
||||
dl_deb.py hildogjr/KiCost && \
|
||||
dl_deb.py INTI-CMNB/KiBot && \
|
||||
dl_deb.py set-soft/kicost-digikey-api-v3 && \
|
||||
dl_deb.py INTI-CMNB/kicad-git-filters && \
|
||||
dl_deb.py INTI-CMNB/kidiff && \
|
||||
dl_deb.py set-soft/pcbnewTransition && \
|
||||
dl_deb.py INTI-CMNB/KiKit --skip kikit-doc && \
|
||||
apt -y install --no-install-recommends ./*.deb && \
|
||||
sed -i 's/<policy domain="coder" rights="none" pattern="PDF" \/>/<!-- <policy domain="coder" rights="none" pattern="PDF" \/> -->/g' /etc/ImageMagick-6/policy.xml && \
|
||||
sed -i 's/<policy domain="coder" rights="none" pattern="PS" \/>/<!-- <policy domain="coder" rights="none" pattern="PS" \/> -->/g' /etc/ImageMagick-6/policy.xml && \
|
||||
apt-get -y remove curl wget && \
|
||||
apt-get -y autoremove && \
|
||||
rm /*.deb && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
# Needed for GitHub seen on git 2.39.1
|
||||
RUN echo "[safe]" >> /etc/gitconfig && \
|
||||
echo " directory = *" >> /etc/gitconfig && \
|
||||
echo '[protocol "file"]' >> /etc/gitconfig && \
|
||||
echo ' allow = always' >> /etc/gitconfig
|
||||
|
|
|
|||
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
docker build -f Dockerfile -t setsoft/kicad_auto:nightly .
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
docker pull ghcr.io/inti-cmnb/kicad_auto:ki5
|
||||
docker pull ghcr.io/inti-cmnb/kicad_auto:ki6
|
||||
docker pull ghcr.io/inti-cmnb/kicad_auto:ki7
|
||||
15
run.sh
15
run.sh
|
|
@ -1,15 +0,0 @@
|
|||
export USER_ID=$(id -u)
|
||||
export GROUP_ID=$(id -g)
|
||||
WORKDIR=../hard
|
||||
SUBDIR=Conjunto
|
||||
docker run --rm -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
|
||||
-v $(pwd)/$WORKDIR:/home/$USER/workdir \
|
||||
--user $USER_ID:$GROUP_ID \
|
||||
--env NO_AT_BRIDGE=1 \
|
||||
--workdir="/home/$USER" \
|
||||
--volume="/etc/group:/etc/group:ro" \
|
||||
--volume="/home/$USER/.config/kicad:/home/$USER/.config/kicad:rw" \
|
||||
--volume="/home/$USER/.cache/kicad:/home/$USER/.cache/kicad:rw" \
|
||||
--volume="/etc/passwd:/etc/passwd:ro" \
|
||||
--volume="/etc/shadow:/etc/shadow:ro" \
|
||||
setsoft/kicad_auto:latest /bin/bash -c "cd workdir/$SUBDIR; kiplot"
|
||||
|
|
@ -0,0 +1,56 @@
|
|||
#!/usr/bin/python3
|
||||
from datetime import datetime, timezone
|
||||
import requests
|
||||
import sys
|
||||
|
||||
|
||||
ORG = 'INTI-CMNB'
|
||||
PKGS = {'kicad_auto', 'kicad5_auto', 'kicad6_auto', 'kicad7_auto'}
|
||||
PKG = 'kicad5_auto'
|
||||
HEADER = {'Accept': 'application/vnd.github+json',
|
||||
'Authorization': 'Bearer '+sys.argv[1],
|
||||
'X-GitHub-Api-Version': '2022-11-28'}
|
||||
|
||||
|
||||
def erase(name):
|
||||
url = f'https://api.github.com/orgs/{ORG}/packages/container/{PKG}/versions/{name}'
|
||||
r = requests.delete(url, timeout=20, allow_redirects=True, headers=HEADER)
|
||||
if r.status_code != 204:
|
||||
print(f'Error: {r.status_code} ****')
|
||||
|
||||
|
||||
deleted = 0
|
||||
for PKG in PKGS:
|
||||
url = f'https://api.github.com/orgs/{ORG}/packages/container/{PKG}/versions'
|
||||
page = 1
|
||||
received = 100
|
||||
vers = []
|
||||
while received == 100:
|
||||
r = requests.get(url, timeout=20, allow_redirects=True, headers=HEADER, params={'per_page': 100, 'page': page})
|
||||
assert r.status_code == 200
|
||||
page = page+1
|
||||
res = r.json()
|
||||
vers.extend(res)
|
||||
received = len(res)
|
||||
|
||||
now = datetime.now(timezone.utc)
|
||||
for v in vers:
|
||||
# How old is this version?
|
||||
date_str = v["updated_at"]
|
||||
parsed_date = datetime.fromisoformat(date_str.replace('Z', '+00:00'))
|
||||
days_ago = (now - parsed_date).days
|
||||
# Leave anything with 15 or less days
|
||||
if days_ago < 15:
|
||||
continue
|
||||
# Analyze the tags
|
||||
tags = v["metadata"]["container"]["tags"]
|
||||
if len(tags) == 0:
|
||||
print(f"Deleting {v['html_url']} UNTAGGED {days_ago} days ago")
|
||||
erase(v["id"])
|
||||
deleted += 1
|
||||
elif len(tags) == 1 and tags[0].startswith('dev_') and len(tags[0]) > 6:
|
||||
# Is dev_* and isn't tagged as the last dev
|
||||
print(f"Deleting {v['html_url']} {tags[0]} {days_ago} days ago")
|
||||
erase(v["id"])
|
||||
deleted += 1
|
||||
print(f"Deleted {deleted} versions")
|
||||
Loading…
Reference in New Issue