Commit Graph

36 Commits

Author SHA1 Message Date
Earlopain
f51e0e85cf
[Ruby] Bump to 3.3.1 2024-04-28 11:46:36 +02:00
Earlopain
db5bdabae2
[Docker] Bump to alpine 3.19
Let's get this out of the way if stuff needs to be rebuild anyways
2024-01-25 22:06:27 +01:00
Earlopain
7826b72835
[Docker] Default to running as root
Previous setups will already contain folders created as root. Making a different user the default
will break these setups. So just make it opt-in instead.
2024-01-15 08:59:56 +00:00
Earlopain
5a1e833e7e
[Docker] Set default for UID/GID in Dockerfile as well
We can't rely on this being set by using compose, since CI as an example just does `docker build .`
2024-01-14 20:13:08 +00:00
Earlopain
2de0ebb5b8
[Docker] Allow running as different user 2024-01-14 16:30:49 +00:00
Earlopain
3d1a53233b
[Docker] Reenable irb autocomplete
Feels much better than when I disabled this
2024-01-12 21:16:36 +00:00
Earlopain
fa9fb531f7
[Docker] Add a devcontainer
This removes the need for all the ruby-lsp setup stuff.

ruby-lsp will try to install the debug gem which contains native code, add that to the gemfile so it doesn't cause trouble.

I'm probably going to remove the rubocop/test compose services at some point. With devcontainers you are just able to run the commands directly.
2024-01-12 20:50:24 +00:00
Earlopain
a0a0d8db13
[Docker] Replace solargraph with ruby-lsp
It just works.
Requires a bit of a workaround for the .rubocop.yml env setup currently in use but thats alright.
The companion ruby-lsp-rails doesn't do much right now but I imagine that to become quite powerful in the future.
2024-01-11 23:16:03 +01:00
Earlopain
9e024ff792
[Docker] Bump node to latest LTS 2023-12-04 17:16:20 +01:00
Earlopain
2620ea983e
[Wiki] Better diffing view 2023-10-15 13:08:28 +02:00
Earlopain
1c4a79d2ef
[Docker] Enable YJIT
Gives a small performance boost on prod in exchange for more RAM usage
2023-09-17 14:37:16 +02:00
Earlopain
e1023163c6
[Docker] Bump to alpine 3.18 2023-06-05 22:14:10 +02:00
Earlopain
76963fe59d
[Docker] Fix build
Wanted to remove the bundler install but removed foreman as well. Whoops
ed268ddf02
2023-05-30 16:07:49 +02:00
Earlopain
ed268ddf02
[Gems] Bump bundler
This is the default version shipped with ruby atm so no need to install it
2023-05-26 20:17:48 +02:00
Earlopain
921e6762ea
[Ruby] Bump to 3.2.2 2023-04-16 14:46:49 +02:00
Earlopain
8f66cecb3f
[Gems] Bump rubocop and solargraph 2023-04-15 16:13:19 +02:00
Earlopain
c6c655942b
[JS] Bump node to v18 2023-04-03 21:55:06 +02:00
Earlopain
7f4344936e
[Ruby] Bump version 2023-04-03 17:39:37 +02:00
Earlopain
6776704560
[DB] Upgrade to postgres 15
Execute the following commands, before pulling:
docker-compose up -d
docker-compose exec postgres pg_dump danbooru2 -U danbooru > backup.sql
docker-compose down
docker volume rm e621ng_db_data

Execute the following commands, after pulling:
docker-compose up -d
docker-compose exec -T postgres psql -d e621_development -U e621 < backup.sql

This also changes the name of the database and role.
Now seems like a nice opportunity to do so.
2023-03-01 20:31:49 +01:00
Earlopain
835f3e1188
[JS] Update to node 16 2023-02-03 17:17:45 +01:00
Earlopain
057a67a168
[Docker] Miscellaneous improvements
* Install exact versions of redis/memcached/node
* Use multistage for js packages/ruby gems
* Replace shoreman with foreman
2022-12-13 15:50:37 +01:00
Earlopain
6d44c07c97
[Docker] Set correct pwd for yarn install
See #449
2022-12-07 09:07:39 +01:00
Earlopain
3294fabad5
Revert "[Docker] Remove node_modules volume"
This reverts commit 12cf54a8f3.
2022-12-06 23:13:51 +01:00
Earlopain
12cf54a8f3
[Docker] Remove node_modules volume
My intention was to share it between the test/main service (I think).
But since it's using the main one as a base anways it's already there.
This volume overlays on the one from newer builds, hiding js package changes.

public_packs_test is unused as well, remove.
2022-12-06 18:51:16 +01:00
Earlopain
4640862271
[Docker] Explicitly use new alpine version
Alpine 3.17 has jemalloc back in it's repositories, which means it can just
be installed through the package manager.
Also explicitly install postgres 12 packages. That was already possible with
alpine 3.16 but I didn't know about it back then.
2022-12-01 15:57:24 +01:00
Earlopain
179a948cf2
[Docker] Add solargraph to the image, and a few more things
* Allow modifying .env without git complainging about changes to commit
* Require COMPOSE_PROFILE=solargraph for solargraph to be included in the image
* Set required vscode settings for solargraph to correctly work in docker
* Clean up .solargraph.yml. All these removed values are the default
* Disable autocomplete in the rails console
* Add a compose service to run rubocop

* Upddate rubocop config

Added some, removed some, ordered alphabetically.
Before: 844 files inspected, 6871 offenses detected, 6095 offenses autocorrectable
After: 844 files inspected, 8024 offenses detected, 7538 offenses autocorrectable
Most of the new offences are because of Style/StringLiterals (1312)
2022-10-18 23:35:18 +02:00
Earlopain
87235d6e92
[Ruby] Update to 3.1
net-smtp is no longer bundled by default
Webrick is no longer bundled by default, new rails projects are created
with puma in the gemfile
2022-04-25 21:27:09 +02:00
Earlopain
8d1f0519ac
[Docker] Silence git warnings
https://github.blog/2022-04-12-git-security-vulnerability-announced/
2022-05-19 12:04:58 +02:00
Earlopain
e45e9023d4
[Bundler] Update to 2.3.12
This is currently the lastest version. The currently used version prints
a deprecation warning everytime with ruby 3
2022-05-19 12:04:58 +02:00
Earlopain
5c215ea154
[Docker] Install bundler into image 2022-05-19 12:02:04 +02:00
Earlopain
dac62bbc78
[Docker] Fix build
The nice to have packages I removed weren't actually  just nice to have.
Shoreman requires a bash installation
2022-04-22 18:25:01 +02:00
Earlopain
8c6fb41933
[Docker] Use jemalloc
It's used in prod, should be done here too then.
Alpine doesn't provide this package, so we'll need to compile it ourself.
Confirmed working with `MALLOC_CONF=stats_print:true ruby -e "exit"`
2022-04-21 20:22:15 +02:00
Earlopain
82d7ff59e0
[Docker] Install gems and js packages into the image
To see the changes persisted into the container run `docker-compose` build
`docker-compose down -v` no longer requires to reinstall gems/packages
It's also possible to have branches with different gemfiles, without having
to install between them constantly
2022-01-05 13:41:41 +01:00
Albert Yi
17604a6147 remove dockerfile 2016-11-28 16:49:43 -08:00
r888888888
097914ca67 copy local config and database.yml in dockerfile 2015-03-11 16:30:18 -07:00
r888888888
447597b665 add Dockerfile support 2015-01-22 15:18:52 -08:00