Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
**/node_modules
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -301,3 +301,6 @@ test_experiment/

# Output data
.wei/

#node modules
**/node_modules
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
rev: v4.6.0
hooks:
- id: check-yaml
- id: check-json
Expand All @@ -17,7 +17,7 @@ repos:
- id: nbstripout
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.3.2
rev: v0.4.8
hooks:
# Run the linter.
- id: ruff
Expand Down
17 changes: 15 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ LABEL org.opencontainers.image.licenses=MIT
RUN set -eux; \
apt-get update; \
apt-get install -y gosu; \
apt-get install -y npm; \
rm -rf /var/lib/apt/lists/*

# User configuration
Expand All @@ -30,17 +31,29 @@ RUN --mount=type=cache,target=/root/.cache \
pip install -r wei/requirements/requirements.txt

# Copy wei files
COPY wei wei/wei
COPY src wei/src
COPY tests wei/tests
COPY pyproject.toml wei/pyproject.toml
COPY README.md wei/README.md
COPY scripts wei/scripts


# Install dependencies and wei
RUN --mount=type=cache,target=/root/.cache \
pip install -e wei

COPY wei-entrypoint.sh /wei-entrypoint.sh
RUN chmod +x /wei-entrypoint.sh
ENTRYPOINT [ "/wei-entrypoint.sh" ]

COPY ./src/ui/package*.json ./

# install project dependencies
RUN npm install
#--mount=type=cache,target=./node_modules \
# npm install

# copy project files and folders to the current working directory (i.e. 'app' folder)

# build app for production with minification

RUN npm run build --prefix wei/src/ui
2 changes: 1 addition & 1 deletion compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ services:
- diaspora_config:/home/app/.diaspora
- ./tests/workcells:/workcell_defs
- ~/.wei:/home/app/.wei
- ./:/home/app/wei # for development only

environment:
- PYTHONUNBUFFERED=1 # Fix weird bug with empty logging
- USER_ID=${USER_ID:-1000}
Expand Down
6 changes: 6 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 2 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,8 @@ requires = ["setuptools", "wheel"]
build-backend = "setuptools.build_meta"


[tool.setuptools.packages.find]
where = ["."]
include = ["wei*"]
exclude = ["*tests*"]
[tool.setuptools]
package-dir = {"wei" = "src/wei"}

#####################
# Development Tools #
Expand Down
Binary file added src/ui/bun.lockb
Binary file not shown.
21 changes: 21 additions & 0 deletions src/ui/components.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
/* eslint-disable */
/* prettier-ignore */
// @ts-nocheck
// Generated by unplugin-vue-components
// Read more: https://github.com/vuejs/core/pull/3399
export {}

declare module 'vue' {
export interface GlobalComponents {
Dashboard: typeof import('./src/components/Dashboard.vue')['default']
Event: typeof import('./src/components/Event.vue')['default']
Experiments: typeof import('./src/components/Experiments.vue')['default']
LocationsColumn: typeof import('./src/components/LocationsColumn.vue')['default']
ModuleColumn: typeof import('./src/components/ModuleColumn.vue')['default']
ModuleModal: typeof import('./src/components/ModuleModal.vue')['default']
Workflow: typeof import('./src/components/Workflow.vue')['default']
WorkflowModal: typeof import('./src/components/WorkflowModal.vue')['default']
WorkflowsColumn: typeof import('./src/components/WorkflowsColumn.vue')['default']
WorkflowTable: typeof import('./src/components/WorkflowTable.vue')['default']
}
}
16 changes: 16 additions & 0 deletions src/ui/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8" />
<link rel="icon" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Squid Dashboard</title>
</head>

<body>
<div id="app"></div>
<script type="module" src="/src/main.ts"></script>
</body>

</html>
Loading