1
- Create your own pydyna-pre service docker container
2
- ===================================================
1
+ Build pydyna-pre service docker container
2
+ :::::::::::::::::::::::::::::::::::::::::
3
3
4
4
The pydyna-pre service Docker containers can be easily built by following
5
5
these steps.
6
6
7
- Inside this folder, the instructions (i.e. ``Dockerfile `` files) for
8
- building the pydyna-pre service Docker containers are made available.
7
+ To build the docker image you will need to clone pydyna repo locally:
9
8
10
- * ``Dockerfile ``: this file builds the Linux-based Docker image.
9
+ .. code :: console
10
+
11
+ git clone https://github.com/pyansys/pydyna.git
12
+ cd pydyna
13
+
14
+ * ``docker/pre/Dockerfile ``: this file builds the Linux-based Docker image.
11
15
12
16
Prerequisites
13
17
^^^^^^^^^^^^^
14
18
15
19
* Ensure that ``docker `` is installed in your machine.
16
20
If you do not have ``docker `` available, please refer to the
17
21
`official Docker site <https://www.docker.com >`_.
18
- Note that the container can also be started on Windows if the Docker Desktop has been installed.
19
- How to install the Docker Desktop: https://docs.docker.com/desktop/install/windows-install/
20
22
21
- * Download the latest release artifacts. You can do this as follows:
23
+ * Download the latest release artifacts for the Linux
24
+ Docker container. You can do this as follows:
22
25
23
26
* Latest Linux artifacts: `linux-binaries.zip <https://github.com/ansys/pydyna/releases/download/v0.2.1/linux-binaries.zip >`_
24
27
25
- * Move these ``.zip `` files to the current location (i.e. ``<repository-root-folder>/docker/pre ``).
26
-
27
- Starting the docker container
28
- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
29
-
30
- There are two ways to start docker container.
31
-
32
- 1.bulid image and run container
33
- >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
28
+ * Move these ``.zip `` files to the current location (i.e. ``<repository-root-folder>/docker ``).
34
29
35
30
Building the Docker images
36
- ::::::::::::::::::::::::::
31
+ ^^^^^^^^^^^^^^^^^^^^^^^^^^
37
32
38
33
In order to build your images, follow the next instructions:
39
34
40
- * Locate yourself at ``<repository-root-folder>/docker/pre `` in your terminal.
35
+ * Locate yourself at ``<repository-root-folder>/docker `` in your terminal.
41
36
* Run the following Docker command:
42
37
43
38
.. code :: bash
@@ -61,13 +56,13 @@ In order to build your images, follow the next instructions:
61
56
>>> ...... ...... ............ .............. ......
62
57
63
58
Run the image as a container
64
- ::::::::::::::::::::::::::::
59
+ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
65
60
66
61
* Run the following Docker command:
67
62
68
63
.. code :: bash
69
64
70
- docker run -d -p 50051:50051 ghcr.io/ansys/ls-pre
65
+ docker run -d -p 50051:50051 ghcr.io/ansys/ls-pre .
71
66
72
67
* Check that the image has been created successfully.
73
68
@@ -76,19 +71,4 @@ Run the image as a container
76
71
77
72
78
73
>>> CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
79
- >>> c77ffd67f9fa ghcr.io/ansys/ls-pre " python3 ./linux-bin…" 7 seconds ago Up 7 seconds 0.0.0.0:50051-> 50051/tcp, :::50051-> 50051/tcp hardcore_margulis
80
-
81
-
82
- 2.Start the container from docker-compose.yml file
83
- >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
84
-
85
- Make sure the docker compose have been installed on your computer.
86
- For more information: https://docs.docker.com/compose/install/
87
-
88
- * Locate yourself at ``<repository-root-folder>/docker/pre `` in your terminal.
89
- * Run the following Docker command:
90
-
91
- .. code :: bash
92
-
93
- docker compose up -d
94
-
74
+ >>> c77ffd67f9fa ghcr.io/ansys/ls-pre " python3 ./linux-bin…" 7 seconds ago Up 7 seconds 0.0.0.0:50051-> 50051/tcp, :::50051-> 50051/tcp hardcore_margulis
0 commit comments