關於網路那些事...

Marketing, SEO, Web trends, Programming tutorial, Web design, and Life event...

Flutter - How to solve VSCode not show iOS simulator device

When running Xcode and iOS simulator, open VSCode does not show the iOS device but has Android emulator options.

How to show iOS simulator in VSCode?

Continue Reading

Flutter - How to solve the error of Unable to load asset for local images

Why unable to load asset for local images and how to load local images

How to solve the problem of “another exception was thrown: Unable to load asset:” in flutter?

Here is the step for flutter how to load local images:

First, for use asset image in local, image location should be add in pubsec.yaml

Continue Reading

Getting start with Dart before Flutter

Flutter tutorial: Getting start with Dart

Dart is created by Google in 2011, and can be use for web, server, mobile, and IoT, also can be use to develop Flutter.

Here we will present a quickly short guid for let you understand what is Dart and how to use it. For more detail about Dart can reference tour of basic Dart program.

Continue Reading

Install flutter in mac and build first project

This tutorial will demonstrate how to install flutter in Mac and build the first app with Xcode.

To install flutter and develop the app, we need to check environment meet minimum requirements

  • Disk space: 2.8 G
  • macOS 64-bit
  • Xcode

Continue Reading

How to customerize the Live Sass Compiler settings for CSS output path and formats

In Visual Studio Code, I’m using the Live Sass Compiler and Live Server (both plugins are developed by Ritwick Dey) for the development HTML project.

After install Live Sass compiler and Liver Server, the quickly functional button “Watch Sass” and “Go Live” will show in the VSCode bottom status list.

Continue Reading

How download videos or live streaming from Azure Media Service content

Here is a tutorial for download video or streaming from Azure Media Service content.

Azure Media Player provides one player to support multiple devices and formate and integration content protection.

Azure media service is provided a stream solution with Azure Media Player, Azure media service is using manifest as streaming info contains the file.

When we need to download content from Azure media, first, we need to get the manifest URL,

Continue Reading

Golang - Using Cobra to build your CLI Application

Cobra is a golang library for creating CLI applications and is using by Kubernetes, Hugo, and Github CLI..

Here we will show how to use cobra to build a CLI app.

Continue Reading

Golang - Get Global Environment Variable From Bash Profile (~/.bash_profile)

In golang project, we may need to call os environment variable for security purposes in OSX or Linux.

Here will showing how to set global environment and get value in our golang project.

Continue Reading

Golang Tutorial : Introduction Gin HTML template and how integration with bootstrap

Introduction Gin HTML template and how integration with bootstrap

Gin is going web framework which include server-side render template, we can transfer variable into a template and render by double braces {{ … }}.

In this article, We will introduce how to use gin template, finally will include how to integrate bootstrap with gin HTML template.

Continue Reading

Github Action Auto Ssh to Host and Execute Script

Github action use SSH to access remote host and execute a script In this article, we will use 6 steps to illustrate how to use Github action to access a remote server and execute the shell script.

Continue Reading

理解 Python package & module 入門 - Getting Start With Python Module

理解 Python package & module 入門 Python 簡單易學,並且 Python 扮演了非常好的膠水的角色,將大量功能強的大模組整合在一起,讓他成為如今火熱的程式碼。 在這裡主要會說明 Package, Module 的組成。 首先聊聊 Module 在 python 來說,我們主要都會透過 module 來將建構我們的程式碼,一個 module 簡單來說,就是一個 .py 檔案。 ├── mymodule.py 例如,建立一個 saymodule.py class sayHello(): name = '' message = 'hello world' def To(self): if self.

Continue Reading

Amazon VPC 基礎知識介紹

Amazon VPC 基礎知識介紹

AWS 會在世界許多區域建立基礎設施,每一個 Region 就可以代表一個區域(例如,東京),在 Region 中,通常會有多個 AZ (Ability Zone),一個 AZ 是一個邏輯資料中心,這裡面會有多個實體資料中心。

Amazon 的 VPC (Virtual Private Cloud ) 是一個虛擬的網路區域,他是私有的會與其他帳號隔離的虛擬網路,可以將 AWS 的服務資源在 Virtual networks 中運行(也可以說,每一個實例資源創建時,就必須指定 VPC 及 subnets ),這些服務之間可以透過 VPC 網路來溝通,在雲端與本地環境無縫接軌,或者在雲端建立起一套私有的網路環境架構。

在接下來會透過幾個部分來階段是的說明 VPC 概念:

Continue Reading

Mac 安裝 Logstash 及啟用

Mac 安裝 Logstash 及啟用

Mac 安裝 Logstash 及啟用

本篇說明如何在 Mac 本地建立 Logstash 流程,其他 Linux 相關主機原則上僅差別在安裝步驟,可直接跳到功能設定參考:

Continue Reading

Elastic Cloud - Kibana 入門介紹

Elastic Cloud - Kibana 入門介紹

Elastic Cloud - Kibana 入門介紹

Kibana 是一個資料數據展示的系統,一般會用來管理 Elasticsearch 數據分析。在這裡我們會介紹如何在 Elastic Cloud 建立集群,如何啟動 Kibana 及配置說明,以及相關功能介紹。

Continue Reading

Terraform 安裝與運行

Terraform 安裝與運行

Terraform 安裝與運行

Terraform 是由 HashiCorp 開發的一套 Infrastructure as Code 工具。

這裡記錄 Terraform 基本安裝及設定的步驟,示範如何在 GCP 建立一個 instance。

Continue Reading

GCP 佈建 Kubernetes 入門 - 使用 Kubernetes Engine

GCP 佈建 Kubernetes 入門 - 使用 Kubernetes Engine

GCP 佈建 Kubernetes 入門 - 使用 Kubernetes Engine

在這裡記錄如何從 GCP 建立起 Kubernetes Engine 建立起 cluster 流程:

Continue Reading

Ansible 配置管理與部署入門

Ansible 配置管理與部署入門

Ansible 配置管理與部署入門

簡介

Ansible 是一個開源的系統自動化工具,擁有配置系統,任務排程,可以透過代碼來管理我們的infra,可以進階設計出一些 CI/CD 流程等功能。Ansible 預設使用 SSH 來進行遠端主機管理,Ansible 1.3 之後的版本可以透過本地的 OpenSSH 與遠端的主機進行通訊,如果是在比較老舊的作業系統,則會採取 paramiko 的相對應做法。

Continue Reading

Kubernetes (K8S) - Mac 本地執行練習上手 如何用 K8S 快速佈建一個 Go Server

Kubernetes (K8S) - Mac 本地執行練習上手 如何用 K8S 快速佈建一個 Go Server

Kubernetes (K8S) - Mac 本地執行練習上手 如何用 K8S 快速佈建一個 Go Server

如何在 Mac 本地快速透過 K8S 啟用一個服務,這裡以一個簡易的 go server 為例子,一步步來說明如何啟動。

Continue Reading

Elasticsearch Mapping 原理及範例說明

Elasticsearch Mapping 原理及範例說明

Elasticsearch Mapping 原理及範例說明

Mapping 類似於資料庫中的 schema,主要的作用如下:

  • 定義類型 (bool, string, num…)
  • 設定屬性倒排索引

在 Elasticsearch 數據產生時,其實都自動進行 mapping,但有時如果有特別的業務需求,則可以自行設定 mapping ,

特別提醒!如果特別需求,請在一開始就建立好 Mapping,因為Mapping建立後,就不能修改。

Continue Reading

Elasticsearch Analyzer 分詞器是什麼,以及日語搜尋 token filter 簡介

Elasticsearch 分詞器是什麼?

Elasticsearch Analyzer 分詞器是什麼,以及日語搜尋 token filter 簡介

Analysis 是 Elasticsearch 的一個概念,他可以將我們數據 寫入及查詢時,也會針對分詞做處理。

這些 analysis 的概念主要是由 Analyzer(分詞器) 來處理,主要做的事情包含:

Continue Reading