Skip to content

Commit

Permalink
Trying to fix docs
Browse files Browse the repository at this point in the history
Signed-off-by: Andy Goldstein <andy.goldstein@redhat.com>
  • Loading branch information
ncdc committed Jan 31, 2023
1 parent 6124312 commit 4b5d5dc
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 4 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/docs-gen-and-push.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,10 @@ jobs:
# copy back older versions to the current docs
- name: Copy everything from archive to docs
run: rsync -av docs/v* public
run: |
if ls docs/v* >/dev/null; then
rsync -av docs/v* public
fi
- name: Upload build artifact
uses: actions/upload-pages-artifact@v1
Expand Down
14 changes: 11 additions & 3 deletions hack/generate/crd-ref/run-crd-ref-gen.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,10 @@
# See the License for the specific language governing permissions and
# limitations under the License.

set -e
set -o errexit
set -o nounset
set -o pipefail
set -o xtrace

CRD_DOCS_GENERATOR_VERSION=0.10.0
# set destination to crd-reference directory in the docs
Expand All @@ -23,9 +26,14 @@ DESTINATION="docs/content/en/main/crd-reference"
# Clear output folder
find "${PWD}/${DESTINATION}" -type f -not -name "_index.md" | xargs -I '{}' rm '{}'

BIND_MOUNT_OPTS=":z"
if [[ $(uname -s) == "Darwin" ]]; then
BIND_MOUNT_OPTS=""
fi

# Generate new content
podman run --rm \
-v ${PWD}/${DESTINATION}:/opt/crd-docs-generator/output:z \
-v ${PWD}/hack/generate/crd-ref:/opt/crd-docs-generator/config:z \
-v "${PWD}"/${DESTINATION}:/opt/crd-docs-generator/output"${BIND_MOUNT_OPTS}" \
-v "${PWD}"/hack/generate/crd-ref:/opt/crd-docs-generator/config"${BIND_MOUNT_OPTS}" \
quay.io/giantswarm/crd-docs-generator:${CRD_DOCS_GENERATOR_VERSION} \
--config /opt/crd-docs-generator/config/config.yaml

0 comments on commit 4b5d5dc

Please sign in to comment.