It’s been about a year since my last post in this series. Things have – surprise surprise – changed quite a lot in a year, but even if I’d like to update the chosen tech, I’ll mostly use what I originally chose. However, I’ll make a couple of major version updates for the Auth service: Node 6.10.2 -> 8.11.2 Restify 4.3.0 -> 7.2.0 The Shippable node image was also updated to 6.5.4 to get Node 8.11.2 support. Due to the node version update the Dockerfiles for all the components were updated as well. Overall Target As mentioned in the introduction[…]
Web Development
Modern Web Development Setup – Acceptance Testing
Introduction In this article we’ll continue setting up the CI/CD system. We’ll setup Kontena-based acceptance testing environments into UpCloud and configure them into our Shippable CI/CD pipeline. Acceptance Test Environment Setup New Kontena Environment Creation To start with, we’ll create acceptance testing CI (atci) and acceptance testing environments. The atci environment is meant for running automated acceptance tests and the acceptance testing environment is meant for manual acceptance testing:
1 2 3 |
$ kontena grid create atci $ kontena upcloud node create --grid atci --username <upcloud_username> --password <upcloud_password> --ssh-key ~/.ssh/id_rsa_upcloud.pub --zone de-fra1 |
1 2 3 |
$ kontena grid create acceptance-testing $ kontena upcloud node create --grid acceptance-testing --username <upcloud_username> --password <upcloud_password> --ssh-key ~/.ssh/id_rsa_upcloud.pub --zone de-fra1 |
We’ll follow the setup according to the test environment setup in previous articles. We’ll set up the acceptance testing environments under at. and atci. subdomains. Before integrating the environments with[…]
Modern Web Development Setup – The Testing Environment (2/2)
Test Strategy for the Authentication Service I come from the embedded software world where out-of-the-box solutions rarely exist, and setting up proper acceptance or integration test environments usually requires physical devices and quite a bit of in-house software to get everything working. Compared to that, the web development world is quite different with various available testing services and tools which make the high level system testing possible with much less resources. Based on various web discussion forums and blogs it seems that the testing is seen as a crucial part of the web development, and test automation is highly recommended. One of the[…]
Modern Web Development Setup – The Testing Environment (1/2)
Testing and Deployment Overview Before setting up the needed environments, it’s good to define the high level targets. The general idea in this setup is to make the deployments and testing automated where feasible, yet keep the system simple enough to implement and maintain. The target is to set up the system in such a way that acceptance testing and production environment updates are triggered manually even if the deployments are automated. Development Environment The local development environment is where the development is done. Created pull-requests, merges and other actions trigger jobs for the CI system. Version Control System The version control system keeps track[…]
Modern Web Development Setup – The Local Development Environment
Alrighty, time to get something concrete done! But let’s check a few things before creating the first versions of the service components. Conventions, Practices & Configurations Coding Conventions I’m using Atom code editor and ESLint with Airbnb’s React coding conventions. There are other convention alternatives also available, but with I’ve been happy with these after a few minor modifications. The setup is needed for Front, App and Auth Services. In macOS the following commands in terminal will do the magic and install the module along with needed dependencies:
1 2 3 4 5 |
( export PKG=eslint-config-airbnb; npm info "$PKG@latest" peerDependencies --json | command sed 's/[\{\},]//g ; s/: /@/g' | xargs npm install --save-dev "$PKG@latest" ) |
For Atom, linter, linter-eslint and language-babel packages provide the needed features – and the default language-javascript package[…]
Modern Web Development Setup – Introduction
Foreword I used to be a hobby php developer back in the days when I was a student, but for the last 10 years I’ve mostly worked in the embedded software scene. Last year I started working as a contractor web developer and I’ve been learning and working with web technologies ever since. With this background I’ve been learning and finding out what are the best ways to build web services these days and what tools and processes are effective for getting things done. There is a huge amount of information available in the web, but few articles offer more than bits and pieces[…]