Skip to content

Commit

Permalink
content transfer from original blog alxshelepenok#2
Browse files Browse the repository at this point in the history
  • Loading branch information
ochaloup committed Oct 18, 2022
1 parent fd5eda0 commit 5b6f798
Show file tree
Hide file tree
Showing 24 changed files with 256 additions and 60 deletions.
6 changes: 6 additions & 0 deletions TODO.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
= What to do

* styling of links and code - it could be similar as it's at original blog http://blog.chalda.cz/2017/05/06/DNS-setting-for-Git-Hub-pages.html
* is possible to generate TOC?
* why RSS generation does not work
* could be used the icons? if not it's necessary to remove things like `icon:smile-o[]` from the adoc sources
6 changes: 3 additions & 3 deletions content/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"googleAnalyticsId": "UA-91848308-1",
"googleManagerTag": "GTM-5NQ9VLB",
"disqusShortname": "",
"postsLimit": 4,
"postsLimit": 6,
"pathPrefix": "/",
"menu": [
{
Expand All @@ -18,8 +18,8 @@
"path": "/pages/links"
},
{
"label": "Contact me",
"path": "/pages/contacts"
"label": "Tags",
"path": "/tags"
}
],
"author": {
Expand Down
12 changes: 0 additions & 12 deletions content/pages/about/index.adoc

This file was deleted.

Binary file removed content/pages/about/notebook.jpg
Binary file not shown.
30 changes: 22 additions & 8 deletions content/pages/links/index.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,34 @@

Different articles I worked on.

== List of presentation
== List of presentations

* http://chalda.cz

== Narayana and XA transactions

* https://developer.jboss.org/wiki/TwoPhaseCommit2PC
* https://developer.jboss.org/wiki/Three-phaseCommitProtocol - https://developer.jboss.org/docs/DOC-56051 - Three-phase commit protocol (3PC)
* http://jbossts.blogspot.com/2018/06/narayana-commit-markable-resource.html
* http://jbossts.blogspot.cz/2018/01/narayana-periodic-recovery-of-xa.html
* http://jbossts.blogspot.cz/2018/01/recovery-of-narayana-jdbc-transactional.html
* https://developer.jboss.org/wiki/MSAQuickstartsWithLRAREST-ATOnMinishift - https://developer.jboss.org/docs/DOC-56074 MSA quickstarts with LRA/REST-AT on Minishift
* http://jbossts.blogspot.cz/2017/06/sagas-and-how-they-differ-from-two.html
* https://developer.jboss.org/docs/DOC-55995[Two Phase commit (2PC)] — How 2PC works in Narayana that's integrated to WildFly/Quarkus
* https://developer.jboss.org/docs/DOC-56051[Three-phase commit protocol (3PC)] — A basic discussion on the 3PC protocol
* http://jbossts.blogspot.com/2018/06/narayana-commit-markable-resource.html[Narayana Commit Markable Resource: a faultless LRCO for JDBC datasources] — How the CMR, an 2PC improvement, works in Narayana
* http://jbossts.blogspot.cz/2018/01/narayana-periodic-recovery-of-xa.html[Narayana periodic recovery of XA transactions] — Details about Narayana periodic recovery
* https://jbossts.blogspot.com/2017/12/narayana-jdbc-transactional-driver.html[Narayana jdbc transactional driver] — Narayana standalone driver for JDBC
* http://jbossts.blogspot.cz/2018/01/recovery-of-narayana-jdbc-transactional.html[Recovery of Narayana jdbc transactional driver] — Technical details about Narayana JDBC recovery
* https://jbossts.blogspot.com/2019/06/expiry-scanners-and-object-store-in.html[Expiry scanners and object store in Narayana] — How Narayana stores data
* https://developer.jboss.org/docs/DOC-56074[MSA quickstarts with LRA/REST-AT on Minishift] — How to run REST-AT on Minishift
* http://jbossts.blogspot.cz/2017/06/sagas-and-how-they-differ-from-two.html[Sagas and how they differ from two-phase commit] — What is difference of Saga and 2PC protocols
* https://jbossts.blogspot.com/2017/12/narayana-lra-implementation-of-saga.html[Narayana LRA: implementation of saga transactions] — About LRA as Saga protocol implementation in Narayana
* https://jbossts.blogspot.com/2019/04/jta-and-cdi-integration.html[JTA and CDI integration] — About transactional topics of the CDI specification
* https://jbossts.blogspot.com/2018/10/integration-with-agroal-database.html[Narayana integration with Agroal connection pool] — Agroal and Narayana integration
* https://jbossts.blogspot.com/2018/05/narayana-jdbc-integration-for-tomcat.html[Narayana JDBC integration for Tomcat] — Tomcat and Narayana integration
* https://jbossts.blogspot.com/2021/08/lra-annotation-checker-maven-plugin.html[LRA annotation checker Maven plugin] — About creation of LRA annotations checker as a Maven plugin
* https://jbossts.blogspot.com/2019/09/heuristic-exceptions.html[Heuristic exceptions] — What are the heuristic exceptions about

== Workshops

* https://github.com/ochaloup/20220605_solana_contracts[Solana workshop for UTXO 2022]
* https://github.com/ochaloup/20211009_workshop_geth_pending_logs[Geth workshop for ETH Brno 2021]
* https://github.com/ochaloup/byteman-workshop[Byteman workshop for DevConf.cz 2018]

== Projects

* https://github.com/ochaloup/vim-syntax-match[Vim plugin for storing syntax matching rules on disk] — a Vim plugin that's handy while investigating through the log records

This file was deleted.

122 changes: 122 additions & 0 deletions content/posts/2017-05-06-DNS-setting-for-GitHub-pages/index.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,122 @@
= DNS settings for GitHub pages
chalda <chalda@seznam.cz>
1.0, 2017-05-06

:icons: font
:toc: macro

:page-template: post
:page-draft: false
:page-slug: dns-settings-of-github-pages
:page-category: DevOps
:page-tags: github, dns
:page-description: How to setup DNS to work with GitHub pages.
:page-socialImage: /articles/notebook.jpg


toc::[]


== Github pages

When setting a blog on GitHub pages I found a bit hard for me to understand
what should be set for DNS to run it on my custom domain.

There is quite good introductory for the process in
https://help.github.com/articles/using-a-custom-domain-with-github-pages/[documentation]
but still I was quite confused at the start. Unknown terms and fact that
I'm not familiar with DNS. I mean I haven't seen it from my college times.

I wanted the following setup

* https://github.com/ochaloup/ochaloup.github.io being pointed from domain http://chalda.cz
* https://github.com/ochaloup/blog.chalda.cz being pointed from domain http://blog.chalda.cz
* `www` variants points to variant without www (http://www.chalda.cz to http://chalda.cz)

=== War of terminology

* *user pages* - regards of https://help.github.com/articles/custom-domain-redirects-for-github-pages-sites/[DNS settings]
it's the same thing as organization pages just for a user. A user (me) have only one user
personal pages. You can create one when creating GitHub repository `<username>.github.io`.
In my case it's https://github.com/ochaloup/ochaloup.github.io. Then any static web page content
is available at `http://ochaloup.github.io`.
* *project pages* - _project_ is my blog at https://github.com/ochaloup/blog.chalda.cz.
By default is available at `http://ochaloup.github.io/blog.chalda.cz`.
* *apex domain* - is equal to a term `root domain` - meaning domain without `www` or `blog`.
In my case the wording `apex domain` means `chalda.cz`

=== Repository settings

For a GitHub repository being availble on GitHub Pages (meaning under `.github.io`)
you need to set it up. Go by tab `Settings` at your repository and scroll down to section _GitHub Pages_.
There you change _None_ to a branch that should represent the content of the _GitHub Pages_.

When you want to use custom domain you need to define what will be at box _Custom domain_.
In my case I want to have the blog available under http://blog.chalda.cz then I set there `blog.chalda.cz`.
My user page should be available under http://chalda.cz then I set there `chalda.cz`.
Now when you do so GitHub starts with automatic recirection to the custom domain.
In my case it means that going to http://ochaloup.github.io will
automatically redirect to https://chalda.cz.

When you define something into _Custom domain_ box then GitHub automatically creates
a file named `CNAME` with only one line consisting the specified Custom domain. Changing
or creating content of the `CNAME` file has the same result as setting that in the box
under `Settings` tab.

== DNS settings

First (probably obvious but...) observation was that changes in settings are propagated
really in terms of hours, not sooner icon:smile-o[]

After spending some time with help of https://help.github.com/articles/troubleshooting-custom-domains/[GitHub documentation]
and some blog posts similar to this one I got the following settings started to work.

[NOTE]
====
Documentation recommends using `ALIAS` DNS record for apex domain settings than
`A` record but `ALIAS` is not available in DNS settings of my provider.
I just took a `cz` domain from first offer came from Google search at http://domena.cz.
====

* https://github.com/ochaloup/ochaloup.github.io has custom domain set as `chalda.cz`
* https://github.com/ochaloup/blog.chalda.cz has custom domain set as `blog.chalda.cz`
* DNS settings

```
@ IN SOA ns1.ignum.com. hostmaster.ignum.cz. 2017020502 10800 3600 604800 3600
@ IN A 192.30.252.153
@ IN A 192.30.252.154
blog IN CNAME ochaloup.github.io.
www IN CNAME ochaloup.github.io.
@ IN NS ns1.ignum.com.
@ IN NS ns2.ignum.com.
@ IN TXT "v=spf1 include:_spf.ignum.cz ~all"
_autodiscover._tcp IN SRV 0 0 443 nmrdiscover.ignum.cz.
```

For more information on `SOA`, `NS` and `TXT` record check some DNS documentation.
Here briefly what I understood - `SOA` is compulsory, defines who is responsible
for domain, `NS` is required by my provider here and defines where name servers
for this domains are, `TXT` serves information about the server (e.g. dns account info).

Now the `A` records are needed for apex domain `chalda.cz` redirection works.
It points to GitHub DNS servers diretly.
The `blog` (for redirect to _project page_) uses `CNAME` record
and points to my `github.io`.
Finally `www` `CNAME` record serves to get available my _user page_ at domain
http://chalda.cz and http://www.chalda.cz. (TODO: here does not work or what?)

=== Tools to help

When I start to play with setup I found out two tools helpful.

* command `dig` - `dig chalda.cz`. With a more consense output
`dig chalda.cz +nostats +nocomments +nocmd`
* Chrome developer tools (Ctrl+Shift+I) - got to tab _Network_, enable checkbox _Preserve log_
and go to e.g. http://ochaloup.github.io. You can see in headers that you were redirected
to http://chalda.cz by `301 Moved Permanently`. If you do some changes then info that the page
was moved permanently is remembered in browser cache and browser then directly shows you the http://chalda.cz
without consultation with DNS server (`301 Moved Permanently (from disk cache)`). To workaround that clear
the Chrome's cache - go to `chrome://net-internals`, click a _small down pointing arrow in right corner_
and choose _Tools -> Clear cache_ from drop down menu.
103 changes: 103 additions & 0 deletions content/posts/2017-05-07-Hub-Pressio-how-to-installl/index.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
= HubPress.io - how to installl
chalda <chalda@seznam.cz>
1.0, 2017-05-07

:icons: font

:page-template: post
:page-draft: false
:page-slug: hubpress-io-how-to-install
:page-category: devops
:page-tags: hubpress.io, blog
:page-description: How to start using Hubpress.io. The motivation is to use AsciiDoctor syntax for the text and having a generator of the pages.
:page-socialImage: /articles/notebook.jpg


== Installation of HubPress.io

Writing blogposts is a proof-of-concept for me having them as a knowledgebase.
For a some time when writing any note I use http://asciidoctor.org[AsciiDoc(tor)] format.
Thus I started to search for option that allows me to write blog-notes that way too.

I could see that many people host blogs at http://github.io I decided to try that way too.
I started by looking for a tool to generate static webpages with http://asciidoctor.org/docs/asciidoc-asciidoctor-diffs[AsciiDoc] support.
There is the mostly used `Jekyll` - written in ruby, generating a webpage from template
on your local machine. There is https://github.com/asciidoctor/jekyll-asciidoc[plugin for AsciiDoc].
Other tool that I was evaluating was http://awestruct.org[:awestruct].

Then I found http://hubpress.io[HubPress.io] that has a concept of a webapp whole written in javascript
which generates static website directly in your browser sending it then to GitHub repo. Merit of this approach
is a nice admin console in your browser. Flaw is a little bit longer waiting time to get post being published.
The other could be current
http://blog.hubpress.io/2016/10/11/We-Arent-Dead-Yet-Hub-Press-Roadmap.html[stall in the development process]. But it seems not be fully true as there is new versions coming (see
https://github.com/HubPress/hubpress.io/commit/ceaca97655fd3a49e4bc057201f0eb7109ad2d4a[0.8.0]).

So far so good. I decided to give it a try.

Process of installation is quite simple - you https://github.com/HubPress/hubpress.io[fork repo],
https://github.com/HubPress/hubpress.io/blob/master/hubpress/config.json[change config file]
and you can start to write a blog posts inside of the administration console.

Nevertheless check https://hubpress.gitbooks.io/hubpress-knowledgebase[knowledgebase to HubPress]
and https://github.com/HubPress/dev.hubpress.io/blob/gh-pages/README.adoc[documentation on GitHub].

...or if you plan to run `HubPress.io` blog against your custom domain these steps could be helpful for you

. Fork repo
** Fork https://github.com/HubPress/hubpress.io[github repository] and set `gh-pages`
https://github.com/HubPress/dev.hubpress.io/blob/gh-pages/README.adoc#use-a-custom-domain-or-github-page-domain-already-in-use[as default one].
** set the `custom domain` field to name of your domain

[NOTE]
====
Having set the `custom domain` will cause creation of `CNAME` file under root
of your github repository.
The content of the file is just the name of your custom domain - thus what you
put to the field.
====

image::hubpressio/githubpages.jpg[]

. change `hubpress/config.json` file to contain (meta)data
** username
** repositoryName
** branch
** cname
in my case it was like this

[source,json]
----
{
"meta": {
"username": "ochaloup",
"repositoryName": "blog.chalda.cz",
"branch": "gh-pages",
"cname": "blog.chalda.cz",
}
}
----

[NOTE]
====
`config.json` file serves to HubPress.io as a configuration file so all settings
that you will set in administration interface will be saved here
====

. When all is set fine you can now go to `HubPress.io` admin page which is
hidden under subaddress `hubpress`. In my case it's at path http://blog.chalda.cz/hubpress.
You need to log in with credentials which you use to login to GitHub. HubPress.io calls
directly the GitHub identification service to confirm that you are the owner of the repo.

. Afte the first login you can see empty screen. That's ok and just create a new article. +
[Updated] for version `0.8.0` it seems that there is already shown information that you have 0 posts so it's not misleading already.

. For https://disqus.com[Disqus] you need short name for your site to be set in HubPress.io.
You will find it when already having page under Discusq when you go `Admin` -> `Settings`
-> choose page -> `General` -> `Shortname`

// TODO: how to add theme...

That's more or less it. Now it's time to write and experiment.


Binary file added static/images/articles/asciidoctor.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/config_maps.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/docker-starter.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/docker-tag.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/docker-to-openshift.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/groovy_straw.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/haproxy_logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/hibernate-standalone.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/maven_plugin.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/minishift-stateful.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/open_shift.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/twelve_labours.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/vim-script.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/articles/wildfly_groovy.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 5b6f798

Please sign in to comment.