Setup Mariadb via Docker With Spring Boot

Setup Mariadb via Docker With Spring Boot
How to run MariaDB inside Docker and connect to it with Spring Boot Docker with MariaDB We’ll use yobasystems/alpine-mariadb, a lightweight container image using the open-source MariaDB as MySQL alternative. Here’s the docker command: docker run --name mariadb -p 33067:3306 -v /var/lib/mysql:/var/lib/mysql -e MYSQL_ROOT_PASSWORD=root_pass -d yobasystems/alpine-mariadb The command will create a container named mariadb with a root password (root_pass). You can connect to the database via localhost on port 33067.
Read more →

Deploy to GitHub Pages Without Jekyll

Deploy to GitHub Pages Without Jekyll
I’m part of a community of self-taught developers. I’m trying to help tech newbies in the discord channel. Judging from the number of questions, new developers seem to have problems deploying static websites to GitHub pages. In this article, I’ll show you a basic way to bring your first front-end projects to life on GitHub pages. Prerequisites On your computer: Git Node.js You’ll also need a free GitHub account.
Read more →

Free Pushbullet Alternative With Gotify on Heroku

Free Pushbullet Alternative With Gotify on Heroku
image from the Gotify website You have several devices and you want to receive notifications from your Android phone to your web browser (or vice versa). Maybe you also want to send notifications via REST API. You are a developer after all. You can think of interesting ways to send notifications. Pushbullet comes to mind, but you don’t want to sign up with Google or Facebook. You don’t want to use Google services.
Read more →

Functions as a Service With SSL Using OpenFaaS, Docker Swarm, Traefik 2 and a Socket Proxy

Functions as a Service With SSL Using OpenFaaS, Docker Swarm, Traefik 2 and a Socket Proxy
Self-deployed FaaS with Docker Swarm Serverless is all the rage right now. Instead of maintaining a server and its infrastructure, you can create self-contained functions that do the job. This can be a boon for front-end developers. A bespoke front-end client written in React.js or another framework can easily be enhanced with back-end code. It’s now trivial to add a secure integration with a payment provider like Stripe.
Read more →

Traefik 2 Docker Swarm Setup With Docker Socket Proxy and More

Traefik 2 Docker Swarm Setup With Docker Socket Proxy and More
Advanced Traefik 2 Setup with Docker Swarm, SSL Certificates and Security Options Traefik is an open-source router and load-balancer that sits in front of your web services. You can set it up to automatically encrypt your websites with SSL certificates. It’s also easy to add new web services to an existing Traefik cluster. I discovered Traefik via Jakub Svehla’s post Building a Heroku-like infrastructure for $5 a month. He shows you how to use Docker to install a Traefik infrastructure on a cheap VPS like DigitalOcean.
Read more →

Hello World From Flask With Hylang (using Docker)

Hello World From Flask With Hylang (using Docker)
(image by @mamihery) Why Hy? My second programming language was a Lisp. I fell in love with the expressiveness of Lisps. But most Lisps are obscure. The ecosystem is not suited for beginners. One of younger Lisps, Clojure, was my first foray into the world of web-development. I failed spectacularly because I didn’t know how web-develoment worked, and the Clojure ecosystem assumes too much previous knowledge. Other languages, e.g., Racket, are more approachable, but are still too unpopular to have a big community.
Read more →

How to Deploy a Deno Docker Container to Heroku

The Zero To Mastery Deno Course deploys a Deno docker container to Amazon EC2. The EC2 instances cost money after you’ve exhausted your free 12 months. Plus, Amazon’s cloud services can be tricky. Sometimes, services spike. You quickly exceed your free tier, even for a simple toy app. Let’s deploy Deno to Heroku instead. Heroku’s free tier stays free regardless of usage. The free level is slow, because it will periodically stop to save resources.
Read more →

Learn Nim: Create a README Template Downloader

Create a command-line tool which downloads a README template for your coding projects Why Nim? Nim is a statically typed systems programming language. Nim generates small, native dependency-free executables. The language combines a Python-like syntax with powerful features like meta-programming. Nim supports macOS, Linux, BSD, and Windows. The language is open-source and has no corporate affiliation. Nim compiles to multiple backends, for example, C, C++, or JavaScript. The ecosystem and community are small, but the language has reached its first stable release.
Read more →

Move To Hugo With Netlify

I’ve moved this blog from Gatsby.js to Hugo. My build times have gone down from more than 7 minutes to a few seconds! The slow build times with Gatsby have been an ongoing concern for me. I’ve slowly been creeping towards Netlify’s free 300-minutes-build-time cap. Hugo runs a magnitude faster, and it integrates well with Netlify. Hugo is a static site generator built with Golang. The project’s selling points are incredible speed, ease of use, and the ability to configure tons of settings.
Read more →

How To Create a Music Player in Reason With The useContext Hook Part 4

UPDATE: ReasonML + BuckleScript is now Rescript. As the ecosystem has changed around those tools, this blog post is not accurate anymore. We’ve come quite far with our music player in ReasonReact. We created a React Context with state, a hook to manage the Context, and we started with our UI. In this post, we will create a component for the music player control buttons, and we will finally implement the functionality to play the track via the DOM API.
Read more →

How To Create a Music Player in Reason With The useContext Hook Part 3

UPDATE: ReasonML + BuckleScript is now Rescript. As the ecosystem has changed around those tools, this blog post is not accurate anymore. Our goal is to create a music player with ReasonReact like this one: ☞ Demo. James King wrote the JavaScript version of the tutorial at upmostly. My blog post series is a port of the tutorial to ReasonML and ReasonReact. I encourage you to check out the original JavaScript tutorial if you’re unsure about how useContext works.
Read more →

How To Create a Music Player in Reason With The useContext Hook Part 2

UPDATE: ReasonML + BuckleScript is now Rescript. As the ecosystem has changed around those tools, this blog post is not accurate anymore. In the last post, we set up our project: a music player with useContext in ReasonReact. You can find the demo on GitHub pages and the full code on GitHub. The tutorial is a port from the React tutorial How to Use the useContext Hook in React by James King.
Read more →

How To Create a Music Player in Reason With The useContext Hook Part 1

UPDATE: ReasonML + BuckleScript is now Rescript. As the ecosystem has changed around those tools, this blog post is not accurate anymore. What Are We Building? This tutorial will show you how to build a music player with ReasonReact and the useContext hook. You will learn how to bootstrap a ReasonReact project, how to build a simple application, and how to use hooks with ReasonReact. ☞ View Demo Why ReasonML and ReasonReact?
Read more →

Learning ReasonReact Step by Step Part: 9

UPDATE: ReasonML + BuckleScript is now Rescript. As the ecosystem has changed around those tools, this blog post is not accurate anymore. In the last post, we finally finished the custom useForm hook. You can see the code on GitHub. Use The Custom Hook Let’s switch to our main form component: scr/Form.re. We need to connect the component to our custom hook. /* src/Form.re */ [@react.component] let make = (~formType) => { let logger = () => Js.
Read more →

Learning ReasonReact Step by Step Part: 8

We set up our form validation rules, tackled state management and most of the logic. Now, we have to hook up our validation logic with the form. Each time a user types into the form, we want to update our validation rules immediately. We can then display the form validation status and give feedback to the user. The user should only be allowed to submit the form if all rules are valid.
Read more →

Learning ReasonReact Step by Step Part: 7

UPDATE: ReasonML + BuckleScript is now Rescript. As the ecosystem has changed around those tools, this blog post is not accurate anymore. What We’ve Done So Far We’ve laid the groundwork for adding form validation to our app. We defined our types; we have a simple form and a functioning useForm custom hook in a separate module. Create Form Rules And State Management Let’s define our validation rules1. /* inside UseForm.
Read more →

Learning ReasonReact Step by Step Part: 6

UPDATE: ReasonML + BuckleScript is now Rescript. As the ecosystem has changed around those tools, this blog post is not accurate anymore. What We’ve Done So Far So far, we’ve created a simple ReasonReact form with a custom useForm hook and client-side routing. The custom hook uses a useReducer to handle state and transitions. The state is a Reason Record, a type-safe immutable “object.” We first define a type for this record, then we create the initial state:
Read more →

Learning ReasonReact Step by Step Part: 5

UPDATE: ReasonML + BuckleScript is now Rescript. As the ecosystem has changed around those tools, this blog post is not accurate anymore. Our reusable Form component works, but we don’t have any routing. How can we navigate to our two forms (register and login)? Enter ReasonReact Router It’s a breeze to set up the inbuilt ReasonReact Router. My forays into the world of React Router have been far more painful.
Read more →

Learning ReasonReact Step by Step Part: 4

UPDATE: ReasonML + BuckleScript is now Rescript. As the ecosystem has changed around those tools, this blog post is not accurate anymore. So far, we’ve created a simple form component with a useReducer hook. This form works with an email and a password - it could be a login form. But what if we would like to use the same logic to create a register form, too? Make The Form Component Re-Usable With a Custom Hook We know the shape of our data: we have three form fields: email, password, and username.
Read more →

Learning ReasonReact Step by Step Part: 3

UPDATE: ReasonML + BuckleScript is now Rescript. As the ecosystem has changed around those tools, this blog post is not accurate anymore. In my last post I tried to create a custom hook function for React forms. That didn’t work as I expected. Some kind folks helped me out and gave me some suggestions. Let’s pivot and try something different. Instead of creating a custom hook, I’ll take a step back and add the logic to the Form component.
Read more →

Learning ReasonReact Step by Step Part: 0

UPDATE: ReasonML + BuckleScript is now Rescript. As the ecosystem has changed around those tools, this blog post is not accurate anymore. My goal is to learn more in public, so that it also may help others. I’ve given ReasonReact a first try. I’ve read a bit of the documentation, took a peek into Exploring ReasonML, and found some useful blog posts. Let’s try to build a form in Reason React!
Read more →

How to Build a Markdown Preview App With Reagent

Why ClojureScript? With React, you build small components and combine them. You design from data and then flow it through functions (and React classes). You start with the programming logic. You then add your UI with HTML-like syntax (JSX). I enjoy the data-centric approach. It also powers the core of Clojure and ClojureScript. I hate Javascript’s verbose syntax. Don’t get me started on the object model and the pitfalls of this.
Read more →

Tutorial: Clojurescript App With Reagent For Beginners, Part 2

This is part 2 of my Clojurescript Reagent Tutorial. In part 1 we created a simple random quote app that displays quotes from the TV-series “Breaking Bad”. Here is the live demo: Breaking Bad Quotes. And here is the Github Repo, so you can see the whole code (minus the sensitive login details for Firebase): Github. Now it’s time to deploy it. We will use Google Firebase for that, just to learn on how to do it.
Read more →

Tutorial: Clojurescript App With Reagent For Beginners, Part 1

Learning to code takes practice and building projects. So, here is how to build a simple “Random Quote Machine” with Clojurescript and Reagent. Hopefully, you’ll get a sense on how Clojurescript and Reagent work. Here is the live demo: Breaking Bad Quotes. And here is the Github Repo, so you can see the whole code: Github. The app displays a quote from the “Breaking Bad” TV series with its author. You can click on a button to get a new quote.
Read more →

Sign up for the newletter!

powered by Buttondown