Skip to content

Commit 8eb1554

Browse files
author
David Zuckerman
committed
using ruby3.3-slim for image, updated README, using app name for service instead of bfs now
1 parent 3f0ec07 commit 8eb1554

File tree

4 files changed

+23
-11
lines changed

4 files changed

+23
-11
lines changed

.ruby-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.1.7
1+
~> 3.3

Dockerfile

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,29 @@
1-
FROM registry.access.redhat.com/ubi8/ruby-31
1+
FROM ruby:3.3-slim AS base
22
USER root
33

44
# Configure users and groups
55
RUN groupadd -g 40054 alma && \
66
useradd -r -s /sbin/nologin -M -u 40054 -g alma alma && \
7+
useradd -u 40061 bfs && \
78
groupadd -g 40061 bfs && \
89
usermod -u 40061 -g bfs -G alma -l bfs default && \
910
find / -user 1001 -exec chown -h bfs {} \; || true && \
1011
mkdir -p /opt/app && \
1112
chown -R bfs:bfs /opt/app
1213

14+
# Get list of available packages
15+
RUN apt-get update -qq
16+
17+
# Install system packages needed to build gems with C extensions.
18+
RUN apt-get install -y --no-install-recommends \
19+
g++ \
20+
git \
21+
build-essential \
22+
libxml2-dev \
23+
libxslt1-dev \
24+
make
25+
26+
1327
WORKDIR /opt/app
1428
COPY --chown=bfs Gemfile* .ruby-version ./
1529
RUN bundle config set force_ruby_platform true

Gemfile

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,3 @@ gem 'net-ssh', '~> 7.1.0'
1313
gem 'nokogiri', '~> 1.15.0'
1414
gem 'rspec'
1515
gem 'thor', '~> 1.1'
16-
17-

README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,13 @@ docker compose build
1313
View the CLI tool help/description:
1414

1515
```sh
16-
docker compose run --rm bfs help
16+
docker compose run --rm app help
1717
```
1818

1919
Adds test data to the default watch directory:
2020

2121
```sh
22-
docker compose run --rm bfs seed
22+
docker compose run --rm app seed
2323
```
2424

2525
Run the app in the background. It will continue running, monitoring for .xml files to process every 10s.
@@ -32,19 +32,19 @@ docker compose logs -f # view processing logs in real time
3232
Watch a non-standard directory:
3333

3434
```sh
35-
docker compose run --rm bfs watch /path/in/container # absolute path
36-
docker compose run --rm bfs watch data/somedir # path relative to /opt/app-root/src
35+
docker compose run --rm app watch /path/in/container # absolute path
36+
docker compose run --rm app watch data/somedir # path relative to /opt/app-root/src
3737
```
3838

3939
Process a specific file:
4040

4141
```sh
42-
docker compose run --rm bfs process /abs/path/to/myfile.xml # absolute path
43-
docker compose run --rm bfs process data/invoicing/pay/somefile.xml # relative path
42+
docker compose run --rm app process /abs/path/to/myfile.xml # absolute path
43+
docker compose run --rm app process data/invoicing/pay/somefile.xml # relative path
4444
```
4545

4646
Delete previously processed files and error logs:
4747

4848
```sh
49-
docker compose run --rm bfs clear
49+
docker compose run --rm app clear
5050
```

0 commit comments

Comments
 (0)