generated from solvaholic/template
-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from solvaholic/version2
Updates for v2.0.0
- Loading branch information
Showing
12 changed files
with
290 additions
and
119 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#!/bin/sh | ||
|
||
# Source this file from your script like: | ||
# . ./.config | ||
|
||
# shellcheck disable=SC2034 | ||
{ | ||
|
||
_image=solvaholic/octodns-sync:latest | ||
|
||
_env_path=.env # .env file with secret keys and stuff | ||
_mountpoint=/config # Mountpoint for your config directory | ||
|
||
# $_volume is the Docker will mount at $_mountpoint: | ||
if command -v wslpath >/dev/null 2>&1; then | ||
_volume="$(wslpath -a .)" | ||
else | ||
_volume="$(realpath .)" | ||
fi | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# Perform release workflow tasks for this repo. | ||
|
||
name: Release | ||
|
||
on: | ||
release: | ||
types: [published] | ||
|
||
# A workflow run is made up of 1+ jobs that can run sequentially or in parallel | ||
# Steps represent a sequence of tasks that will be executed as part of a job | ||
|
||
jobs: | ||
# When a release is published, bump the corresponding short tag. | ||
# For example, when v2.0.4 is published, update v2 to v2.0.4's SHA. | ||
# TODO: Only run when tag_name matches /v[0-9]+\.[0-9]+\.[0-9]+/. | ||
# TODO: Only update when the published release is also the latest. | ||
bumptag: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Create/update the short tag to match the release tag | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
_repo: ${{ github.repository }} | ||
_api: https://api.github.com | ||
_tag_name: ${{ github.event.release.tag_name }} | ||
_tag_sha: ${{ github.sha }} | ||
run: | | ||
echo _tag_sha: ${_tag_sha} | ||
# Build the pieces of the curl command to use. | ||
_a="Authorization: token ${GITHUB_TOKEN}" | ||
_b="{\"ref\": \"refs/tags/${_tag_name%%.*}\"," | ||
_b+=" \"sha\": \"${_tag_sha}\"}" | ||
_c="${_api}/repos/${_repo}/git/refs" | ||
# Create the short tag, if it doesn't exist yet. | ||
curl -sL -XPOST -H "${_a}" -d "${_b}" "${_c}" | ||
# Revise curl parts for a different call. | ||
_b="{\"sha\": \"${_tag_sha}\"}" | ||
_c="${_api}/repos/${_repo}/git/refs/tags/${_tag_name%%.*}" | ||
# Update the major version tag, for example "v2". | ||
curl -sL -XPATCH -H "${_a}" -d "${_b}" "${_c}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# Run octodns with your config. | ||
# Run octodns-sync with your config. | ||
|
||
FROM python:3-slim | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.