summaryrefslogtreecommitdiff
path: root/content/html
diff options
context:
space:
mode:
authorPaul Buetow <git@mx.buetow.org>2021-05-01 19:14:32 +0100
committerPaul Buetow <git@mx.buetow.org>2021-05-21 05:11:04 +0100
commit689d9f201e13ce386ffaa1a161908263bcd16b95 (patch)
treefc1e2f239cbdb962d9bd7637e8886d2a84cd1cd1 /content/html
parent2a0f3afe20d5b6eaae9eed4d01393a70fa2abc39 (diff)
fix < and > in pre
Diffstat (limited to 'content/html')
-rw-r--r--content/html/gemfeed/2016-05-22-spinning-up-my-own-authoritative-dns-servers.html50
-rw-r--r--content/html/gemfeed/2016-11-20-methods-in-c.html18
2 files changed, 34 insertions, 34 deletions
diff --git a/content/html/gemfeed/2016-05-22-spinning-up-my-own-authoritative-dns-servers.html b/content/html/gemfeed/2016-05-22-spinning-up-my-own-authoritative-dns-servers.html
index 95f6f78f..4bf4e371 100644
--- a/content/html/gemfeed/2016-05-22-spinning-up-my-own-authoritative-dns-servers.html
+++ b/content/html/gemfeed/2016-05-22-spinning-up-my-own-authoritative-dns-servers.html
@@ -30,28 +30,28 @@ li { color: #98be65; }
include freebsd
freebsd::ipalias { '2a01:4f8:120:30e8::14':
- ensure =>gt; up,
- proto =>gt; 'inet6',
- preflen =>gt; '64',
- interface =>gt; 're0',
- aliasnum =>gt; '5',
+ ensure =&gt; up,
+ proto =&gt; 'inet6',
+ preflen =&gt; '64',
+ interface =&gt; 're0',
+ aliasnum =&gt; '5',
}
include jail::freebsd
class { 'jail':
- ensure =>gt; present,
- jails_config =>gt; {
- dns =>gt; {
- '_ensure' =>gt; present,
- '_type' =>gt; 'freebsd',
- '_mirror' =>gt; 'ftp://ftp.de.freebsd.org',
- '_remote_path' =>gt; 'FreeBSD/releases/amd64/10.1-RELEASE',
- '_dists' =>gt; [ 'base.txz', 'doc.txz', ],
- '_ensure_directories' =>gt; [ '/opt', '/opt/enc' ],
- 'host.hostname' =>gt; "'dns.ian.buetow.org'",
- 'ip4.addr' =>gt; '192.168.0.15',
- 'ip6.addr' =>gt; '2a01:4f8:120:30e8::15',
+ ensure =&gt; present,
+ jails_config =&gt; {
+ dns =&gt; {
+ '_ensure' =&gt; present,
+ '_type' =&gt; 'freebsd',
+ '_mirror' =&gt; 'ftp://ftp.de.freebsd.org',
+ '_remote_path' =&gt; 'FreeBSD/releases/amd64/10.1-RELEASE',
+ '_dists' =&gt; [ 'base.txz', 'doc.txz', ],
+ '_ensure_directories' =&gt; [ '/opt', '/opt/enc' ],
+ 'host.hostname' =&gt; "'dns.ian.buetow.org'",
+ 'ip4.addr' =&gt; '192.168.0.15',
+ 'ip6.addr' =&gt; '2a01:4f8:120:30e8::15',
},
.
.
@@ -65,8 +65,8 @@ class { 'jail':
.
.
# dns.ian.buetow.org
-rdr pass on re0 proto tcp from any to $pub_ip port {53} ->gt; 192.168.0.15
-rdr pass on re0 proto udp from any to $pub_ip port {53} ->gt; 192.168.0.15
+rdr pass on re0 proto tcp from any to $pub_ip port {53} -&gt; 192.168.0.15
+rdr pass on re0 proto udp from any to $pub_ip port {53} -&gt; 192.168.0.15
pass in on re0 inet6 proto tcp from any to 2a01:4f8:120:30e8::15 port {53} flags S/SA keep state
pass in on re0 inet6 proto udp from any to 2a01:4f8:120:30e8::15 port {53} flags S/SA keep state
.
@@ -76,8 +76,8 @@ pass in on re0 inet6 proto udp from any to 2a01:4f8:120:30e8::15 port {53} flags
<p>In "manifests/dns.pp" (the Puppet manifest for the Master DNS Jail itself) I configured the BIND DNS server this way:</p>
<pre>
class { 'bind_freebsd':
- config =>gt; "puppet:///files/bind/named.${::hostname}.conf",
- dynamic_config =>gt; "puppet:///files/bind/dynamic.${::hostname}",
+ config =&gt; "puppet:///files/bind/named.${::hostname}.conf",
+ dynamic_config =&gt; "puppet:///files/bind/dynamic.${::hostname}",
}
</pre>
<p>The Puppet module is actually a pretty simple one. It installs the file "/usr/local/etc/namerd/named.conf" and it populates the "/usr/local/etc/named/dynamicdb" directory with all my zone files.</p>
@@ -142,10 +142,10 @@ zone "buetow.zone" {
<p>The end result looks like this now:</p>
<pre>
% dig -t ns buetow.org
-; <lt;<lt;>gt;>gt; DiG 9.10.3-P4-RedHat-9.10.3-12.P4.fc23 <lt;<lt;>gt;>gt; -t ns buetow.org
+; &lt;&lt;&gt;&gt; DiG 9.10.3-P4-RedHat-9.10.3-12.P4.fc23 &lt;&lt;&gt;&gt; -t ns buetow.org
;; global options: +cmd
;; Got answer:
-;; ->gt;>gt;HEADER<lt;<lt;- opcode: QUERY, status: NOERROR, id: 37883
+;; -&gt;&gt;HEADER&lt;&lt;- opcode: QUERY, status: NOERROR, id: 37883
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
@@ -163,10 +163,10 @@ buetow.org. 600 IN NS dns1.buetow.org.
;; MSG SIZE rcvd: 77
% dig -t any buetow.org @dns1.buetow.org
-; <lt;<lt;>gt;>gt; DiG 9.10.3-P4-RedHat-9.10.3-12.P4.fc23 <lt;<lt;>gt;>gt; -t any buetow.org @dns1.buetow.org
+; &lt;&lt;&gt;&gt; DiG 9.10.3-P4-RedHat-9.10.3-12.P4.fc23 &lt;&lt;&gt;&gt; -t any buetow.org @dns1.buetow.org
;; global options: +cmd
;; Got answer:
-;; ->gt;>gt;HEADER<lt;<lt;- opcode: QUERY, status: NOERROR, id: 49876
+;; -&gt;&gt;HEADER&lt;&lt;- opcode: QUERY, status: NOERROR, id: 49876
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 6, AUTHORITY: 0, ADDITIONAL: 7
;; OPT PSEUDOSECTION:
diff --git a/content/html/gemfeed/2016-11-20-methods-in-c.html b/content/html/gemfeed/2016-11-20-methods-in-c.html
index 3b2efa46..0d0bdc53 100644
--- a/content/html/gemfeed/2016-11-20-methods-in-c.html
+++ b/content/html/gemfeed/2016-11-20-methods-in-c.html
@@ -25,7 +25,7 @@ li { color: #98be65; }
<h2>Example</h2>
<p>Lets have a look at the following sample program. Basically all you have to do is to add a function pointer such as "calculate" to the definition of struct "something_s". Later, during the struct initialization, assign a function address to that function pointer:</p>
<pre>
-#include <lt;stdio.h>gt;
+#include &lt;stdio.h&gt;
typedef struct {
double (*calculate)(const double, const double);
@@ -53,26 +53,26 @@ int main(void) {
const double a = 3, b = 2;
- printf("%s(%f, %f) =>gt; %f\n", mult.name, a, b, mult.calculate(a,b));
- printf("%s(%f, %f) =>gt; %f\n", div.name, a, b, div.calculate(a,b));
+ printf("%s(%f, %f) =&gt; %f\n", mult.name, a, b, mult.calculate(a,b));
+ printf("%s(%f, %f) =&gt; %f\n", div.name, a, b, div.calculate(a,b));
}
</pre>
<p>As you can see you can call the function (pointed by the function pointer) the same way as in C++ or Java via:</p>
<pre>
-printf("%s(%f, %f) =>gt; %f\n", mult.name, a, b, mult.calculate(a,b));
-printf("%s(%f, %f) =>gt; %f\n", div.name, a, b, div.calculate(a,b));
+printf("%s(%f, %f) =&gt; %f\n", mult.name, a, b, mult.calculate(a,b));
+printf("%s(%f, %f) =&gt; %f\n", div.name, a, b, div.calculate(a,b));
</pre>
<p>However, that's just syntactic sugar for:</p>
<pre>
-printf("%s(%f, %f) =>gt; %f\n", mult.name, a, b, (*mult.calculate)(a,b));
-printf("%s(%f, %f) =>gt; %f\n", div.name, a, b, (*div.calculate)(a,b));
+printf("%s(%f, %f) =&gt; %f\n", mult.name, a, b, (*mult.calculate)(a,b));
+printf("%s(%f, %f) =&gt; %f\n", div.name, a, b, (*div.calculate)(a,b));
</pre>
<p>Output:</p>
<pre>
pbuetow ~/git/blog/source [38268]% gcc methods-in-c.c -o methods-in-c
pbuetow ~/git/blog/source [38269]% ./methods-in-c
-Multiplication(3.000000, 2.000000) =>gt; 6.000000
-Division(3.000000, 2.000000) =>gt; 1.500000
+Multiplication(3.000000, 2.000000) =&gt; 6.000000
+Division(3.000000, 2.000000) =&gt; 1.500000
</pre>
<p>Not complicated at all, but nice to know and helps to make the code easier to read!</p>
<h2>Taking it further</h2>