Spaces:
Build error
Build error
Update Dockerfile
Browse files- Dockerfile +15 -99
Dockerfile
CHANGED
|
@@ -1,99 +1,15 @@
|
|
| 1 |
-
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
#
|
| 5 |
-
#
|
| 6 |
-
#
|
| 7 |
-
#
|
| 8 |
-
#
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
# provided username and password. Do not set these in your Dockerfile, as they
|
| 17 |
-
# globally visible on a public space.
|
| 18 |
-
#
|
| 19 |
-
# LABEL_STUDIO_USERNAME
|
| 20 |
-
# LABEL_STUDIO_PASSWORD
|
| 21 |
-
#
|
| 22 |
-
# You will need to provide new users with an invitation link to join the space.
|
| 23 |
-
#
|
| 24 |
-
################################################################################
|
| 25 |
-
|
| 26 |
-
################################################################################
|
| 27 |
-
#
|
| 28 |
-
# How to Enable Configuration Persistence
|
| 29 |
-
# ---------------------------------------
|
| 30 |
-
# By default this space stores all project configuration and data annotations
|
| 31 |
-
# in local storage with Sqlite. If the space is reset, all configuration and
|
| 32 |
-
# annotation data in the space will be lost. You can enable configuration
|
| 33 |
-
# persistence by connecting an external Postgres database to your space,
|
| 34 |
-
# guaranteeing that all project and annotation settings are preserved.
|
| 35 |
-
#
|
| 36 |
-
# Set the following secret variables to match your own hosted instance of
|
| 37 |
-
# Postgres. We strongly recommend setting these as secrets to prevent leaking
|
| 38 |
-
# information about your database service to the public in your spaces
|
| 39 |
-
# definition.
|
| 40 |
-
#
|
| 41 |
-
# ENV DJANGO_DB=default
|
| 42 |
-
# ENV POSTGRE_NAME=<postgres_name>
|
| 43 |
-
# ENV POSTGRE_PORT=<db_port>
|
| 44 |
-
# ENV POSTGRE_USER=<postgres_user>
|
| 45 |
-
# ENV POSTGRE_PASSWORD=<password>
|
| 46 |
-
# ENV POSTGRE_PORT=<db_port>
|
| 47 |
-
# ENV POSTGRE_HOST=<db_host>
|
| 48 |
-
#
|
| 49 |
-
# Uncomment the following line to remove the warning about ephemeral storage
|
| 50 |
-
#
|
| 51 |
-
# ENV STORAGE_PERSISTENCE=1
|
| 52 |
-
#
|
| 53 |
-
# Note that you will need to connect cloud storage to host data items that you
|
| 54 |
-
# want to annotate, as local storage will not be preserved across a space reset.
|
| 55 |
-
#
|
| 56 |
-
################################################################################
|
| 57 |
-
|
| 58 |
-
################################################################################
|
| 59 |
-
#
|
| 60 |
-
# How to Enable Cloud Storage
|
| 61 |
-
# ---------------------------
|
| 62 |
-
# By default the only data storage enabled for this space is local. In the case
|
| 63 |
-
# of a space reset, all data will be lost. To enable permanent storage, you
|
| 64 |
-
# must enable a cloud storage connector. We also strongly recommend enabling
|
| 65 |
-
# configuration persistence to preserve project data, annotations, and user
|
| 66 |
-
# settings. Choose the appropriate cloud connector and configure the secrets
|
| 67 |
-
# for it.
|
| 68 |
-
#
|
| 69 |
-
# Amazon S3
|
| 70 |
-
# =========
|
| 71 |
-
# STORAGE_TYPE=s3
|
| 72 |
-
# STORAGE_AWS_ACCESS_KEY_ID="<YOUR_ACCESS_KEY_ID>"
|
| 73 |
-
# STORAGE_AWS_SECRET_ACCESS_KEY="<YOUR_SECRET_ACCESS_KEY>"
|
| 74 |
-
# STORAGE_AWS_BUCKET_NAME="<YOUR_BUCKET_NAME>"
|
| 75 |
-
# STORAGE_AWS_REGION_NAME="<YOUR_BUCKET_REGION>"
|
| 76 |
-
# STORAGE_AWS_FOLDER=""
|
| 77 |
-
#
|
| 78 |
-
# Google Cloud Storage
|
| 79 |
-
# ====================
|
| 80 |
-
#
|
| 81 |
-
# STORAGE_TYPE=gcs
|
| 82 |
-
# STORAGE_GCS_BUCKET_NAME="<YOUR_BUCKET_NAME>"
|
| 83 |
-
# STORAGE_GCS_PROJECT_ID="<YOUR_PROJECT_ID>"
|
| 84 |
-
# STORAGE_GCS_FOLDER=""
|
| 85 |
-
# GOOGLE_APPLICATION_CREDENTIALS="/opt/heartex/secrets/key.json"
|
| 86 |
-
#
|
| 87 |
-
# Azure Blob Storage
|
| 88 |
-
# ==================
|
| 89 |
-
#
|
| 90 |
-
# STORAGE_TYPE=azure
|
| 91 |
-
# STORAGE_AZURE_ACCOUNT_NAME="<YOUR_STORAGE_ACCOUNT>"
|
| 92 |
-
# STORAGE_AZURE_ACCOUNT_KEY="<YOUR_STORAGE_KEY>"
|
| 93 |
-
# STORAGE_AZURE_CONTAINER_NAME="<YOUR_CONTAINER_NAME>"
|
| 94 |
-
# STORAGE_AZURE_FOLDER=""
|
| 95 |
-
#
|
| 96 |
-
#
|
| 97 |
-
################################################################################
|
| 98 |
-
|
| 99 |
-
CMD exec label-studio --host=$SPACE_HOST
|
|
|
|
| 1 |
+
# This will start a code-server container and expose it at http://127.0.0.1:8080.
|
| 2 |
+
# It will also mount your current directory into the container as `/home/coder/project`
|
| 3 |
+
# and forward your UID/GID so that all file system operations occur as your user outside
|
| 4 |
+
# the container.
|
| 5 |
+
#
|
| 6 |
+
# Your $HOME/.config is mounted at $HOME/.config within the container to ensure you can
|
| 7 |
+
# easily access/modify your code-server config in $HOME/.config/code-server/config.json
|
| 8 |
+
# outside the container.
|
| 9 |
+
mkdir -p ~/.config
|
| 10 |
+
docker run -it --name code-server -p 127.0.0.1:8080:8080 \
|
| 11 |
+
-v "$HOME/.config:/home/coder/.config" \
|
| 12 |
+
-v "$PWD:/home/coder/project" \
|
| 13 |
+
-u "$(id -u):$(id -g)" \
|
| 14 |
+
-e "DOCKER_USER=$USER" \
|
| 15 |
+
codercom/code-server:latest
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|