generated from DAM/ts-TEMPLATE
day0-untested
This commit is contained in:
49
README.md
49
README.md
@@ -1,8 +1,8 @@
|
|||||||
# {{Service}} with Tailscale Integration
|
# Immich Machine Learning with Tailscale Integration
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
This project sets up a {{Service}} instance with Tailscale VPN integration using Docker Compose. It creates a secure, private network connection for your {{Service}} instance using Tailscale.
|
This project sets up a Immich Machine Learning instance with Tailscale VPN integration using Docker Compose. It creates a secure, private network connection for your Immich Machine Learning instance using Tailscale.
|
||||||
|
|
||||||
## Prerequisites
|
## Prerequisites
|
||||||
|
|
||||||
@@ -12,21 +12,20 @@ This project sets up a {{Service}} instance with Tailscale VPN integration using
|
|||||||
|
|
||||||
## Project Structure
|
## Project Structure
|
||||||
```
|
```
|
||||||
ts-{{service}}/
|
ts-immich-machine-learning/
|
||||||
├── docker-compose.yml
|
├── docker-compose.yml
|
||||||
├── tailscale/
|
├── tailscale/
|
||||||
│ ├── tailscale-data/ # Persistent Tailscale state
|
├── tailscale-data/ # Persistent Tailscale state
|
||||||
│ └── config/ # Tailscale configuration files
|
└── config/ # Tailscale configuration files
|
||||||
└── {{service}}/
|
|
||||||
└── config/ # {{Service}} configuration files
|
|
||||||
```
|
```
|
||||||
|
|
||||||
## Setup Instructions
|
## Setup Instructions
|
||||||
|
|
||||||
1. **Clone the Repository**
|
1. **Clone the Repository**
|
||||||
```bash
|
```bash
|
||||||
git clone https://gitea.damconsulting.llc/DAM/ts-{{service}}
|
git clone https://gitea.damconsulting.llc/DAM/ts-immich-machine-learning
|
||||||
cd ts-{{service}}
|
cd ts-immich-machine-learning
|
||||||
```
|
```
|
||||||
2. Create Required Directories
|
2. Create Required Directories
|
||||||
```bash
|
```bash
|
||||||
@@ -37,7 +36,7 @@ ts-{{service}}/
|
|||||||
- Optionally, update the file in `tailscale/config/serve.json` if you need specific Tailscale serve configurations
|
- Optionally, update the file in `tailscale/config/serve.json` if you need specific Tailscale serve configurations
|
||||||
- CAUTION: Changing `"${TS_CERT_DOMAIN}:443": false` to `true` will expose the service to the internet
|
- CAUTION: Changing `"${TS_CERT_DOMAIN}:443": false` to `true` will expose the service to the internet
|
||||||
|
|
||||||
4. Configure {{Service}}
|
4. Configure Immich Machine Learning
|
||||||
- See the [documentation]({{service_docs}}) for configuration options
|
- See the [documentation]({{service_docs}}) for configuration options
|
||||||
|
|
||||||
5. Start the Services
|
5. Start the Services
|
||||||
@@ -48,30 +47,30 @@ ts-{{service}}/
|
|||||||
6. Wait for Certificate to propagate [~2m]
|
6. Wait for Certificate to propagate [~2m]
|
||||||
|
|
||||||
7. Login
|
7. Login
|
||||||
- After starting the services your service should be available via tailnet at https://{{service}}.{{YOUR_TAILNET_DOMAIN}}.ts.net ie https://{{service}}.tail12345.ts.net/
|
- After starting the services your service should be available via tailnet at https://immich-machine-learning.{{YOUR_TAILNET_DOMAIN}}.ts.net ie https://immich-machine-learning.tail12345.ts.net/
|
||||||
|
|
||||||
## Services
|
## Services
|
||||||
|
|
||||||
### {{service}}-ts (Tailscale)
|
### immich-machine-learning-ts (Tailscale)
|
||||||
|
|
||||||
- Runs Tailscale VPN client
|
- Runs Tailscale VPN client
|
||||||
- Image: tailscale/tailscale:latest
|
- Image: tailscale/tailscale:latest
|
||||||
- Container name: {{service}}-ts
|
- Container name: immich-machine-learning-ts
|
||||||
- Hostname: {{service}}
|
- Hostname: immich-machine-learning
|
||||||
- Requires NET_ADMIN and SYS_MODULE capabilities
|
- Requires NET_ADMIN and SYS_MODULE capabilities
|
||||||
- Persists state in ./tailscale/tailscale-data
|
- Persists state in ./tailscale/tailscale-data
|
||||||
- Uses configuration from ./tailscale/config
|
- Uses configuration from ./tailscale/config
|
||||||
|
|
||||||
### {{service}}
|
### immich-machine-learning
|
||||||
|
|
||||||
- Depends on {{service}}-ts service
|
- Depends on immich-machine-learning-ts service
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
- After starting the services your service should be available via tailnet at `https://{{service}}.{{YOUR_TAILNET_DOMAIN}}.ts.net` ie `https://{{service}}.tail12345.ts.net/`
|
- After starting the services your service should be available via tailnet at `https://immich-machine-learning.{{YOUR_TAILNET_DOMAIN}}.ts.net` ie `https://immich-machine-learning.tail12345.ts.net/`
|
||||||
- To manually get the Tailscale IP/hostname of your container:
|
- To manually get the Tailscale IP/hostname of your container:
|
||||||
```bash
|
```bash
|
||||||
docker logs {{service}}-ts
|
docker logs immich-machine-learning-ts
|
||||||
```
|
```
|
||||||
Look for the Tailscale IP address in the logs.
|
Look for the Tailscale IP address in the logs.
|
||||||
|
|
||||||
@@ -90,19 +89,19 @@ ts-{{service}}/
|
|||||||
## Troubleshooting
|
## Troubleshooting
|
||||||
- Check container logs:
|
- Check container logs:
|
||||||
```bash
|
```bash
|
||||||
docker logs {{service}}-ts
|
docker logs immich-machine-learning-ts
|
||||||
docker logs {{service}}
|
docker logs immich-machine-learning
|
||||||
```
|
```
|
||||||
- Ensure your Tailscale auth key is valid and not expired
|
- Ensure your Tailscale auth key is valid and not expired
|
||||||
- Verify the configuration files have proper permissions
|
- Verify the configuration files have proper permissions
|
||||||
- Make sure required directories exist before starting
|
- Make sure required directories exist before starting
|
||||||
|
|
||||||
## Notes
|
## Notes
|
||||||
- The {{Service}} service uses the Tailscale service's network stack via `network_mode: service:{{service}}-ts`
|
- The Immich Machine Learning service uses the Tailscale service's network stack via `network_mode: service:immich-machine-learning-ts`
|
||||||
- Direct port mapping is disabled by default as Tailscale handles the networking
|
- Direct port mapping is disabled by default as Tailscale handles the networking
|
||||||
- Services restart automatically unless explicitly stopped
|
- Services restart automatically unless explicitly stopped
|
||||||
- For more information:
|
- For more information:
|
||||||
- Tailscale documentation: https://tailscale.com/kb/
|
- Tailscale documentation: https://tailscale.com/kb/
|
||||||
- {{Service}} [documentation]({{service_docs}})
|
- Immich Machine Learning [documentation]({{service_docs}})
|
||||||
- {{Service}} [repository]({{service_repo}})
|
- Immich Machine Learning [repository]({{service_repo}})
|
||||||
- {{Service}} [linuxserve.io]({{service_lcsr}})
|
- Immich Machine Learning [linuxserve.io]({{service_lcsr}})
|
||||||
@@ -1,8 +1,8 @@
|
|||||||
services:
|
services:
|
||||||
{{service}}-ts:
|
immich-machine-learning-ts:
|
||||||
image: tailscale/tailscale:latest
|
image: tailscale/tailscale:latest
|
||||||
hostname: {{service}}
|
hostname: immich-machine-learning
|
||||||
container_name: {{service}}-ts
|
container_name: immich-machine-learning-ts
|
||||||
environment:
|
environment:
|
||||||
- TS_AUTHKEY={{YOUR_TAILSCALE_AUTHKEY}}
|
- TS_AUTHKEY={{YOUR_TAILSCALE_AUTHKEY}}
|
||||||
- TS_STATE_DIR=/var/lib/tailscale
|
- TS_STATE_DIR=/var/lib/tailscale
|
||||||
@@ -15,7 +15,25 @@ services:
|
|||||||
- net_admin
|
- net_admin
|
||||||
- sys_module
|
- sys_module
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
{{service-compose}}
|
|
||||||
network_mode: service:{{service}}-ts
|
immich-machine-learning:
|
||||||
|
container_name: immich_machine_learning
|
||||||
|
# For hardware acceleration, add one of -[armnn, cuda, rocm, openvino, rknn] to the image tag.
|
||||||
|
# Example tag: ${IMMICH_VERSION:-release}-cuda
|
||||||
|
image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release}
|
||||||
|
# extends: # uncomment this section for hardware acceleration - see https://immich.app/docs/features/ml-hardware-acceleration
|
||||||
|
# file: hwaccel.ml.yml
|
||||||
|
# service: cpu # set to one of [armnn, cuda, rocm, openvino, openvino-wsl, rknn] for accelerated inference - use the `-wsl` version for WSL2 where applicable
|
||||||
|
volumes:
|
||||||
|
- model-cache:/cache
|
||||||
|
env_file:
|
||||||
|
- .env
|
||||||
|
network_mode: service:immich-machine-learning-ts
|
||||||
depends_on:
|
depends_on:
|
||||||
- {{service}}-ts
|
- immich-machine-learning-ts
|
||||||
|
restart: always
|
||||||
|
healthcheck:
|
||||||
|
disable: false
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
model-cache:
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
"${TS_CERT_DOMAIN}:443": {
|
"${TS_CERT_DOMAIN}:443": {
|
||||||
"Handlers": {
|
"Handlers": {
|
||||||
"/": {
|
"/": {
|
||||||
"Proxy": "http://127.0.0.1:3000"
|
"Proxy": "http://127.0.0.1:3003"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user