Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
117 changes: 117 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,117 @@
# Created by https://www.toptal.com/developers/gitignore/api/phpstorm
# Edit at https://www.toptal.com/developers/gitignore?templates=phpstorm

### PhpStorm ###
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839

# User-specific stuff
.idea/**/workspace.xml
.idea/**/tasks.xml
.idea/**/usage.statistics.xml
.idea/**/dictionaries
.idea/**/shelf

# AWS User-specific
.idea/**/aws.xml

# Generated files
.idea/**/contentModel.xml

# Sensitive or high-churn files
.idea/**/dataSources/
.idea/**/dataSources.ids
.idea/**/dataSources.local.xml
.idea/**/sqlDataSources.xml
.idea/**/dynamic.xml
.idea/**/uiDesigner.xml
.idea/**/dbnavigator.xml

# Gradle
.idea/**/gradle.xml
.idea/**/libraries

# Gradle and Maven with auto-import
# When using Gradle or Maven with auto-import, you should exclude module files,
# since they will be recreated, and may cause churn. Uncomment if using
# auto-import.
# .idea/artifacts
# .idea/compiler.xml
# .idea/jarRepositories.xml
# .idea/modules.xml
# .idea/*.iml
# .idea/modules
# *.iml
# *.ipr

# CMake
cmake-build-*/

# Mongo Explorer plugin
.idea/**/mongoSettings.xml

# File-based project format
*.iws

# IntelliJ
out/

# mpeltonen/sbt-idea plugin
.idea_modules/

# JIRA plugin
atlassian-ide-plugin.xml

# Cursive Clojure plugin
.idea/replstate.xml

# SonarLint plugin
.idea/sonarlint/

# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties
fabric.properties

# Editor-based Rest Client
.idea/httpRequests

# Android studio 3.1+ serialized cache file
.idea/caches/build_file_checksums.ser

### PhpStorm Patch ###
# Comment Reason: https://github.com/joeblau/gitignore.io/issues/186#issuecomment-215987721

# *.iml
# modules.xml
# .idea/misc.xml
# *.ipr

# Sonarlint plugin
# https://plugins.jetbrains.com/plugin/7973-sonarlint
.idea/**/sonarlint/

# SonarQube Plugin
# https://plugins.jetbrains.com/plugin/7238-sonarqube-community-plugin
.idea/**/sonarIssues.xml

# Markdown Navigator plugin
# https://plugins.jetbrains.com/plugin/7896-markdown-navigator-enhanced
.idea/**/markdown-navigator.xml
.idea/**/markdown-navigator-enh.xml
.idea/**/markdown-navigator/

# Cache file creation bug
# See https://youtrack.jetbrains.com/issue/JBR-2257
.idea/$CACHE_FILE$

# CodeStream plugin
# https://plugins.jetbrains.com/plugin/12206-codestream
.idea/codestream.xml

# Azure Toolkit for IntelliJ plugin
# https://plugins.jetbrains.com/plugin/8053-azure-toolkit-for-intellij
.idea/**/azureSettings.xml

# End of https://www.toptal.com/developers/gitignore/api/phpstorm
23 changes: 22 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,27 @@ sf-open-email: ## Open Email catcher.
sf-check-requirements: ## Check requirements.
$(SYMFONY) check:requirements
.PHONY: sf-check-requirements

sf-generate-keys: ## Generate public and private keys for current environment
$(SYMFONY_CONSOLE) secret:generate-keys
.PHONY: sf-generate-keys

sf-generate-all-keys: ## Generate keys for dev and prod environments
APP_RUNTIME_ENV=dev $(MAKE) sf-generate-keys && APP_RUNTIME_ENV=prod $(MAKE) sf-generate-keys
.PHONY: sf-generate-all-keys

sf-rotate-keys: ## Generate a new decrypt key for current environment
$(SYMFONY_CONSOLE) secret:generate-keys --rotate
.PHONY: sf-rotate-keys

sf-rotate-all-keys: ## Generate new decrypt keys for dev and prod environments
APP_RUNTIME_ENV=dev $(MAKE) sf-rotate-keys && APP_RUNTIME_ENV=prod $(MAKE) sf-rotate-keys
.PHONY: sf-rotate-all-keys

sf-decrypt: ## Decrypt secrets and add environments variables
$(SYMFONY_CONSOLE) secrets:decrypt-to-local --force
.PHONY: sf-decrypt

#---------------------------------------------#

## === 📦 COMPOSER ==============================================
Expand Down Expand Up @@ -255,7 +276,7 @@ tests-coverage: ## Run tests with coverage.
before-commit: qa-cs-fixer qa-phpstan qa-security-checker qa-phpcpd qa-lint-twigs qa-lint-yaml qa-lint-container qa-lint-schema tests ## Run before commit.
.PHONY: before-commit

first-install: docker-up composer-install npm-install npm-build sf-perm sf-dc sf-dmm sf-start sf-open ## First install.
first-install: docker-up composer-install npm-install npm-build sf-perm sf-dc sf-dmm sf-decrypt sf-start sf-open ## First install.
.PHONY: first-install

start: docker-up sf-start sf-open ## Start project.
Expand Down
36 changes: 32 additions & 4 deletions Taskfile.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ tasks:
docker-up:
desc: "Start docker containers"
cmds:
- "{{.DOCKER_COMPOSE_UP}}"
- "{{.DOCKER_COMPOSE_UP}} -d"

docker-stop:
desc: "Stop docker containers"
Expand Down Expand Up @@ -81,7 +81,7 @@ tasks:
cmds:
- "{{.SYMFONY_CONSOLE}} doctrine:database:drop --if-exists --force"

sf-dc:
sf-ds:
desc: "Update symfony schema database"
cmds:
- "{{.SYMFONY_CONSOLE}} doctrine:schema:update --force"
Expand Down Expand Up @@ -150,7 +150,34 @@ tasks:
desc: "Check symfony requirements"
cmds:
- "{{.SYMFONY}} check:requirements"


sf-generate-keys:
desc: "Generate public and private keys for current environment"
cmds:
- "{{.SYMFONY_CONSOLE}} secret:generate-keys"

sf-generate-all-keys:
desc: "Generate keys for dev and prod environments"
cmds:
- "APP_RUNTIME_ENV=dev {{.SYMFONY_CONSOLE}} secret:generate-keys"
- "APP_RUNTIME_ENV=prod {{.SYMFONY_CONSOLE}} secret:generate-keys"

sf-rotate-keys:
desc: "Generate a new decrypt key for current environment"
cmds:
- "{{.SYMFONY_CONSOLE}} secret:generate-keys --rotate"

sf-rotate-all-keys:
desc: "Generate new decrypt keys for dev and prod environments"
cmds:
- "APP_RUNTIME_ENV=dev {{.SYMFONY_CONSOLE}} secret:generate-keys --rotate"
- "APP_RUNTIME_ENV=prod {{.SYMFONY_CONSOLE}} secret:generate-keys --rotate"

sf-decrypt:
desc: "Decrypt secrets and add environments variables"
cmds:
- "{{.SYMFONY_CONSOLE}} secrets:decrypt-to-local --force"

composer-install:
desc: "Install composer dependencies"
cmds:
Expand Down Expand Up @@ -279,13 +306,14 @@ tasks:
- task: sf-perm
- task: sf-dc
- task: sf-dmm
- task: sf-decrypt
- task: sf-start
- task: sf-open

start:
desc: "Start"
cmds:
- tasl: docker-up
- task: docker-up
- task: sf-start
- task: sf-open

Expand Down