Skip to content

Commit 71a3252

Browse files
committed
Update Docker README
1 parent b5c0ebc commit 71a3252

File tree

1 file changed

+69
-30
lines changed

1 file changed

+69
-30
lines changed

demos/guru_scripts/docker/README.md

Lines changed: 69 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
Overview
2-
=================
1+
# Overview
2+
33
This document provides step-by-step instructions on how to pull the latest TigerGraph Free Trial docker image to your host machine. You can follow the sections in sequence to setup the TigerGraph docker enviroment.
44

55
The latest TigerGraph docker image includes the following content.
@@ -18,8 +18,25 @@ This video shows the whole setup process. https://www.youtube.com/watch?v=V5VvgJ
1818

1919
If you want to customize your own docker image, the last section of this README has instructions on how to accomplish it.
2020

21-
Install Docker Desktop
22-
=========================
21+
# Table of Contents
22+
23+
- [Install Docker Desktop](#install-docker-desktop)
24+
- [Prepare a Shared Folder on Host OS](#prepare-a-shared-folder-on-host-os-shared-with-docker-container)
25+
- [Start TigerGraph Instance](#start-tigergraph-instance)
26+
- [Quick Start for Community Edition](#quick-start-for-community-edition)
27+
- [Download and Import Pre-built TigerGraph Community Edition Image](#download-and-import-pre-built-tigergraph-community-edition-image)
28+
- [Load Sample Database](#load-sample-database)
29+
- [Quick Start for Enterprise Edition](#quick-start-for-enterprise-edition)
30+
- [Getting a License Key](#getting-a-license-key-no-need-if-using-community-edition)
31+
- [Pull Pre-built TigerGraph Docker Image And Run It As A Server](#pull-pre-built-tigergraph-docker-image-and-run-it-as-a-server)
32+
- [Operation Commands Cheat Sheet](#operation-commands-cheat-sheet)
33+
- [Documents and Forum](#documents-and-forum)
34+
- [Build your own Docker Image](#build-your-own-docker-image)
35+
36+
37+
# Install Docker Desktop
38+
----
39+
2340
1. Install Docker on your OS (choose one)
2441
- To install Docker for Mac OS, follow this video
2542
https://www.youtube.com/watch?v=MU8HUVlJTEY
@@ -44,8 +61,9 @@ Install Docker Desktop
4461
4. To understand the Docker *Container* and *Image* concepts, watch this video:
4562
https://www.youtube.com/watch?v=Rv3DAJbDrS0
4663

47-
Prepare a Shared Folder on Host OS shared with Docker Container
48-
===============================================================
64+
# Prepare a Shared Folder on Host OS shared with Docker Container
65+
----
66+
4967
Open a shell on your host machine and create or select a directory for sharing data between your host machine and docker container. Grant read/write/execute permission to the folder. For example, to create a folder called data in Linux:
5068

5169
mkdir data
@@ -59,34 +77,39 @@ Suppose we mount the host OS ~/data folder to a docker folder /home/tigergraph/m
5977
Since our dev edition does not support backup/restore data, you can persist your data (raw file, gsql script etc.)
6078
on the data volume. After upgrading Dev version, you can start a new container using the same data volume.
6179

62-
Getting a License Key (Skip If Using Community Edition)
63-
=======================================================
80+
# Start TigerGraph Instance
81+
----
6482

65-
Please note that this package does not include a license key.
83+
The following TigerGraph editions are availble for you to choose:
84+
* Community Edition
85+
* Enterprise Edition
6686

67-
You may obtain a license key by going to [dl.tigergraph.com](https://dl.tigergraph.com/) and clicking on "**Request Free Dev License**" at the top. Fill out the form to receive a license key. Once you have the key, [follow the directions](https://docs.tigergraph.com/tigergraph-server/current/system-management/management-with-gadmin#_manage_licenses) for applying the key.
87+
## Quick Start for Community Edition
88+
----
6889

69-
Currently, the Free Trial limits your database to **50 GB**, and is valid for **30 days** after the date of issue.
90+
### Download and Import Pre-built TigerGraph Community Edition Image
7091

71-
Quick Start for Community Edition
72-
================================
7392
1. Download docker image from https://dl.tigergraph.com/
7493
2. [Optional for enterprise edition] Download trial license key from https://dl.tigergraph.com/, it's a text file containing the Dev license.
7594
3. In Macbook/Linux/Windows command line (# starts a comment) type the following sequence of commands, change the image file name to the one you downloaded.
7695

77-
```python
96+
```shell
7897
docker load -i ./tigergraph-4.2.0-community-docker-image.tar.gz # the xxx.gz file name are what you have downloaded. Change the gz file name depending on what you have downloaded
7998
docker images #find image id
80-
docker run -d --name mySandbox imageId #start a container, name it “mySandbox” using the image id you see from previous command
81-
docker exec -it mySandbox /bin/bash #start a shell on this container.
99+
docker run -d --init -p 14240:14240 --name tigergraph tigergraph/community:4.2.0 #Run a container named tigergraph from the imported image
100+
docker exec -it tigergraph /bin/bash #start a shell on this container.
82101
gadmin start all #start all tigergraph component services
83102
gadmin status #should see all services are up.
84103
```
85-
You are ready to go! Try the [sample financial data](https://github.com/tigergraph/ecosys/blob/master/tutorials/GSQL.md)
104+
You are ready to go!
105+
106+
### Load Sample Database
107+
108+
Try the [sample financial data](https://github.com/tigergraph/ecosys/blob/master/tutorials/GSQL.md)
86109

87110
For the impatient, load the sample data from the tutorial/gsql folder and run your first query.
88111

89-
```python
112+
```shell
90113
cd tutorial/gsql/
91114
gsql 00_schema.gsql #setup sample schema in catalog
92115
gsql 01_load.gsql #load sample data
@@ -100,24 +123,39 @@ For the impatient, load the sample data from the tutorial/gsql folder and run yo
100123
GSQL> exit #quit gsql shell
101124
```
102125
126+
### Access UI Apps
127+
128+
Visit http://localhost:14240 to access the Apps
129+
130+
131+
## Quick Start for Enterprise Edition
132+
----
133+
134+
### Getting a License Key (No Need If Using Community Edition)
135+
136+
Please note that this package does not include a license key.
137+
138+
You may obtain a license key by going to [dl.tigergraph.com](https://dl.tigergraph.com/) and clicking on "**Request Free Dev License**" at the top. Fill out the form to receive a license key. Once you have the key, [follow the directions](https://docs.tigergraph.com/tigergraph-server/current/system-management/management-with-gadmin#_manage_licenses) for applying the key.
139+
140+
Currently, the Free Trial limits your database to **50 GB**, and is valid for **30 days** after the date of issue.
103141
If you download enterprise edition, you need to apply the license before you can start.
104142
```python
105143
gadmin license set the_license_from_step_2_text #copy the license from step 2 file
106144
gadmin config apply #apply the license
107145
```
108146
109-
Pull Pre-built TigerGraph Docker Image And Run It As A Server
110-
================================================================
147+
### Pull Pre-built TigerGraph Docker Image And Run It As A Server
148+
111149
One command pull docker image and bind all ports for first time user from the TigerGraph docker registry.
112150
This image will start as a daemon, so user can ssh to it.
113151
114152
1. pull the latest version, only do this step in shell if you upgrade your docker image
115153
116154
docker pull tigergraph/tigergraph:latest
117155
118-
> Note: replace "latest" with specific version number if a dedicated version of TigerGraph is to be used. E.g. If you want to get 3.6.0 version, the following would be the URL.
156+
> Note: replace "latest" with specific version number if a dedicated version of TigerGraph is to be used. E.g. If you want to get 4.2.0 version, the following would be the URL.
119157
120-
docker pull tigergraph/tigergraph:3.6.0
158+
docker pull tigergraph/tigergraph:4.2.0
121159
122160
> Note:
123161
> * to use the legacy versions, use docker.tigergraph.com/tigergraph:version
@@ -139,11 +177,11 @@ This image will start as a daemon, so user can ssh to it.
139177
- "-v" mount the host OS ~/data folder to the docker /home/tigergraph/mydata folder using the -v option. Note that if you are using windows, change the above ~/data to something using windows file system convention, e.g. c:\data
140178
- download the "latest" docker image from the TigerGraph docker registry url tigergraph/tigergraph.
141179
```bash
142-
docker run -d -p 14022:22 -p 9000:9000 -p 14240:14240 --name tigergraph --ulimit nofile=1000000:1000000 -v ~/data:/home/tigergraph/mydata -t tigergraph/tigergraph:latest
180+
docker run -d --init -p 14022:22 -p 9000:9000 -p 14240:14240 --name tigergraph --ulimit nofile=1000000:1000000 -v ~/data:/home/tigergraph/mydata -t tigergraph/tigergraph:latest
143181
```
144182
Note that if you use Windows, and have disk drive permission issue with the above command, please try the following
145183
```bash
146-
docker run -d -p 14022:22 -p 9000:9000 -p 14240:14240 --name tigergraph --ulimit nofile=1000000:1000000 -t tigergraph/tigergraph:latest
184+
docker run -d --init -p 14022:22 -p 9000:9000 -p 14240:14240 --name tigergraph --ulimit nofile=1000000:1000000 -t tigergraph/tigergraph:latest
147185
```
148186
149187
After pulling the image and launch the container in the background, you can try the following to verify it's running.
@@ -172,8 +210,8 @@ After pulling the image and launch the container in the background, you can try
172210
173211
http://localhost:14240
174212
175-
Operation Commands Cheat Sheet
176-
================================
213+
# Operation Commands Cheat Sheet
214+
----
177215
178216
- After you start Docker Desktop, use the below command to start/stop the container created
179217
@@ -210,8 +248,9 @@ Operation Commands Cheat Sheet
210248
211249
gsql version
212250
213-
Documents and Forum
214-
=====================
251+
# Documents and Forum
252+
----
253+
215254
- Tutorial
216255
217256
https://docs.tigergraph.com/start/gsql-101
@@ -236,8 +275,8 @@ If you like the tutorial and want to explore more, join the GSQL developer commu
236275
https://www.tigergraph.com/webinars-and-events/
237276
238277
239-
Build your own Docker Image
240-
================================
278+
# Build your own Docker Image
279+
241280
To customize the Tigergraph Docker image, e.g., integrate another docker images
242281
1. Create a tigergraph folder
243282
1. Download the [dockerfile](https://github.com/tigergraph/ecosys/blob/master/demos/guru_scripts/docker/dockerfile) shared in this repo to the folder

0 commit comments

Comments
 (0)