Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3114784
D3593.id11448.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D3593.id11448.diff
View Options
diff --git a/services/docker-compose.yml b/services/docker-compose.yml
--- a/services/docker-compose.yml
+++ b/services/docker-compose.yml
@@ -3,6 +3,7 @@
services-net:
name: services-net
services:
+ # tunnelbroker
tunnelbroker-server:
build:
dockerfile: services/tunnelbroker/Dockerfile
@@ -38,6 +39,7 @@
- "${COMM_SERVICES_PORT_BACKUP}:50051"
volumes:
- $HOME/.aws/credentials:/root/.aws/credentials:ro
+ # blob
blob-server:
networks:
- services-net
@@ -53,3 +55,14 @@
- "${COMM_SERVICES_PORT_BLOB}:50051"
volumes:
- $HOME/.aws/credentials:/root/.aws/credentials:ro
+ # identity
+ identity-server:
+ networks:
+ - services-net
+ build:
+ dockerfile: services/identity/Dockerfile
+ context: ../
+ image: commapp/identity-server:0.1
+ container_name: identity-server
+ ports:
+ - "${COMM_SERVICES_PORT_IDENTITY}:50051"
diff --git a/services/identity/Dockerfile b/services/identity/Dockerfile
new file mode 100644
--- /dev/null
+++ b/services/identity/Dockerfile
@@ -0,0 +1,27 @@
+FROM rust:1.57
+
+# Create a new user comm and use it to run subsequent commands
+RUN useradd -m comm
+USER comm
+
+WORKDIR /app/identity
+RUN cargo init --bin
+
+COPY services/identity/Cargo.toml services/identity/Cargo.lock ./
+
+# Cache build dependencies in a new layer
+RUN cargo build --release
+RUN rm src/*.rs
+
+COPY services/identity .
+
+# Remove the previously-built binary so that only the application itself is
+# rebuilt
+RUN rm ./target/release/deps/identity*
+
+# The build.rs script depends on rustfmt
+RUN rustup component add rustfmt
+
+RUN cargo build --release
+
+CMD ["./target/release/identity"]
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Nov 1, 8:41 PM (22 h, 16 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2400490
Default Alt Text
D3593.id11448.diff (1 KB)
Attached To
Mode
D3593: [services][identity] Dockerfile for the identity service
Attached
Detach File
Event Timeline
Log In to Comment