Closed bbroniewski closed 10 months ago
Content file works perfectly on server preview, fails on minify during build.
Start building sites … hugo v0.99.0-1de333e7a3fc863672ec6d6cd53ba66dbcdd2305+extended linux/amd64 BuildDate=2022-05-16T08:10:56Z VendorInfo=gohugoio Error: Error building site: MINIFY: failed to transform "index.js" (application/javascript): unexpected s in expression on line 144 and column 8696 Total in 2508 ms 144: ...default CA like Let's Encrypt, Google and...
I tried with latest version of hugo and it is the same.
Fresh install, page added, and it looks OK to me: website + repo
Error: Error building site: MINIFY: failed to transform "index.js" (application/javascript): unexpected s in expression on line 144 and column 8696
I recall an issue with comments in index.js
. Does this help you: https://github.com/h-enk/doks/issues/716#issuecomment-1102618110?
Otherwise, please provide your Doks repo.
Description
Hi, I am facing issue with markdown file with content which contains code fences. Some characters are causing build to crash.
Steps to reproduce
Example repository from gets started of this project with my content added:
title: "Setting up SSL with cert-manager and trust-manager"
description: "An example for setting up ssl connections using cert-manager and trust-manager projects" draft: false images: [] menu: docs: parent: "tutorials" weight: 110 toc: true
A lot of Kubernetes clusters already use cert-manager and trust-manager to handle certificates management.
The goal of this tutorial is to show how to configure ActiveMQ Artemis Operator resources to utilize both projects mentioned above for ssl communication.
Prerequisites
Installation guides for cert-manager and trust-manager you can find on the cert-manager project website.
SSL
There are various scenarioes how SSL can be achived for your ActiveMQ Artemis brokers, to list some:
In this tutorial we will cover the first scenario "ActiveMQ Artemis brokers handling SSL termination" with no assumption it is the best for your cluster, please consider the best setup yourself.
Let's start!
Prepare keystore and truststore
Here we are gonna use cert-manager and trust-manager to create keystore and truststore.
Our assumption is that you are gonna use local Issuer or local ClusterIssuer in cert-manager.
Another assumption is your cert-manager and trust-manager are installed in the "cert-manager" namespace.
Create local CA (Certificate authority)
:information_source: If you have already some local CA configured please go directly to the next step.
To create local CA, first we need to have base certificate for that issuer to allow it issue certificates. This base certificate for our custom local CA should be saved into the secret in cert-manager namespace with the secret type kubernetes.io/tls.
One way of creating it is to use selfsigned-cluster-issuer:
Use kubectl apply command with file created based on the yaml below.
Now you have your own CA which can sign new certificates for you.
Create secret for keystore password
Replace myproject with actual namespace your brokers are installed in.
Replace dummy_password with actual password you want to use.
You can create a secret directly using command line:
Create certificate for ActiveMQ Artemis brokers
Create certificate resource using kubectl apply.
Replace all occuriences of myproject with actual namespace your brokers are installed in.
Create truststore using trust-manager
Here we will utlize trust-manager to create truststore in config map.
:information_source: Truststore does not contain any secrets, that's why it is stored by trust-manager in a config map, additionally password for truststore is set by design to "changeit", because of the same reason (no secrets).
It is advised to create a copy of your base CA certificate to not have an issue during CA certificate rotation event, so we will create a copy of base certificate of CA. In the phase of rotation of that certificate you would need to support old and new base CA certificate until all services use already certificates issued based on the new one. You can read more in trust-manager documentation about that topic.
Copy base ca secret:
Create bundle resource which trust-manager will use to create ca budles in all namespaces of your cluster. Use
kubectl apply
with content below:This will produce configmap in all namespaces with truststore.jks and trust-bundle.pem which you can use internally for any services inside your cluster (java based or others).
Create a secret with the details of your ssl setup for the ActiveMQ Artemis broker
Replace dummy_password with the password you have used in section Create secret for keystore password.
Do not replace changeit password, it is like that by design, for more informations please check above in trust-manager section.
Deploy ArtemisCloud operator
Operator will create ActiveMQ resources based on custom resources definitions (CRD).
If you are not sure how to deploy the operator take a look at [here]({{< relref "using_operator.md" >}}).
In this tutorial we assume you deployed the operator to a namespace called activemq-artemis-operator.
Make sure the operator is in "Runing" status before going to the next step. You can run this command and observe the output:
Deploy a broker
Example of the broker CRD is located in the local repository cloned during activities from section Deploy ArtemisCloud operator.
Replace myproject with actual namespace your brokers are installed in.
Deploy a broker with (beeing on the root folder of this repository):
Deploy a queue
Example of the queue CRD is located in the local repository cloned during activities from section Deploy ArtemisCloud operator.
Deploy a queue with (beeing on the root folder of this repository):
The CR tells the Operator to create a queue named myQueue0 on address myAddress0 on each broker that it manages.
After the CR is deployed, you can observe the queue on the broker:
Test messaging over a SSL connection
Log into the broker pod first to get a shell command environment:
Then send 100 messages through port 61618, but before replace dummy_password with the password you have used in section Create secret for keystore password.
Finally you can receive those 100 messages (again replace dummy_password with the password you have used in section Create secret for keystore password):
This confirms everything works as expected!
Have fun!
Expected result
I expect markdown with code fences to be supported out of the box.
Actual result
Build is failing.
Environment
Repo from gets started