archsight 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: '02159c7a5daad27f25979069c4b99ffaf571a21d39aff2cab0f5596a3214f897'
4
- data.tar.gz: ab77c07451e71853aaca877b2642df46ffc32c81b5dfbcc0d7b86893a26ef955
3
+ metadata.gz: 5daf787a0535e787bb31a5abbe46e8da7621256e710dd59ec7328c116b988df4
4
+ data.tar.gz: e662425404ec865eef3701723135c103e688e43bb8d560708f936dd9021acd88
5
5
  SHA512:
6
- metadata.gz: d753c04025bea2bb8ce93b55e0cb479eb3c44ad756d1e123b1cda844119fedfcce43d8f4b824d6cefd6c5c98401099eaa00c1416cc2302f2486514917f3df05e
7
- data.tar.gz: 3992fc81f881e7de8c751c6af12354463eabfeb8ac30d8019106ec0676d792543cdf4b4658aef1075b5f8a85d1ef037d31cfe0b33df0b2867de7d0f3b1b97157
6
+ metadata.gz: c31f6486348cd3e4e2b3a8247071f3f1ddbe139b0cb20faeba51167122d860d74cf205128532d6184ac78a9eac5be64ccee28c41dec9fff094963d77e1ee34bc
7
+ data.tar.gz: cb36b1eb48ed9c44985925e2e54ffa7c74d66ee51ca0407882151db27ce34168f747dc9cb4aadbfe35c19d1fb5c5a1b3860741635a6a342a810faac926638885
data/Dockerfile CHANGED
@@ -1,39 +1,38 @@
1
- FROM ruby:4.0-alpine3.23
1
+ # Build stage
2
+ FROM ruby:4.0-alpine3.23 AS builder
2
3
 
3
- # Install system dependencies required for building gems
4
- RUN apk add --no-cache \
5
- build-base \
6
- git \
7
- libffi-dev \
8
- yaml-dev \
9
- graphviz
4
+ RUN apk add --no-cache build-base git libffi-dev yaml-dev
10
5
 
11
- # Set working directory
12
6
  WORKDIR /app
7
+ COPY . .
8
+
9
+ # Build and install the gem
10
+ RUN gem build archsight.gemspec && \
11
+ gem install --no-document archsight-*.gem
13
12
 
14
- # Copy gemspec, Gemfile, and .ruby-version for dependency installation
15
- COPY archsight.gemspec Gemfile Gemfile.lock* .ruby-version ./
16
- COPY lib/archsight/version.rb lib/archsight/version.rb
13
+ # Runtime stage
14
+ FROM ruby:4.0-alpine3.23
17
15
 
18
- # Install Ruby dependencies
19
- RUN bundle install --jobs 4
16
+ RUN apk add --no-cache graphviz
20
17
 
21
- # Copy application code
22
- COPY . .
18
+ # Copy installed gems from builder (including default gems that were updated)
19
+ COPY --from=builder /usr/local/bundle /usr/local/bundle
20
+ COPY --from=builder /usr/local/lib/ruby/gems /usr/local/lib/ruby/gems
21
+
22
+ # Ensure Ruby finds gems in both /usr/local/bundle and default gems location
23
+ ENV GEM_HOME=/usr/local/bundle
24
+ ENV GEM_PATH=/usr/local/bundle:/usr/local/lib/ruby/gems/4.0.0
25
+ ENV PATH="/usr/local/bundle/bin:${PATH}"
23
26
 
24
- # Create volume mount point for resources
25
27
  RUN mkdir -p /resources
26
28
 
27
- # Set resources directory environment variable
28
29
  ENV ARCHSIGHT_RESOURCES_DIR=/resources
29
30
  ENV APP_ENV=production
30
31
 
31
- # Expose port for web server
32
32
  EXPOSE 4567
33
33
 
34
- # Health check
35
34
  HEALTHCHECK --interval=30s --timeout=3s --start-period=5s --retries=3 \
36
35
  CMD wget --no-verbose --tries=1 --spider http://localhost:4567/ || exit 1
37
36
 
38
- # Default command - use the archsight CLI
39
- CMD ["bundle", "exec", "exe/archsight", "web", "--port", "4567"]
37
+ ENTRYPOINT ["archsight"]
38
+ CMD ["web", "--port", "4567"]
data/README.md CHANGED
@@ -41,18 +41,23 @@ Access at: <http://localhost:4567>
41
41
  ### Option 2: Docker
42
42
 
43
43
  ```bash
44
- docker build -t archsight .
45
- docker run -p 4567:4567 -v "/path/to/resources:/resources" archsight
44
+ # Run web server (default)
45
+ docker run -p 4567:4567 -v "/path/to/resources:/resources" ghcr.io/ionos-cloud/archsight
46
+
47
+ # Run lint
48
+ docker run -v "/path/to/resources:/resources" ghcr.io/ionos-cloud/archsight lint -r /resources
49
+
50
+ # Run any command
51
+ docker run ghcr.io/ionos-cloud/archsight version
46
52
  ```
47
53
 
48
- Access at: <http://localhost:4567>
54
+ Access web interface at: <http://localhost:4567>
49
55
 
50
56
  **Notes:**
51
57
 
52
- - The volume mount `-v "/path/to/resources:/resources"` mounts your resources directory
53
- - Resources are accessible at `/resources` inside the container
54
- - Live YAML updates are reflected without rebuilding
55
- - Health check verifies the service is running
58
+ - Volume mount `-v "/path/to/resources:/resources"` mounts your resources directory
59
+ - Default command starts the web server on port 4567
60
+ - Pass subcommands directly (lint, version, console, template)
56
61
 
57
62
  ## CLI Commands
58
63
 
data/exe/archsight CHANGED
@@ -1,7 +1,9 @@
1
1
  #!/usr/bin/env ruby
2
2
  # frozen_string_literal: true
3
3
 
4
- $LOAD_PATH.unshift File.expand_path("../lib", __dir__)
4
+ # Support running from source (development)
5
+ lib_path = File.expand_path("../lib", __dir__)
6
+ $LOAD_PATH.unshift(lib_path) if File.directory?(File.join(lib_path, "archsight"))
5
7
 
6
8
  require "archsight"
7
9
  require "archsight/cli"
data/lib/archsight/cli.rb CHANGED
@@ -15,6 +15,7 @@ module Archsight
15
15
  def web
16
16
  configure_resources
17
17
  require "archsight/web/application"
18
+ Archsight::Web::Application.setup_mcp!
18
19
  Archsight::Web::Application.run!(port: options[:port], bind: options[:host])
19
20
  end
20
21
 
@@ -4,5 +4,5 @@
4
4
  # Do not edit manually.
5
5
 
6
6
  module Archsight
7
- VERSION = "0.1.1"
7
+ VERSION = "0.1.2"
8
8
  end
@@ -13,7 +13,7 @@ Welcome to the Architecture Documentation System. This documentation covers how
13
13
  The following diagram shows all resource types organized by layer and their relationships:
14
14
 
15
15
  ```mermaid
16
- <%= Documentation.generate_mermaid_diagram %>
16
+ <%= Archsight::Documentation.generate_mermaid_diagram %>
17
17
  ```
18
18
 
19
19
  ## Resource Types
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: archsight
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vincent Landgraf