a new gitlab runner for publishing static content ranging from webpages, release based content, RPM and debian repositories straight from gitlab with out of the box automatic https and no hassle to setup keys and or passwords for publishing.
Using Gitlab and the integrated CI/CD for software and webpages is a great way to keep track of things and manage the projects, it being opensource and out of the box support for CI/CD makes it a must have tool in software development.
With this project we hope to add even more or easier deployment of output and/or static webpages.
Easy deployment of environments for publishing software releases, repository setup and deployment for rpm/deb and static web page development from a Gitlab-instance (gitlab.com and/or private instance).
Read more on the choice to integrate the runner with deployctl deployctl runner
deployctl commands are predefined commands executed by the
deployctl runner which is running on the deployment/production web-server as a non-privileged user.
so for dynamic environments :
and deployctl handles:
As a quick example, an excerpt of the
gitlab-ci.yml to publish this website.
variables: CI_PROJECT_PATH_SLUG: deployctl-www-deployctl-com DEPLOY_DOMAIN_APP: gioxapp.com DEPLOY_DOMAIN : www.deployctl.com DEPLOY_CONFIG_HTTPS: "True" DEPLOY_PUBLISH_PATH: '["/":"/web/_sites/"]' release: tags: - deployctl-gioxapp.com variables: GIT_STRATEGY: none environment: name: production url: http://$DEPLOY_DOMAIN script: - deployctl static only: - master
deployctl static will :
DEPLOY_CONFIG_HTTPSconfigure the website for https
DEPLOY_DOMAIN_APPpoints to the app-server
DEPLOY_DOMAINhas a CNAME record pointing to
CI_PROJECT_PATH_SLUGneeds to be defined only if no custom domain in
DEPLOY_DOMAINis defined. Since gitlab 9.3, this is defined, but it can contain
_making it a no go to use as part of a domain name since let’s encrypt does not accept
_. gitlab issue #34643
DEPLOY_PUBLISH_PATH: '["/":"/web/_sites/"]'which will use the content in
/web/_sites/as output, no need to copy or move content.
DEPLOY_PUBLISH_PATHis not defined, it defaults to
deployctl static : deploys a static page for the environment from the public directory
deployctl release : creates a download page per environment with:
links list generated from:
*.url files, containing
<href>,metric, with filename without extension as name.
DEPLOY_hrefs: a key/value array: ‘[“name”: “href”,”name1”: “href2”,…]’
And For a production environment, with release tag creates additional :
Release notes as per the Gitlab tag’s release.
updates the releases page, with all releases
/release.json : a static JSON database, containing an overview of all releases with release notes as per gitlab Tag’s, links and other info.
/tag.svg : a release tag to use in the projectpage or webpage indicating the latest release.
an updated link to /latest
deployctl delete : deletes the deployment environment
REMARK: Release info is only availleble when the project is public! If you like this, upvote gitlab issue #29566
Spin of a VM on a provider, give it a hostname.
have the DNS A/AAAA record to point to it’s ip.
add a wild-card
* CNAME record.
Take note of the gitlab runner registration-token and url on gitlab.
Modify the repository
Read more about gitlab support and concepts for dynamic environment deployment here
09 Aug 2017
deployctl now support deployment to a repository for rpm and deb packages with easy client install and multiple projects support.
09 Aug 2017
deployctl is no longer a
gitlab-runner helper, but a new dedicated runner for static deployments.
Read further about the reasons for this development.
24 Mar 2017
deployctl deployment server on Digital Ocean for use with Gitlab to deploy static websites and releases.