still doesn't work

This commit is contained in:
Apodemus Erectus 2023-08-15 16:54:24 +02:00
parent 50d368aacf
commit a46bc9ab05
2 changed files with 45 additions and 30 deletions

11
.vscode/settings.json vendored Normal file
View File

@ -0,0 +1,11 @@
{
"files.exclude": {
"**/.git": true,
"**/.svn": true,
"**/.hg": true,
"**/CVS": true,
"**/.DS_Store": true,
"**/Thumbs.db": true,
"**/node_modules": true
}
}

View File

@ -17,11 +17,15 @@ RUN apt-get install -y \
rm -rf /var/lib/apt/lists/*
# Install gems
COPY Gemfile Gemfile.lock ./
# COPY Gemfile Gemfile.lock Rakefile ./
COPY . .
RUN gem install rake bundler && \
# bundle config set --local path 'vendor' && \
# bundle update && \
bundle install --jobs 4
bundle install && \
bundle update && \
bundle install
# bundle binstubs --all
RUN rails db:migrate
@ -34,36 +38,36 @@ RUN rails assets:precompile && \
# RUN rake test
# RUN bash -c "cat > /etc/systemd/system/ingang.service" << EOF \
# [Unit] \
# Description=Ingang \
# \
# [Service] \
# Type=simple \
# RemainAfterExit=yes \
# Restart=on-failure \
# TimeoutSec=300 \
# User=$USER \
# WorkingDirectory=$PWD \
# PIDFile=$PWD/tmp/pids/server.pid \
# ExecStart=$PUMA -F $PWD/config/puma.rb start \
# ExecStop=$PUMA -F $PWD/config/puma.rb stop \
# ExecReload=$PUMA -F $PWD/config/puma.rb phased-restart \
# \
# [Install] \
# WantedBy=multi-user.target \
# EOF
RUN bash -c "cat > /etc/systemd/system/ingang.service" << EOF \
[Unit] \
Description=Ingang \
\
[Service] \
Type=simple \
RemainAfterExit=yes \
Restart=on-failure \
TimeoutSec=300 \
User=$USER \
WorkingDirectory=$PWD \
PIDFile=$PWD/tmp/pids/server.pid \
ExecStart=$PUMA -F $PWD/config/puma.rb start \
ExecStop=$PUMA -F $PWD/config/puma.rb stop \
ExecReload=$PUMA -F $PWD/config/puma.rb phased-restart \
\
[Install] \
WantedBy=multi-user.target \
EOF
# RUN systemctl daemon-reload && \
# systemctl stop ingang && \
# systemctl disable ingang && \
# systemctl enable ingang && \
# systemctl start ingang && \
# systemctl status ingang && \
# journalctl -u ingang
RUN chkconfig ingang --add && \
service ingang stop && \
service ingang off && \
service ingang on && \
service ingang start && \
service ingang status && \
journalctl -u ingang
# Copy the application code
COPY . .
# COPY . .
# Expose ports
EXPOSE 6969