mirror of
https://github.com/VinylDNS/vinyldns
synced 2025-08-22 10:10:12 +00:00
- Simplify build config - Add TTY check to Makefiles for running Docker containers - Update `fs2` to latest patch - Update `sbt-assembly` plugin - Update portal to remove chatty console - Update portal scripts to add license header - Update prepare-portal/Gruntfile to combine js and css where applicable - Remove unused gentelella files from final portal artifact - Add support for shared zones to quickstart/docker images - Consolidate built artifacts in `artifacts/` to make eventual release easier
Building VinylDNS
This folder contains scripts and everything you need to build and test VinylDNS from your own machine.
Pre-requisites
docker
- you will need docker and docker-compose installed locally
Local Build and Test
./docker-release.sh --clean
- Open up
version.sbt
in the root to know the directory (or capture in the script output) - Once complete, run a test
./start.sh --version 0.9.4-SNAPSHOT
(replace 0.9.4 with the value in version.sbt). - Login to the portal at http://localhost:9001 to verify everything looks good
- Run
./stop.sh
to bring everything down
Release Process
- If you are using image signing / docker notary, be sure you set the environment variable
export DOCKER_CONTENT_TRUST=1
.
Whether you sign or not is up to your organization. You need to have notary setup to be able to sign properly. - Be sure to login to your docker registry, typically done by
docker login
in the terminal you will release from. - The actual version number is pulled from the local
version.sbt
based on the branch specified (defaults to master) - Run
./docker-release.sh --push --clean --tag [your tag here] --branch [your branch here]
- typically the
tag
is a build number that you maintain, for example a build number in Jenkins. Using this field is recommended. This value will be appended to the generated version as-b[TAG]
; for example0.9.4-b123
if using123
for the tag. - the
branch
defaults tomaster
if not specified, you can choose any branch or tag from https://github.com/vinyldns/vinyldns
- typically the
- The version generated will be whatever the version is in the
version.sbt
on thebranch
specified (defaults to master) - Each of the images are built using the branch specified and the correct version
- The func tests are run with only smoke tests against the API image to verify it is working
- If everything passes, and the user specifies
--push
, the images are tagged and released to the docker repository (defaults to docker hub)
Release Script
Does a clean build off of remote master and tags it with
./docker-release.sh --clean --push --tag 123
The release script is used for doing a release. It takes the following parameters:
-b | --branch [BRANCH]
- what branch to pull from, can be any PR branch or a tag likev0.9.3
, defaults tomaster
-c | --clean
- a flag that indicates to perform a build. If omitted, the release script will look for a pre-built image locally-p | --push
- a flag that indicates to push to the remote docker registry. The default docker registry isdocker.io
-r | --repository [REPOSITORY]
- a URL to your docker registry, defaults todocker.io
-t | --tag [TAG]
- a build qualifer for this build. For example, pass in the build number for your continuous integration tool-v | --version [VERSION]
- overrides the version calculation and forces the version passed in. Used primarily for official releases
Docker Images
The build will generate several VinylDNS docker images that are used to deploy into any environment VinylDNS
vinyldns/api
- this is the heart of the VinylDNS system, the backend APIvinyldns/portal
- the VinylDNS web UI
vinyldns/api
The default build for vinyldns api assumes an ALL MYSQL installation.
Environment Variables
VINYLDNS_VERSION
- this is the version of VinylDNS the API is running, typically you will not set this as it is set as part of the container build
Volumes
/opt/vinyldns/conf/
- if you need to have your own application config file. This is MANDATORY for any production environments. Typically, you will add your ownapplication.conf
file in here with your settings./opt/vinyldns/lib_extra/
- if you need to have additional jar files available to your VinylDNS instance. Rarely used, but if you want to bring your own message queue or database you can put thejar
files there
vinyldns/portal
The default build for vinyldns portal assumes an ALL MYSQL installation.
Environment Variables
VINYLDNS_VERSION
- this is the version of VinylDNS the API is running, typically you will not set this as it is set as part of the container build
Volumes
/opt/vinyldns/conf/
- if you need to have your own application config file. This is MANDATORY for any production environments. Typically, you will add your ownapplication.conf
file in here with your settings./opt/vinyldns/lib_extra/
- if you need to have additional jar files available to your VinylDNS instance. Rarely used, but if you want to bring your own message queue or database you can put thejar
files there