• Home

  • Custom Ecommerce
  • Application Development
  • Database Consulting
  • Cloud Hosting
  • Systems Integration
  • Legacy Business Systems
  • Security & Compliance
  • GIS

  • Expertise

  • About Us
  • Our Team
  • Clients
  • Blog
  • Careers

  • VisionPort

  • Contact
  • Our Blog

    Ongoing observations by End Point Dev people

    Comparison of Lightweight CSS Frameworks

    Seth Jensen

    By Seth Jensen
    January 13, 2022

    The frame of a house in front of a mountain range

    Several months ago I was building a new website and needed a CSS framework. There are many new CSS frameworks around now, so I decided to do several small trial runs and compare them to find the most fitting for our site.

    Initially I tried using Foundation, which this site is built on, but I ran into a problem: Foundation and other popular frameworks are powerful, but they have more features than I needed, and they take up too much disk space for a modest website. Foundation is about 6000 lines long and 200kB unminified. It can be shrunk by removing components you don’t need, but the time it takes to slim a large CSS framework down to your needs can be more than it’s worth, especially if you want to change any styling.

    Instead of adapting a larger framework to my needs, I looked into lightweight CSS frameworks. These aim to provide boilerplate components, better styling for buttons, forms, tables, and the like, all at the cost of very little disk space.

    I like to modify the source CSS as needed, so all of the sizes I list will be unzipped and unminified. They are also from my brief real-world testing on one machine, so your mileage may vary.

    Bulma

    Bulma looked very …


    css design

    Database integration testing with .NET

    Kevin Campusano

    By Kevin Campusano
    January 12, 2022

    Sunset over lake in mountains

    Ruby on Rails is great. We use it at End Point for many projects with great success. One of Rails’ cool features is how easy it is to write database integration tests. Out of the box, Rails projects come with all the configuration necessary to set up a database that’s exclusive for the automated test suite. This database includes all the tables and other objects that exist within the regular database that the app uses during its normal execution. So, it is very easy to write automated tests that cover the application components that interact with the database.

    ASP.NET Core is also great! However, it doesn’t have this feature out of the box. Let’s see if we can’t do it ourselves.

    The sample project

    As a sample project we will use a REST API that I wrote for another article. Check it out if you want to learn more about the ins and outs of developing REST APIs with .NET. You can find the source code on GitHub.

    The API is very straightforward. It provides a few endpoints for CRUDing some database tables. It also provides an endpoint which, when given some vehicle information, will calculate a monetary value for that vehicle. That’s a feature that would …


    dotnet integration database testing docker containers

    On the Importance of Explicitly Converting Strings to Numbers

    Jeff Laughlin

    By Jeff Laughlin
    January 11, 2022

    Wall with tiles of 4 colors in a pattern

    Recently a valued colleague approached me with a JavaScript problem. This individual is new to programming and is working on a self-taught course.

    The assignment was fairly simple: Take a list of space-delimited integers and find the maximum and minimum values. If you are an experienced developer you can probably already guess where this is going. His code:

    function highAndLow(numbers) {
      const myArr = numbers.split(" ");
      let lowNum = myArr[0];
      let highNum = myArr[0];
      for (let i = 0; i < myArr.length; i++) {
        if (myArr[i] > highNum) {
          highNum = myArr[i];
        } else if (myArr[i] < lowNum) {
          lowNum = myArr[i];
        }
      }
      return highNum + ' ' + lowNum;
    }
    
    console.log(highAndLow("8 3 -5 42 -1 0 0 -9 4 7 4 -4"));
    

    This produced the output:

    "8 -1"
    

    These are clearly not the maximum or minimum values.

    After looking at it for a few moments I recognized a classic JavaScript pitfall: failure to explicitly convert stringy numbers to actual number types.

    You see, JavaScript tries to be clever. JavaScript tries to get it right. JavaScript tries to say “the thing you are doing looks like something that you would do with numbers so …


    programming javascript typescript

    Kubernetes 101: Deploying a web application and database

    Kevin Campusano

    By Kevin Campusano
    January 8, 2022

    Groups of birds on a telephone pole

    The DevOps world seems to have been taken over by Kubernetes during the past few years. And rightfully so, I believe, as it is a great piece of software that promises and delivers when it comes to managing deployments of complex systems.

    Kubernetes is hard though. But it’s all good, I’m not a DevOps engineer. As a software developer, I shouldn’t care about any of that. Or should I? Well… Yes. I know that very well after being thrown head first into a project that heavily involves Kubernetes, without knowing the first thing about it.

    Even if I wasn’t in the role of a DevOps engineer, as a software developer, I had to work with it in order to set up dev environments, troubleshoot system issues, and make sound design and architectural decisions.

    After a healthy amount of struggle, I eventually gained some understanding on the subject. In this blog post I’ll share what I learned. My hope is to put out there the things I wish I knew when I first encountered and had to work with Kubernetes.

    So, I’m going to introduce the basic concepts and building blocks of Kubernetes. Then, I’m going to walk you through the process of containerizing a …


    kubernetes docker dotnet postgres containers

    Fixing a PostgreSQL cluster that has no superuser

    Jon Jensen

    By Jon Jensen
    January 7, 2022

    Stone building with arched windows, a tower, steps leading up, and lush lawn, flowers, and trees

    Normally in a newly-created PostgreSQL database cluster there is a single all-powerful administrative role (user) with “superuser” privileges, conventionally named postgres, though it can have any name.

    After the initial cluster setup you can create other roles as needed. You may optionally grant one or more of your new roles the superuser privilege, but it is best to avoid granting superuser to any other roles because you and your applications should generally connect as roles with lower privilege to reduce the risk of accidental or malicious damage to your database.

    Let’s break something 😎

    Imagine you have a cluster with two or more superuser roles. If you accidentally remove superuser privilege from one role, you can simply connect as the other superuser and re-grant it.

    But if you have a cluster where only the single postgres role is a superuser, what happens if you connect as that role and try to remove its superuser privilege?

    $ psql -U postgres postgres
    psql (14.1)
    Type "help" for help.
    
    postgres=# \du
                           List of roles
     Role name |            Attributes             | Member of …

    postgres security tips

    Setting up SSH in Visual Studio Code

    Couragyn Chretien

    By Couragyn Chretien
    January 6, 2022

    View of Grand Canyon

    Visual Studio Code is a powerful code editor that can create a customized IDE for your development. VS Code’s default configuration is great for working locally but lacks the functionality to give the same experience for remote SSH development. Enter the extension Remote SSH.

    Installation

    Remote SSH in Visual Studio Code Marketplace

    Installing the Remote SSH extension is really easy! First you access the Extension Marketplace with Ctrl+Shift+X or by clicking View > Extensions in the menu, then you just search for and select Remote - SSH.

    Setting up your SSH config file

    To configure your connection, you’ll need to add a few lines to your SSH config. Click the green Open a Remote Window icon on the bottom left corner:

    Open Remote Window

    Select Open SSH Configuration File... and select the config file you want to use. I use the Linux default, /home/$USER/.ssh/config. Add the Host, HostName, and User as required and save:

    Host MySite
      HostName site.endpointdev.com
      User couragyn
    

    Connecting

    Click the green Open a Remote Window icon on the bottom left corner, select Connect to Host..., and pick your desired host, in this case MySite. If your public SSH key isn’t on the remote server, you will be prompted to enter a …


    ssh tips vscode

    Word diff: Git as wdiff alternative

    Jon Jensen

    By Jon Jensen
    January 5, 2022

    5 drinking fountains mounted on a wall at varying levels

    The diff utility to show differences between two files was created in 1974 as part of Unix. It has been incredibly useful and popular ever since, and hasn’t changed much since 1991 when it gained the ability to output the now standard “unified context diff” format.

    The comparison diff makes is per line, so if anything on a given line changes, in unified context format we can tell that the previous version of that line was removed by seeing - at the beginning of the old line, and the following line will start with + followed by the new version.

    For example see this Dockerfile that had two lines changed:

    $ diff -u Dockerfile.old Dockerfile
    --- Dockerfile.old	2022-01-05 22:16:21 -0700
    +++ Dockerfile	2022-01-05 23:08:55 -0700
    @@ -2,7 +2,7 @@
     
     WORKDIR /usr/src/app
     
    -# Bundle app source
    +# Bundle entire source
     COPY . .
     
    -RUN /usr/src/app/test.sh
    +RUN /usr/src/app/start.sh
    

    That works well for visually reviewing changes to many types of files that developers typically work with.

    It can also serve as input to the patch program, which dates to 1985 and is still in wide use as a counterpart to diff. With patch we can apply changes to a file and avoid the need to send …


    git terminal vscode intellij-idea tips

    Generate PDF with Chrome, Puppeteer, and Serverless Stack

    Afif Sohaili

    By Afif Sohaili
    January 2, 2022

    Cloud Computing and Serverless

    Function as a Service (FaaS) solutions are becoming more and more mainstream today. The FaaS model allows developers to not have to worry about managing infrastructure and instead focus on writing the application logic. In the FaaS model, developers write individual functions that run specific tasks that are deployed together on a FaaS platform, including but not limited to Amazon Web Services (AWS), Azure, and Google Cloud Platform (GCP).

    These functions don’t always run like a traditional application server does, waiting for a request. Instead, these FaaS platforms only spin up instances of these functions whenever there is traffic and will shut them back down once there are no more requests after a given period of time. This helps make FaaS a really cheap platform while traffic is low. It is a good approach for on-demand tasks that are part of the application but not necessarily the most common path in a customer’s everyday journey within the application.

    The tools

    In this tutorial, we’re going to be looking at implementing PDF download with Chrome, Puppeteer, and Serverless Stack, but first, let’s have a brief introduction of the tools that we are …


    automation aws chrome cloud pdf serverless
    Previous page • Page 18 of 217 • Next page