Skip to content

Commit 0dea285

Browse files
committed
feat: add builder
0 parents  commit 0dea285

17 files changed

+1233
-0
lines changed

.dockerignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
*
2+
!Dockerfile
3+
!bin

.editorconfig

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# editorconfig.org
2+
root = true
3+
4+
[*]
5+
indent_style = space
6+
indent_size = 2
7+
end_of_line = lf
8+
charset = utf-8
9+
trim_trailing_whitespace = true
10+
insert_final_newline = true

.github/renovate.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
3+
"extends": ["local>containerbase/.github"]
4+
}

.github/workflows/build.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: build
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- 'renovate/**'
8+
9+
pull_request:
10+
11+
jobs:
12+
build:
13+
runs-on: ubuntu-latest
14+
15+
strategy:
16+
matrix:
17+
distro: [focal, bionic]
18+
arch: [x86_64]
19+
20+
env:
21+
DISTRO: ${{ matrix.distro }} # build target, name required by binary-builder
22+
ARCH: ${{ matrix.arch }} # build target, name required by binary-builder
23+
24+
steps:
25+
- uses: actions/[email protected]
26+
27+
- name: binary-builder
28+
uses: renovatebot/[email protected]
29+
with:
30+
command: binary-builder
31+
dry-run: ${{github.ref != 'refs/heads/main'}}
32+
token: ${{ secrets.GITHUB_TOKEN }}
33+
34+
- uses: actions/[email protected]
35+
with:
36+
name: ${{ env.DISTRO }}
37+
path: .cache/*.tar.xz

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
.cache
2+
node_modules
3+
dist/
4+
data/

.huskyrc.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"hooks": {
3+
"pre-commit": "pretty-quick --staged"
4+
}
5+
}

.prettierignore

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
node_modules/
2+
.vs/
3+
dist/
4+
coverage/
5+
.cache/
6+
data/
7+
yarn.lock
8+
9+
.editorconfig
10+
.*ignore
11+
.npmrc
12+
.yarnrc
13+
.yarnclean
14+
15+
*.snap
16+
*.sh

.prettierrc.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"singleQuote": true,
3+
"trailingComma": "es5"
4+
}

Dockerfile

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
#--------------------------------------
2+
# Ubuntu flavor
3+
#--------------------------------------
4+
ARG DISTRO
5+
6+
#--------------------------------------
7+
# base images
8+
#--------------------------------------
9+
FROM ubuntu:bionic@sha256:4bc3ae6596938cb0d9e5ac51a1152ec9dcac2a1c50829c74abd9c4361e321b26 as build-bionic
10+
FROM ubuntu:focal@sha256:b4f9e18267eb98998f6130342baacaeb9553f136142d40959a1b46d6401f0f2b as build-focal
11+
12+
13+
#--------------------------------------
14+
# builder images
15+
#--------------------------------------
16+
FROM build-${DISTRO} as builder
17+
18+
19+
ENTRYPOINT [ "dumb-init", "--", "builder.sh" ]
20+
21+
COPY bin /usr/local/bin
22+
23+
RUN install-builder.sh

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2021 WhiteSource Ltd
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

0 commit comments

Comments
 (0)