Commit Graph

50 Commits

Author SHA1 Message Date
Tobias Genannt
a68f315acb Move default source image to Python 3.8 2020-09-01 12:27:39 +02:00
Tobias Genannt
795e82be46 Fix shellcheck error 2020-05-14 13:54:40 +02:00
Tobias Genannt
d8a6c321a1
Update build.sh
Include suggestion from cimnine

Co-authored-by: Christian Mäder <cimnine@users.noreply.github.com>
2020-05-14 13:49:19 +02:00
Tobias Genannt
786f9b50d2 Fixes build when DOCKER_FROM is set but empty
The DOCKER_FROM is set to an empty value in the push tests.
This expands the check to catch this test case
2020-04-09 10:26:21 +02:00
Tobias Genannt
5909670690 Fixed "latest" tag
The variable for the latest tag didn't contain all the needed values.
2020-04-09 09:04:20 +02:00
Tobias Genannt
d84c399c00 Let "latest" tag follow the highest version
Latest tag is now added to the new version when it is release by Netbox.
2020-04-09 08:17:05 +02:00
Tobias Genannt
794fb45e0e Fix shellcheck items found by shellcheck 0.7.1 2020-04-08 16:06:55 +02:00
Tobias Genannt
8e34f46bad Add checks to verifiy if a new build is needed
This checks if the source materials (python image, Netbox commit,
netbox-docker commit) have changed since the last build. This check is done
by comparing the digest and commit ids from the previous image with the
given tag to the current values taken from the Git and Docker repositories.

The checks are only performed for builds by the automated builds on Github.
2020-04-08 15:50:06 +02:00
Tobias Genannt
26d08302e3 Add labels for all variants
When we don't set the --label argument on the commandline for all
build variants we lose them in the image.
This also prints out the labes on image push.
2020-04-05 09:29:31 +02:00
Christian Mäder
dd0aee081a Fix failing GH Action 2020-01-17 18:46:30 +01:00
Christian Mäder
b118cd5812 Building the Docker image with Github Actions 2019-12-23 18:21:08 +01:00
Christian Mäder
7af88388bb
Merge pull request #202 from netbox-community/prepare_184
Prepares scripts and documentation for #184
2019-12-20 11:42:41 +01:00
Matt Olenik
66e90428b5 Remove use of GNU date extensions when labeling images
Fixes #197
2019-12-13 16:06:18 -08:00
Christian Mäder
a4186c1031 Prepares scripts and documentation for #184 2019-12-10 21:44:11 +01:00
Christian Mäder
6c762a7755 Merge branch 'fix-skip-git' of https://github.com/mattolenik/netbox-docker into mattolenik-fix-skip-git 2019-11-25 17:11:03 +01:00
Matt Olenik
34ce5be006 Respect SKIP_GIT environment variable when building
Fixes issue #190
2019-11-21 08:09:01 -08:00
Christian Mäder
caaa68234c Adds more labels to the Dockerfile
It also updates the README and the bug_report template to reflect
the changes. Additionally, in the README some relevant shields from
shields.io are added.

The labels follow [label-schema.org][lsorg] and the [OpenContainer
image spec, section annotations][ocis], specifications.

[lsorg]: http://label-schema.org/rc1/
[ocis]: https://github.com/opencontainers/image-spec/blob/master/annotations.md
2019-11-17 17:13:29 +01:00
Christian Mäder
e060f86b9a Corrections for shellcheck warnings 2019-10-15 10:03:39 +02:00
Christian Mäder
0a38220497 Update purpose text in build.sh 2019-10-15 01:00:21 +02:00
Christian Mäder
123fd981e9 Fix build
The Docker Hub build system runs on Ubuntu Xenial containers.
Xenial's git is 2.7.4, which does not know the `-P` flag yet.
2019-10-15 00:34:15 +02:00
Christian Mäder
20109c3392 Checkout the repository with git
This changes the build process even further. Instead
f using `wget` to fetch the current code, `git` is used.
This allows for faster switching between branches,
because only the differences between them have to be
fetched from the server.

But the main advantage is that the build cache can
finally be used as designed by Docker. Repetitive
builds are very fast now. This is also true between
branches and tags, as long as the `requirements.txt`
file doesn't change.
2019-10-15 00:34:15 +02:00
Christian Mäder
f3b9c34e3b externalize netbox download with wget 2019-10-15 00:34:15 +02:00
Christian Mäder
ab4b8720d1 Fix caching in build.sh 2019-10-15 00:34:15 +02:00
Christian Mäder
fadac8c5c3 Only build the master branch to speed up the test 2019-10-15 00:34:15 +02:00
Christian Mäder
d0ebb34432 Refactor to multistage builds
This commit introduces a huge change in the build process.

What changed:

- Dockerfile.ldap was integrated into Dockerfile as a seperate
  [build stage][multistage-build].
- All the build scripts were refactored according to this.
- The `docker-compose.yml` file was adjusted likewise.
- The main build script, `/build.sh`, now always builds all
  targets (formerly called variants).
- The minimal requirements for Docker and docker-compose
  have increased.
- The build on hub.docker.com must be adjusted.

This change should also fix #156 permanently.

[multistage-build]: https://docs.docker.com/develop/develop-images/multistage-build/
2019-10-15 00:34:15 +02:00
Christian Mäder
dc3db2d9fd %s/digitalocean/netbox-community/gi
Thank you Digitalocean for sponsoring Netbox!
And thank you for letting it grow up and move out ;)
2019-07-02 21:32:58 +02:00
Christian Mäder
286bfa0248 reorganized tagging 2019-03-27 12:00:32 +01:00
Tobias Genannt
220370ed76 Add short version tag
Adds a short version tag in the form of v$MAJOR.$MINOR. This tags
creates the possibillity to follow patch releases automatically with the
scheduled import option in Openshift and Kubernetes.
2019-03-22 08:28:41 +01:00
Christian Mäder
c1946751ef
Fix default in build.sh 2019-02-06 14:50:00 +01:00
Christian Mäder
6182133c7a
Update references to netboxcommunity 2019-02-06 11:46:20 +01:00
Christian Mäder
4ef420d443
Build system for hub.docker.com 2019-02-06 10:09:44 +01:00
Christian Mäder
a5dccb2558
Revert "⚙️ Print every command"
This reverts commit 1fb6b80f93.
2018-04-10 11:42:06 +02:00
Christian Mäder
1fb6b80f93
⚙️ Print every command 2018-04-10 11:13:52 +02:00
Christian Mäder
6c3966415b
⚙️ Additional build debug info 2018-04-10 10:58:31 +02:00
Martin Chlumsky
2bbb7f68f2 Add proxy support to build.sh. 2018-04-05 10:25:27 -04:00
Christian Mäder
f56a79381b
Introduces a Netbox Docker project version 2018-04-04 09:44:58 +02:00
Christian Mäder
ae9a3f04a5
✏️ Typo 2018-03-05 16:38:30 +01:00
Christian Mäder
747b32adb2
🐞 Fix parameter passing 2018-03-05 16:29:02 +01:00
Christian Mäder
e3120a715e
🐳 Allow variants from other source images 2018-03-05 14:35:11 +01:00
Christian Mäder
30a37511e2
❇️ Adds DEBUG option 2018-03-05 14:32:04 +01:00
Christian Mäder
8f001adef4
💄 Cleanup and hide warnings 2018-03-05 14:29:24 +01:00
Tobias Genannt
6a01a3379d Add django_ldap_auth
In the ldap.Dockerfile the django_ldap_auth module is installed to
enable authentication againt LDAP servers.
2018-02-27 10:09:14 +01:00
Christian Mäder
fe05ca5c7c
❇️ Adds new options to the build script 2018-02-02 12:48:38 +01:00
Christian Mäder
d2ec32fefe
Travis docker can't do squash 2018-01-30 16:00:05 +01:00
Christian Mäder
dca64f55f5
❇️ Squash the images 2018-01-30 14:48:40 +01:00
Christian Mäder
e5e5f0204d
✏️ Overhaul of the README
Plus some adjustment to the `build.sh` help text.

Fixes #3
2017-09-11 15:30:52 +02:00
Christian Mäder
34d5bd711e
❇️ Don't use Docker cache for 'master' and 'develop' 2017-08-11 17:08:43 +02:00
Christian Mäder
fe82d10aeb
Changes the build script's messages to be more precise 2017-06-09 13:05:02 +02:00
Christian Mäder
57c848978c
Build script recognizes master=latest and develop=snapshot 2017-06-09 12:41:14 +02:00
Christian Mäder
d9c1bd143d
Add suggestions from PRs in digitalocean/netbox-drocker 2017-06-09 10:14:43 +02:00