-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #306 from caktus/develop
Production release v1.20.0
- Loading branch information
Showing
62 changed files
with
24,194 additions
and
1,153 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,7 +41,7 @@ cloudformation_stack: | |
MaxScale: 4 | ||
UseAES256Encryption: "true" | ||
CustomerManagedCmkArn: "" | ||
ContainerInstanceType: t3a.medium | ||
ContainerInstanceType: t3a.large | ||
ContainerVolumeSize: 40 | ||
DatabaseAllocatedStorage: 100 | ||
DatabaseClass: db.t3.large | ||
|
@@ -64,7 +64,7 @@ k8s_install_descheduler: yes | |
# You must set the k8s_descheduler_chart_version to match the Kubernetes | ||
# node version (0.23.x -> K8s 1.23.x); see: | ||
# https://github.com/kubernetes-sigs/descheduler#compatibility-matrix | ||
k8s_descheduler_chart_version: v0.25.2 | ||
k8s_descheduler_chart_version: v0.29.0 | ||
# See values.yaml for options: | ||
# https://github.com/kubernetes-sigs/descheduler/blob/master/charts/descheduler/values.yaml#L63 | ||
k8s_descheduler_release_values: | ||
|
@@ -94,9 +94,9 @@ k8s_iam_users: [copelco] | |
# Pin ingress-nginx and cert-manager to current versions so future upgrades of this | ||
# role will not upgrade these charts without your intervention: | ||
# https://github.com/kubernetes/ingress-nginx/releases | ||
k8s_ingress_nginx_chart_version: "4.4.2" | ||
k8s_ingress_nginx_chart_version: "4.9.1" | ||
# https://github.com/jetstack/cert-manager/releases | ||
k8s_cert_manager_chart_version: "v1.11.1" | ||
k8s_cert_manager_chart_version: "v1.14.3" | ||
# AWS only: | ||
# Use the newer load balancer type (NLB). DO NOT edit k8s_aws_load_balancer_type after | ||
# creating your Service. | ||
|
@@ -106,11 +106,11 @@ k8s_aws_load_balancer_type: nlb | |
# caktus.k8s-hosting-services: Logging and monitoring configuration | ||
# ---------------------------------------------------------------------------- | ||
|
||
k8s_papertrail_logspout_destination: "syslog+tls://logs2.papertrailapp.com:20851" | ||
k8s_papertrail_logspout_memory_limit: 128Mi | ||
# k8s_papertrail_logspout_destination: "syslog+tls://logs2.papertrailapp.com:20851" | ||
# k8s_papertrail_logspout_memory_limit: 128Mi | ||
|
||
# New Relic Account: [email protected] | ||
k8s_newrelic_chart_version: "5.0.4" | ||
k8s_newrelic_chart_version: "5.0.68" | ||
k8s_newrelic_logging_enabled: true | ||
k8s_newrelic_license_key: !vault | | ||
$ANSIBLE_VAULT;1.1;AES256 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ The services configured for this project are: | |
* PostgreSQL database backups to S3 (within Caktus AWS account) | ||
* Currently, this is only `traffic_stops`, which contains users, census data, etc. | ||
* `traffic_stops_nc` is not backed up since the entire dataset is re-imported daily. | ||
* Papertrail logging (to Caktus account) | ||
* New Relic logging (to Caktus account) | ||
* New Relic Infrastructure monitoring (Account: `[email protected]`) | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
import React, { useEffect, useState } from 'react'; | ||
import ArrestsStyled from './Arrests.styles'; | ||
|
||
// Hooks | ||
import useMetaTags from '../../../Hooks/useMetaTags'; | ||
import useTableModal from '../../../Hooks/useTableModal'; | ||
|
||
// Children | ||
import PercentageOfStops from './Charts/PercentageOfStops'; | ||
import PercentageOfSearches from './Charts/PercentageOfSearches'; | ||
import CountOfStopsAndArrests from './Charts/CountOfStopsAndArrests'; | ||
import PercentageOfStopsForStopPurposeGroup from './Charts/PercentageOfStopsForPurposeGroup'; | ||
import PercentageOfStopsForStopPurpose from './Charts/PercentageOfStopsPerStopPurpose'; | ||
import PercentageOfSearchesForStopPurposeGroup from './Charts/PercentageOfSearchesForPurposeGroup'; | ||
import PercentageOfSearchesPerStopPurpose from './Charts/PercentageOfSearchesPerStopPurpose'; | ||
import PercentageOfStopsPerContrabandType from './Charts/PercentageOfStopsPerContrabandType'; | ||
import Switch from 'react-switch'; | ||
import { SwitchContainer } from '../TrafficStops/TrafficStops.styled'; | ||
|
||
function Arrests(props) { | ||
const { year } = props; | ||
const [togglePercentageOfStops, setTogglePercentageOfStops] = useState(true); | ||
const [togglePercentageOfSearches, setTogglePercentageOfSearches] = useState(true); | ||
|
||
const renderMetaTags = useMetaTags(); | ||
const [renderTableModal] = useTableModal(); | ||
|
||
useEffect(() => { | ||
if (window.location.hash) { | ||
document.querySelector(`${window.location.hash}`).scrollIntoView(); | ||
} | ||
}, []); | ||
|
||
const stopGraphToggle = () => ( | ||
<SwitchContainer> | ||
<span> | ||
Switch to view {togglePercentageOfStops ? 'all stop purposes' : 'grouped stop purposes '} | ||
</span> | ||
<Switch | ||
onChange={() => setTogglePercentageOfStops(!togglePercentageOfStops)} | ||
checked={togglePercentageOfStops} | ||
className="react-switch" | ||
/> | ||
</SwitchContainer> | ||
); | ||
|
||
const searchGraphToggle = () => ( | ||
<SwitchContainer> | ||
<span> | ||
Switch to view {togglePercentageOfSearches ? 'all stop purposes' : 'grouped stop purposes '} | ||
</span> | ||
<Switch | ||
onChange={() => setTogglePercentageOfSearches(!togglePercentageOfSearches)} | ||
checked={togglePercentageOfSearches} | ||
className="react-switch" | ||
/> | ||
</SwitchContainer> | ||
); | ||
|
||
return ( | ||
<ArrestsStyled> | ||
{renderMetaTags()} | ||
{renderTableModal()} | ||
<PercentageOfStops {...props} year={year} /> | ||
<PercentageOfSearches {...props} year={year} /> | ||
<CountOfStopsAndArrests {...props} year={year} /> | ||
|
||
{togglePercentageOfStops ? ( | ||
<PercentageOfStopsForStopPurposeGroup {...props} year={year}> | ||
{stopGraphToggle()} | ||
</PercentageOfStopsForStopPurposeGroup> | ||
) : ( | ||
<PercentageOfStopsForStopPurpose {...props} year={year}> | ||
{stopGraphToggle()} | ||
</PercentageOfStopsForStopPurpose> | ||
)} | ||
|
||
{togglePercentageOfSearches ? ( | ||
<PercentageOfSearchesForStopPurposeGroup {...props} year={year}> | ||
{searchGraphToggle()} | ||
</PercentageOfSearchesForStopPurposeGroup> | ||
) : ( | ||
<PercentageOfSearchesPerStopPurpose {...props} year={year}> | ||
{searchGraphToggle()} | ||
</PercentageOfSearchesPerStopPurpose> | ||
)} | ||
|
||
<PercentageOfStopsPerContrabandType {...props} year={year} /> | ||
</ArrestsStyled> | ||
); | ||
} | ||
|
||
export default Arrests; |
Oops, something went wrong.