Commit graph

5530 commits

Author SHA1 Message Date
Michael Kohl
c3f3575dcf
Make DB seeding idempotent (#8153) 2020-05-29 10:21:00 -04:00
rhymes
689fb6efb6
Routine rubocop fixes (#8137)
* Update gems

* rubocop -a

* rubocop --auto-gen-config
2020-05-29 11:56:52 +02:00
rhymes
5e3f645d29
Fix WikipediaTag tag regexp (#8139) 2020-05-29 10:59:12 +02:00
dependabot-preview[bot]
6b2cfd53da
[deploy] Bump kaminari from 1.2.0 to 1.2.1 (#8120)
* Bump kaminari from 1.2.0 to 1.2.1

Bumps [kaminari](https://github.com/kaminari/kaminari) from 1.2.0 to 1.2.1.
- [Release notes](https://github.com/kaminari/kaminari/releases)
- [Changelog](https://github.com/kaminari/kaminari/blob/master/CHANGELOG.md)
- [Commits](https://github.com/kaminari/kaminari/compare/v1.2.0...v1.2.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

* Bump kaminari from 1.2.0 to 1.2.1 (Update vendor/cache)

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-28 15:48:48 -05:00
dependabot-preview[bot]
9d652b38cf
Bump @babel/plugin-proposal-class-properties from 7.8.3 to 7.10.1 (#8131)
Bumps [@babel/plugin-proposal-class-properties](https://github.com/babel/babel/tree/HEAD/packages/babel-plugin-proposal-class-properties) from 7.8.3 to 7.10.1.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/master/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.10.1/packages/babel-plugin-proposal-class-properties)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-28 15:47:42 -05:00
dependabot-preview[bot]
4f1f7ccb41
Bump lint-staged from 10.2.4 to 10.2.6 (#8124)
Bumps [lint-staged](https://github.com/okonet/lint-staged) from 10.2.4 to 10.2.6.
- [Release notes](https://github.com/okonet/lint-staged/releases)
- [Commits](https://github.com/okonet/lint-staged/compare/v10.2.4...v10.2.6)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-28 15:45:32 -05:00
dependabot-preview[bot]
76c8c917e5
[deploy] Bump ddtrace from 0.35.2 to 0.36.0 (#8119)
* Bump ddtrace from 0.35.2 to 0.36.0

Bumps [ddtrace](https://github.com/DataDog/dd-trace-rb) from 0.35.2 to 0.36.0.
- [Release notes](https://github.com/DataDog/dd-trace-rb/releases)
- [Changelog](https://github.com/DataDog/dd-trace-rb/blob/master/CHANGELOG.md)
- [Commits](https://github.com/DataDog/dd-trace-rb/compare/v0.35.2...v0.36.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

* Bump ddtrace from 0.35.2 to 0.36.0 (Update vendor/cache)

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-28 15:13:55 -05:00
dependabot-preview[bot]
fcb71ab2cc
Bump vcr from 5.1.0 to 6.0.0 (#8121)
* Bump vcr from 5.1.0 to 6.0.0

Bumps [vcr](https://github.com/vcr/vcr) from 5.1.0 to 6.0.0.
- [Release notes](https://github.com/vcr/vcr/releases)
- [Changelog](https://github.com/vcr/vcr/blob/master/CHANGELOG.md)
- [Upgrade guide](https://github.com/vcr/vcr/blob/master/Upgrade.md)
- [Commits](https://github.com/vcr/vcr/compare/v5.1.0...v6.0.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

* Bump vcr from 5.1.0 to 6.0.0 (Update vendor/cache)

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-28 15:13:15 -05:00
dependabot-preview[bot]
1dd048cd30
Bump sitemap_generator from 6.1.0 to 6.1.1 (#8123)
* Bump sitemap_generator from 6.1.0 to 6.1.1

Bumps [sitemap_generator](https://github.com/kjvarga/sitemap_generator) from 6.1.0 to 6.1.1.
- [Release notes](https://github.com/kjvarga/sitemap_generator/releases)
- [Changelog](https://github.com/kjvarga/sitemap_generator/blob/master/CHANGES.md)
- [Commits](https://github.com/kjvarga/sitemap_generator/compare/v6.1.0...v6.1.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

* Bump sitemap_generator from 6.1.0 to 6.1.1 (Update vendor/cache)

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-28 15:12:37 -05:00
Molly Struve
234ae0f308
Update vendor cache gems (#8146) 2020-05-28 14:37:36 -05:00
Molly Struve
773a2d322b
Add Missing Vendor Gems from Dependabot Merges (#8145) 2020-05-28 14:32:21 -05:00
dependabot-preview[bot]
abe36378f4
Bump activerecord-import from 1.0.4 to 1.0.5 (#8118)
Bumps [activerecord-import](https://github.com/zdennis/activerecord-import) from 1.0.4 to 1.0.5.
- [Release notes](https://github.com/zdennis/activerecord-import/releases)
- [Changelog](https://github.com/zdennis/activerecord-import/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zdennis/activerecord-import/compare/v1.0.4...v1.0.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-28 15:18:29 -04:00
dependabot-preview[bot]
2c5fa60d39
Bump erb_lint from 0.0.32 to 0.0.33 (#8117)
Bumps [erb_lint](https://github.com/Shopify/erb-lint) from 0.0.32 to 0.0.33.
- [Release notes](https://github.com/Shopify/erb-lint/releases)
- [Commits](https://github.com/Shopify/erb-lint/compare/v0.0.32...v0.0.33)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-28 15:11:52 -04:00
dependabot-preview[bot]
077ce3fc2d
Bump fog-aws from 3.6.4 to 3.6.5 (#8115)
Bumps [fog-aws](https://github.com/fog/fog-aws) from 3.6.4 to 3.6.5.
- [Release notes](https://github.com/fog/fog-aws/releases)
- [Changelog](https://github.com/fog/fog-aws/blob/master/CHANGELOG.md)
- [Commits](https://github.com/fog/fog-aws/compare/v3.6.4...v3.6.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-28 15:11:42 -04:00
Nick Taylor
5c6e547187
Updated Storybook packages (#8141) 2020-05-28 14:56:26 -04:00
Joe Doss
284b6ee1e1
Update dependabot.yml (#8143) 2020-05-28 13:45:47 -05:00
Jacob Herrington
79bc4929e6
Remove unclear comment (#8138)
This is probably pedantic, but I believe this comment is unclear. There
is also a typo removed by this commit.
2020-05-28 12:53:04 -05:00
Joe Doss
a913103e7d
Update dependabot.yml (#8140) 2020-05-28 12:30:26 -05:00
Joe Doss
a607cbbf41
Update vendor/cache After Dependabot (#8135)
* Create dependabot.yml with 

bundle config cache_all_platforms true
bundle config set cache_all true

so we cache gems in the workflow.
2020-05-28 12:15:43 -05:00
Joe Doss
aa49cb1cfe
Bugfix for #7663 and refactor of container setup (#7747)
* Move from Alpine Linux to Fedora Linux.

This changes the base container image away from Alpine Linux to
Fedora Linux to address some musl libc issues with some of our gems.

It also moved the main file to a Containerfile and symlinks the Dockerfile
to it. This makes our container setup less Docker-centric as Linux users
most likely will be using Podman as their container runtime.

Lastly, it moves the WORKDIR from /usr/src/app to /opt/apps/devto.
The Linux FHS states that /opt is the spot for Optional application
software packages and /usr/src is for kernel source code.

https://en.wikipedia.org/wiki/Filesystem_Hierarchy_Standard

/opt Optional application software packages
/usr/src Source code, e.g., the kernel source code with its header files.

Also, if SELinux becomes a thing in our future, moving this makes it
easier to manage contexts out of /opt rather than /usr/src.

* Adjust the Containerfile a bit to add some missing packages, make it
more generic and move env vars to the docker-compose.

* Move the Dockerfile to a symlink to the Containerfile.

We need to be able to support more than just Docker for a container
runtime. Moving everything to a Containerfile and symlinking the
Dockerfile helps users run runtimes such as Podman.

* Add in new entrypoint files and fix the app path in docker-entrypoint.sh

* Refactor the docker-compose.yml file so it doesn't build the main
application container three times in a row. We can use the same
container for web, webpacker, and sidekiq.

Also make the volume names very explicit on what their contents and add
in SELinux context support with :Z

* Fix ELASTICSEARCH_URL.

* Remove the absolute path on ip binary and add in iproute to Containerfile.

* Symlink the Dockerfile to Containerfile and add in a container-compose.yml file
for usage with podman-compose. We are waiting for this issue to get resolved

https://github.com/containers/libpod/issues/6153

and for podman-compose to mature a bit more. A user using podman-compose can use

podman-compose -f container-compose.yml

to launch the DEV container stack with Podman.

* Update the .gitignore file to reflect the new container volumes.

* Fix the entrypoint script on the Containerfile and clean up a bunch of things.

* Rework the Containerfile to prep it to run as a non-root user. We have to wait
for this issue to get fixed:

https://github.com/containers/libpod/issues/6153

for Linux users and then we can uncomment the USER line so we are running Rails
as a non-root user. :toot:

* This reworks the compose files so each task that is needed to start the app has
a correct wait command with dockerize. It also adds in containers for doing
yarn and bundle things for development. Since we mount the code directory inside
the container we lose our pre-containerized gems and node_modules.

This means users can run:

Linux
podman-compose -f container-compose.yml up

Mac
docker-compose up

and it should correctly build the app stack with containers!

* Clean up old container related things.

* Add in some container pre-reqs and my name to the "Core team" section! :toot:

* Adjust the seed and sidekiq compose entries so they do not use the web entrypoint
and set the REDIS_URL and REDIS_SESSIONS_URL env vars for seed.

Add in some echos to the entrypoint.sh.

Also set docker-compose to use :delegated on mount points to speed things up.

https://docs.docker.com/storage/bind-mounts/#configure-mount-consistency-for-macos

* Just call yarn install --dev on the yarn container.

* Update documentation to support Docker and Podman as Container Engines and
move the page from docker to containers to reflect the fact not all users run
their containers via Docker.

There are dozens of us... DOZENS!

* Set --local on bundle config so it just impacts this Ruby app.

* Renamed bin/docker-setup to bin/container-setup to reflect the fact that that
we can use Podman as a container engine. I also refactored it so it does some
basic pre-flight checks for docker and docker-compose or podman and
podman-compose to make sure users have a container engine installed.

* Set cache_all_platforms true for bundler.

* Bump docker-compose dockerize -timeout to 45min for slower macOS hardware.

* Move to the consolidated app_initializer:setup rake task for bootstrapping the
app.

* Update docs/installation/readme.md
2020-05-28 12:11:51 -05:00
Ridhwana
1a40e10df8
Update the tag moderation email (#8048)
* feat: update the tag mod text

* feat: channel slug

* feat: updates

* feat: update text

* chore: change
2020-05-28 17:46:41 +02:00
dependabot-preview[bot]
293a9d7c86
Bump rubocop-performance from 1.5.2 to 1.6.0 (#8116)
Bumps [rubocop-performance](https://github.com/rubocop-hq/rubocop-performance) from 1.5.2 to 1.6.0.
- [Release notes](https://github.com/rubocop-hq/rubocop-performance/releases)
- [Changelog](https://github.com/rubocop-hq/rubocop-performance/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rubocop-hq/rubocop-performance/compare/v1.5.2...v1.6.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-28 10:38:16 -05:00
dependabot-preview[bot]
896cfa7315
Bump capybara from 3.32.1 to 3.32.2 (#8114)
Bumps [capybara](https://github.com/teamcapybara/capybara) from 3.32.1 to 3.32.2.
- [Release notes](https://github.com/teamcapybara/capybara/releases)
- [Changelog](https://github.com/teamcapybara/capybara/blob/master/History.md)
- [Commits](https://github.com/teamcapybara/capybara/compare/3.32.1...3.32.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-28 10:37:09 -05:00
Molly Struve
07f8964007
[deploy] Tweak How We Track Ambiguous Routes to Make them Easier to Track (#8112) 2020-05-28 10:34:39 -05:00
Nick Taylor
530b13e8c7
made all frontend unit tests uniform by preffering it(...) over test(...) (#8113) 2020-05-28 17:18:15 +02:00
Molly Struve
14c2372ae7
[deploy] Add API Key to API Write Throttle (#8110) 2020-05-28 09:45:01 -05:00
Nick Taylor
0f68c37679
Fixed a typo and broken image in the frontent tests docs. (#8109) 2020-05-28 10:08:16 -04:00
Molly Struve
8a4c2c1cb4
[deploy] Add App, Database, and Search Health Check Endpoints (#8071) 2020-05-28 08:33:31 -05:00
Molly Struve
0edca1fe2c
[deploy] Track How Often We Hit Ambiguous Routes (#8098) 2020-05-28 07:56:00 -05:00
Nick Taylor
4e97623823
Fixed issue with jest picking up the built storybook folder causing tests to run out of memory. (#8096) 2020-05-28 14:22:24 +02:00
rhymes
79247e2e24
Add libv8 for Catalina (#8106) 2020-05-28 11:31:32 +02:00
rhymes
eb355a6d4c
Fix broken tag filters in listings (#8086) 2020-05-28 10:24:50 +02:00
Nick Taylor
58135879c8
Configured jest to use the jest-watch-typeahead watch plugin. (#8093)
* Configured jest to use the jest-watch-typeahead watch plugin.

* Added some documentation in regards to jest watch mode.
2020-05-28 10:09:50 +02:00
fermin
a8d56ad894
Fix dev.to link (#8097) 2020-05-28 10:00:47 +02:00
krishna kakade
29269cd589
--base-50: changed to #fff unreadble text in ten X hacker theme (#8001)
--base-50: changed to #fff unreadable text in ten X hacker theme  light-dark text making eye strain their that's why i changed to white it looks i tested in firefox and another bug in this theme is in case of mail 
  and usernames CSS properties are overriding please and that text is getting black out there Ex:-Hidden
2020-05-27 15:54:55 -04:00
Vaidehi Joshi
5baecfdd61
Remove type onboarding from broadcast form options (#8087) [deploy] 2020-05-27 12:49:23 -07:00
Molly Struve
134fec0e9c
Add New Gems to Cache (#8095) 2020-05-27 14:13:49 -05:00
Mac Siri
8521eab94a
Update .simplecov (#8078) 2020-05-27 14:37:21 -04:00
Nick Taylor
c83cad6fb6
Sorting Storybook stories (#8058)
* Added story sorting to Storybook.

* Added design system guidelines.

* Made Base in Storybook tree 2nd in the tree view.

* Now Components are 3rd in the treeview of Storybook.

* Now App Components are 4th in the treeview of Storybook.

* Froze node version to 12.16.0

* Revert "Froze node version to 12.16.0"

This reverts commit 093b119c7d7ca05ecb4e1c0234b24bcf8e7b10a4.
2020-05-27 13:10:16 -04:00
Molly Struve
182faa0289
[deploy] Consolidate Setup Tasks to a Single Rake Task (#8065) 2020-05-27 11:59:07 -05:00
Nick Taylor
26c66b34d2
Fixed configuration to build Storybook on Netlify. (#8088) 2020-05-27 12:44:30 -04:00
Joe Doss
f7a3664415
Let's cache our gems in vendor/cache! (#8066)
* Let's cache our gems in vendor/cache!

This PR adds in bundle package caching which will help speed up deployments by
caching all of the gems that we use in our git repo. This was done with the
following commands on a fresh repo clone:

bundle install
bundle package --all

This cached all of our gems in vendor/cache and when you do a bundle install to
update gems from the Gemfile, it will update our gem cache too.

You can read more about bundle package here:

https://bundler.io/man/bundle-package.1.html

* Add in bundle config set cache_all true to bin/setup so it gets set for everyone.
2020-05-27 11:29:55 -05:00
Ben Halpern
9a489adc12
[deploy] Fix cloudinary helper (#6701)
Co-authored-by: Molly Struve <mollylbs@gmail.com>
2020-05-27 11:05:30 -05:00
Fernando Valverde
bf740ac5d8
[deploy] Podcast Player native bridge calls refactor to use message based communication (#8054)
* Podcast native bridge calls now message based

* Resets current time to 0 when initializing
2020-05-27 11:14:31 -04:00
Molly Struve
dc76c891c6
[deploy] Comment out Percy Code Failing Specs (#8077) 2020-05-27 10:12:28 -05:00
Julianna Tetreault
6cf177c3e4
Add download_app Welcome Notification (#8067)
* Add download_broadcast to generator.rb
  * Adds memoized download_broadcast method
  * Adds send_download_notification method
  * Adds send_download_notification to call method

* Add download_app to broadcasts.rb and seeds.rb
  * Adds download_app broadcast info and copy to factory
  * Adds download_app copy to seeds

* Add specs around #send_download_app_notification in generator_spec.rb

* Fix quotes around copy

* Remove extra space within copy
2020-05-27 08:14:47 -06:00
Michael Kohl
7f75f99560
[deploy] Rename classified listings (#7910)
* Change models and related files

* Update controllers and specs

* More renaming

* Seek and destroy, I mean search and replace

* Round up the stragglers

* Ground control to Major Travis...

* More fixes

* PR feedback

* Various fixes

* Rename view

* Fix list query builder

* Unify request specs

* Fix some API spec errors

* Fix remaining API specs

* Make spec conform to API

* Fix leftover problems

* Fix JS tests

* Fix column name in select

* Fix API specs

* Fix search specs

* Paging Mr. Travis
2020-05-27 13:35:09 +00:00
rhymes
ce28c0b5e5
[deploy] Remove ERB pre-processing from pure JS files and cleanup (#8030) 2020-05-27 08:25:39 -05:00
ludwiczakpawel
975ddc61c4
Home Feed Tabs - Crayonsified (#7976)
* flare tag line height

* .

* new tabs on home

* instantclick

* Some JS cleanup for mobile view select event handler.

* eslint cleanup

* select arrow color

* quotes

* quotes

* .

* .

* omg

* .

* finally

* focus visible

Co-authored-by: Nick Taylor <nick@iamdeveloper.com>
2020-05-27 14:48:18 +02:00
rhymes
acb35afe03
Add unique indexes - part 4 (#8059)
* Rubocop unique index cop needs a static list of columns

* Add unique index on organizations secret

* Add unique index on chat_channel_memberships chat_channel_id

* Add unique index to chat_channel slug

* Add unique index to badge_achievements badge_id
2020-05-27 09:29:20 +02:00