Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
freedombone
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Context Sensitive Group
freedombone
Commits
3adc321f
Commit
3adc321f
authored
8 years ago
by
Bob Mottram
Browse files
Options
Downloads
Patches
Plain Diff
Permissions
parent
85758178
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/freedombone-app-mediagoblin
+17
-4
17 additions, 4 deletions
src/freedombone-app-mediagoblin
with
17 additions
and
4 deletions
src/freedombone-app-mediagoblin
+
17
−
4
View file @
3adc321f
...
...
@@ -122,7 +122,9 @@ function remove_user_mediagoblin {
function
reconfigure_mediagoblin
{
MEDIAGOBLIN_BASE_DIR
=
/var/www/
$MEDIAGOBLIN_DOMAIN_NAME
/htdocs
rm
-f
/var/lib/mediagoblin/
*
.db
rm
-rf
$MEDIAGOBLIN_BASE_DIR
/user_dev
rm
-rf
/var/lib/mediagoblin/media/
*
rm
-f
$MEDIAGOBLIN_BASE_DIR
/user_dev
su
-c
"cd
$MEDIAGOBLIN_BASE_DIR
/mediagoblin && ln -s /var/lib/mediagoblin user_dev"
- mediagoblin
su
-c
"cd
$MEDIAGOBLIN_BASE_DIR
/mediagoblin/ && ./bin/gmg dbupdate"
- mediagoblin
}
...
...
@@ -130,6 +132,7 @@ function upgrade_mediagoblin {
MEDIAGOBLIN_BASE_DIR
=
/var/www/
$MEDIAGOBLIN_DOMAIN_NAME
/htdocs
su
-c
"cd
$MEDIAGOBLIN_BASE_DIR
/mediagoblin/ && ./bin/python setup.py develop --upgrade && ./bin/gmg dbupdate"
- mediagoblin
mediagoblin_fix_email
su
-c
"cd
$MEDIAGOBLIN_BASE_DIR
/mediagoblin/ && ./bin/gmg dbupdate"
- mediagoblin
echo
"0"
}
...
...
@@ -172,8 +175,9 @@ function restore_local_mediagoblin {
fi
rm
-rf
${
temp_restore_dir
}
rm
-rf
${
temp_restore_dir
}
2
chown
-hR
mediagoblin:www-data /var/lib/mediagoblin
chown
-hR
mediagoblin:www-data
$MEDIAGOBLIN_BASE_DIR
chown
-hR
mediagoblin:www-data /var/lib/mediagoblin
chmod
-R
g+wx /var/lib/mediagoblin
fi
}
...
...
@@ -204,8 +208,9 @@ function restore_remote_mediagoblin {
fi
rm
-rf
/root/tempmediagoblin
rm
-rf
/root/tempmediagoblin2
chown
-hR
mediagoblin:www-data /var/lib/mediagoblin
chown
-hR
mediagoblin:www-data
$MEDIAGOBLIN_BASE_DIR
chown
-hR
mediagoblin:www-data /var/lib/mediagoblin
chmod
-R
g+wx /var/lib/mediagoblin
fi
}
...
...
@@ -257,9 +262,10 @@ function install_mediagoblin {
useradd
-c
"GNU MediaGoblin system account"
-d
/var/lib/mediagoblin
-m
-r
-g
www-data mediagoblin
usermod
--append
-G
mediagoblin mediagoblin
mkdir
-p
/var/lib/mediagoblin
chown
-hR
mediagoblin:www-data /var/lib/mediagoblin
mkdir
-p
$MEDIAGOBLIN_BASE_DIR
chown
-hR
mediagoblin:www-data
$MEDIAGOBLIN_BASE_DIR
chown
-hR
mediagoblin:www-data /var/lib/mediagoblin
chmod
-R
g+wx /var/lib/mediagoblin
su
-c
"cd
$MEDIAGOBLIN_BASE_DIR
&& git clone
$MEDIAGOBLIN_REPO
$MEDIAGOBLIN_BASE_DIR
/mediagoblin"
- mediagoblin
su
-c
"cd
$MEDIAGOBLIN_BASE_DIR
/mediagoblin && git checkout
$MEDIAGOBLIN_COMMIT
-b
$MEDIAGOBLIN_COMMIT
"
- mediagoblin
su
-c
"cd
$MEDIAGOBLIN_BASE_DIR
/mediagoblin && git submodule sync"
- mediagoblin
...
...
@@ -465,6 +471,10 @@ function install_mediagoblin {
mediagoblin_fix_email
if
[
-d
/var/lib/mediagoblin/media
]
;
then
chmod
-R
+x /var/lib/mediagoblin/media
fi
function_check create_site_certificate
create_site_certificate
$MEDIAGOBLIN_DOMAIN_NAME
...
...
@@ -479,6 +489,9 @@ function install_mediagoblin {
function_check add_ddns_domain
add_ddns_domain
$MEDIAGOBLIN_DOMAIN_NAME
chown
-hR
mediagoblin:www-data /var/lib/mediagoblin
chmod
-R
g+wx /var/lib/mediagoblin
APP_INSTALLED
=
1
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment