mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-05-15 09:07:02 +02:00
merge main
This commit is contained in:
commit
cc3ae1efcc
5 changed files with 9 additions and 18 deletions
|
@ -74,20 +74,4 @@ jobs:
|
|||
cf_org: cisa-dotgov
|
||||
cf_space: ${{ env.ENVIRONMENT }}
|
||||
cf_manifest: ops/manifests/manifest-${{ env.ENVIRONMENT }}.yaml
|
||||
comment:
|
||||
runs-on: ubuntu-latest
|
||||
needs: [deploy]
|
||||
steps:
|
||||
- uses: actions/github-script@v6
|
||||
env:
|
||||
ENVIRONMENT: ${{ github.event.inputs.environment }}
|
||||
with:
|
||||
github-token: ${{secrets.GITHUB_TOKEN}}
|
||||
script: |
|
||||
github.rest.issues.createComment({
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
body: '🥳 Successfully deployed to developer sandbox **[${{ env.ENVIRONMENT }}](https://getgov-${{ env.ENVIRONMENT }}.app.cloud.gov/)**.'
|
||||
})
|
||||
|
||||
|
|
@ -45,6 +45,8 @@ When deploying to your personal sandbox, you should make sure all of the USWDS a
|
|||
|
||||
For ease of use, you can run the `deploy.sh <sandbox name>` script in the `/src` directory to build the assets and deploy to your sandbox. Similarly, you could run `build.sh <sandbox name>` script to just compile and collect the assets without deploying.
|
||||
|
||||
You may also manually deploy to a sandbox using our [manual deploy workflow](https://github.com/cisagov/manage.get.gov/actions/workflows/deploy-manual.yaml) on GitHub Actions. Select Run workflow and enter the branch you want to deploy to your sandbox of choice.
|
||||
|
||||
Your sandbox space should've been setup as part of the onboarding process. If this was not the case, please have an admin follow the instructions below.
|
||||
|
||||
## Creating a sandbox or new environment
|
||||
|
|
|
@ -116,6 +116,10 @@ sed -i '' '/ - development/ {a\
|
|||
- '"$1"'
|
||||
}' .github/workflows/migrate.yaml
|
||||
|
||||
sed -i '' '/ - backup/ {a\
|
||||
- '"$1"'
|
||||
}' .github/workflows/deploy-manual.yaml
|
||||
|
||||
sed -i '' '/${{startsWith(github.head_ref, / {a\
|
||||
|| startsWith(github.head_ref, '"'$1'"')
|
||||
}' .github/workflows/deploy-sandbox.yaml
|
||||
|
|
|
@ -49,6 +49,7 @@ rm ops/manifests/manifest-$1.yaml
|
|||
sed -i '' "/getgov-$1.app.cloud.gov/d" src/registrar/config/settings.py
|
||||
sed -i '' "/- $1/d" .github/workflows/reset-db.yaml
|
||||
sed -i '' "/- $1/d" .github/workflows/migrate.yaml
|
||||
sed -i '' "/- $1/d" .github/workflows/deploy-manual.yaml
|
||||
|
||||
echo "Cleaning up services, applications, and the Cloud.gov space for $1..."
|
||||
cf delete getgov-$1
|
||||
|
|
|
@ -61,7 +61,7 @@ def add_has_profile_feature_flag_to_context(request):
|
|||
def portfolio_permissions(request):
|
||||
"""Make portfolio permissions for the request user available in global context"""
|
||||
try:
|
||||
if not request.user or not request.user.is_authenticated:
|
||||
if not request.user or not request.user.is_authenticated or not flag_is_active(request, "organization_feature"):
|
||||
return {
|
||||
"has_base_portfolio_permission": False,
|
||||
"has_domains_portfolio_permission": False,
|
||||
|
@ -74,7 +74,7 @@ def portfolio_permissions(request):
|
|||
"has_domains_portfolio_permission": request.user.has_domains_portfolio_permission(),
|
||||
"has_domain_requests_portfolio_permission": request.user.has_domain_requests_portfolio_permission(),
|
||||
"portfolio": request.user.portfolio,
|
||||
"has_organization_feature_flag": flag_is_active(request, "organization_feature"),
|
||||
"has_organization_feature_flag": True,
|
||||
}
|
||||
except AttributeError:
|
||||
# Handles cases where request.user might not exist
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue